From 95fad99fe7b788aeef51029e63092b19a0ff65ed Mon Sep 17 00:00:00 2001
From: Marko Lindqvist <cazfi74@gmail.com>
Date: Fri, 6 Sep 2024 07:18:08 +0300
Subject: [PATCH 19/19] Rename struct Treaty as struct treaty

See RM #825

Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
---
 ai/classic/classicai.c         |  4 ++--
 ai/default/daidiplomacy.c      |  6 +++---
 ai/default/daidiplomacy.h      |  6 +++---
 ai/tex/texai.c                 |  4 ++--
 client/clitreaty.c             | 10 +++++-----
 client/gui-gtk-3.22/diplodlg.c | 22 ++++++++++-----------
 client/gui-gtk-4.0/diplodlg.c  | 22 ++++++++++-----------
 client/gui-gtk-5.0/diplodlg.c  | 22 ++++++++++-----------
 client/gui-qt/diplodlg.cpp     | 18 ++++++++---------
 client/gui-qt/diplodlg.h       |  8 ++++----
 client/gui-qt/qtg_cxxside.h    | 12 ++++++------
 client/gui-sdl2/diplodlg.c     | 16 ++++++++--------
 client/gui-sdl3/diplodlg.c     | 16 ++++++++--------
 client/gui-stub/diplodlg.c     | 12 ++++++------
 client/gui_interface.c         | 12 ++++++------
 client/gui_interface.h         | 12 ++++++------
 client/include/diplodlg_g.h    | 14 +++++++-------
 common/ai.h                    |  6 +++---
 common/diptreaty.c             | 18 ++++++++---------
 common/diptreaty.h             | 22 ++++++++++-----------
 doc/HACKING                    |  2 +-
 server/diplhand.c              | 35 +++++++++++++++++-----------------
 server/diplhand.h              |  1 -
 server/savegame/savegame2.c    |  2 +-
 server/savegame/savegame3.c    |  4 ++--
 25 files changed, 153 insertions(+), 153 deletions(-)

diff --git a/ai/classic/classicai.c b/ai/classic/classicai.c
index 8caf0bd34d..aa08fa7fb2 100644
--- a/ai/classic/classicai.c
+++ b/ai/classic/classicai.c
@@ -484,7 +484,7 @@ static void cai_do_last_activities(struct player *pplayer)
   Call default ai with classic ai type as parameter.
 **************************************************************************/
 static void cai_treaty_evaluate(struct player *pplayer, struct player *aplayer,
-                                struct Treaty *ptreaty)
+                                struct treaty *ptreaty)
 {
   struct ai_type *deftype = classic_ai_get_self();
 
@@ -495,7 +495,7 @@ static void cai_treaty_evaluate(struct player *pplayer, struct player *aplayer,
   Call default ai with classic ai type as parameter.
 **************************************************************************/
 static void cai_treaty_accepted(struct player *pplayer, struct player *aplayer, 
-                                struct Treaty *ptreaty)
+                                struct treaty *ptreaty)
 {
   struct ai_type *deftype = classic_ai_get_self();
 
diff --git a/ai/default/daidiplomacy.c b/ai/default/daidiplomacy.c
index 2582b136cc..549267b636 100644
--- a/ai/default/daidiplomacy.c
+++ b/ai/default/daidiplomacy.c
@@ -622,7 +622,7 @@ static int dai_goldequiv_clause(struct ai_type *ait,
   is the treaty being considered. It is all a question about money :-)
 **********************************************************************/
 void dai_treaty_evaluate(struct ai_type *ait, struct player *pplayer,
-                         struct player *aplayer, struct Treaty *ptreaty)
+                         struct player *aplayer, struct treaty *ptreaty)
 {
   int total_balance = 0;
   bool only_gifts = TRUE;
@@ -742,7 +742,7 @@ static void dai_treaty_react(struct ai_type *ait,
   is the treaty accepted.
 **********************************************************************/
 void dai_treaty_accepted(struct ai_type *ait, struct player *pplayer,
-                         struct player *aplayer, struct Treaty *ptreaty)
+                         struct player *aplayer, struct treaty *ptreaty)
 {
   bool close_here;
   struct ai_plr *ai;
@@ -1231,7 +1231,7 @@ static void suggest_tech_exchange(struct ai_type *ait,
 **********************************************************************/
 static void clear_old_treaty(struct player *pplayer, struct player *aplayer)
 {
-  struct Treaty *old_treaty = find_treaty(pplayer, aplayer);
+  struct treaty *old_treaty = find_treaty(pplayer, aplayer);
 
   if (old_treaty != NULL) {
     /* Remove existing clauses */
diff --git a/ai/default/daidiplomacy.h b/ai/default/daidiplomacy.h
index 74e4a10e39..03cac30b56 100644
--- a/ai/default/daidiplomacy.h
+++ b/ai/default/daidiplomacy.h
@@ -18,7 +18,7 @@
 
 #include "ai.h" /* incident_type */
 
-struct Treaty;
+struct treaty;
 struct Clause;
 struct ai_data;
 
@@ -26,9 +26,9 @@ void dai_diplomacy_begin_new_phase(struct ai_type *ait, struct player *pplayer);
 void dai_diplomacy_actions(struct ai_type *ait, struct player *pplayer);
 
 void dai_treaty_evaluate(struct ai_type *ait, struct player *pplayer,
-                         struct player *aplayer, struct Treaty *ptreaty);
+                         struct player *aplayer, struct treaty *ptreaty);
 void dai_treaty_accepted(struct ai_type *ait, struct player *pplayer,
-                         struct player *aplayer, struct Treaty *ptreaty);
+                         struct player *aplayer, struct treaty *ptreaty);
 
 void dai_incident(struct ai_type *ait, enum incident_type type,
                   enum casus_belli_range scope,
diff --git a/ai/tex/texai.c b/ai/tex/texai.c
index 56151afd4e..1d4d181256 100644
--- a/ai/tex/texai.c
+++ b/ai/tex/texai.c
@@ -465,7 +465,7 @@ static void texwai_last_activities(struct player *pplayer)
 **************************************************************************/
 static void texwai_treaty_evaluate(struct player *pplayer,
                                    struct player *aplayer,
-                                   struct Treaty *ptreaty)
+                                   struct treaty *ptreaty)
 {
   TEXAI_AIT;
   TEXAI_DFUNC(dai_treaty_evaluate, pplayer, aplayer, ptreaty);
@@ -476,7 +476,7 @@ static void texwai_treaty_evaluate(struct player *pplayer,
 **************************************************************************/
 static void texwai_treaty_accepted(struct player *pplayer,
                                    struct player *aplayer, 
-                                   struct Treaty *ptreaty)
+                                   struct treaty *ptreaty)
 {
   TEXAI_AIT;
   TEXAI_DFUNC(dai_treaty_accepted, pplayer, aplayer, ptreaty);
diff --git a/client/clitreaty.c b/client/clitreaty.c
index 8ef31d27f1..cf4264ff85 100644
--- a/client/clitreaty.c
+++ b/client/clitreaty.c
@@ -32,7 +32,7 @@
 **************************************************************************/
 void client_init_meeting(int counterpart, int initiated_from)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   struct player *we;
   struct player *they;
 
@@ -59,7 +59,7 @@ void client_init_meeting(int counterpart, int initiated_from)
 void client_recv_accept_treaty(int counterpart, bool I_accepted,
                                bool other_accepted)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   struct player *we;
   struct player *they;
 
@@ -82,7 +82,7 @@ void client_recv_accept_treaty(int counterpart, bool I_accepted,
 **************************************************************************/
 void client_recv_cancel_meeting(int counterpart, int initiated_from)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   struct player *we;
   struct player *they;
 
@@ -105,7 +105,7 @@ void client_recv_cancel_meeting(int counterpart, int initiated_from)
 void client_recv_create_clause(int counterpart, int giver,
                                enum clause_type type, int value)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   struct player *we;
   struct player *they;
 
@@ -131,7 +131,7 @@ void client_recv_create_clause(int counterpart, int giver,
 void client_recv_remove_clause(int counterpart, int giver,
                                enum clause_type type, int value)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   struct player *we;
   struct player *they;
 
diff --git a/client/gui-gtk-3.22/diplodlg.c b/client/gui-gtk-3.22/diplodlg.c
index e61cfbd222..ad0fa80ee5 100644
--- a/client/gui-gtk-3.22/diplodlg.c
+++ b/client/gui-gtk-3.22/diplodlg.c
@@ -51,7 +51,7 @@
 #include "plrdlg.h"
 
 struct Diplomacy_dialog {
-  struct Treaty *treaty;
+  struct treaty *treaty;
   struct gui_dialog *dialog;
 
   GtkWidget *menu0;
@@ -85,12 +85,12 @@ struct city_deal {
 static struct dialog_list *dialog_list;
 static struct Diplomacy_notebook *dipl_main;
 
-static struct Diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct Diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1);
 
 static struct Diplomacy_dialog *find_diplomacy_dialog(struct player *they);
-static void popup_diplomacy_dialog(struct Treaty *ptreaty, struct player *they,
+static void popup_diplomacy_dialog(struct treaty *ptreaty, struct player *they,
                                    struct player *initiator);
 static void diplomacy_dialog_map_callback(GtkWidget *w, gpointer data);
 static void diplomacy_dialog_seamap_callback(GtkWidget *w, gpointer data);
@@ -117,7 +117,7 @@ static void diplomacy_main_response(struct gui_dialog *dlg, int response,
 /************************************************************************//**
   Server tells us that either party has accepted treaty
 ****************************************************************************/
-void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void gui_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -134,7 +134,7 @@ void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Someone is initiating meeting with us.
 ****************************************************************************/
-void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator)
 {
   popup_diplomacy_dialog(ptreaty, they, initiator);
@@ -143,7 +143,7 @@ void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
 /************************************************************************//**
   Meeting has been cancelled.
 ****************************************************************************/
-void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
@@ -160,7 +160,7 @@ void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Prepare to clause creation or removal.
 **************************************************************************/
-void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void gui_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   /* Not needed */
 }
@@ -168,7 +168,7 @@ void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Added clause to the meeting
 ****************************************************************************/
-void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -185,7 +185,7 @@ void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Removed clause from meeting.
 ****************************************************************************/
-void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -202,7 +202,7 @@ void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Popup the dialog 10% inside the main-window 
 ****************************************************************************/
-static void popup_diplomacy_dialog(struct Treaty *ptreaty, struct player *they,
+static void popup_diplomacy_dialog(struct treaty *ptreaty, struct player *they,
                                    struct player *initiator)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
@@ -686,7 +686,7 @@ static void diplomacy_response(struct gui_dialog *dlg, int response,
 /************************************************************************//**
   Setups diplomacy dialog widgets.
 ****************************************************************************/
-static struct Diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct Diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1)
 {
diff --git a/client/gui-gtk-4.0/diplodlg.c b/client/gui-gtk-4.0/diplodlg.c
index a9a0667227..ecc21e3f8b 100644
--- a/client/gui-gtk-4.0/diplodlg.c
+++ b/client/gui-gtk-4.0/diplodlg.c
@@ -51,7 +51,7 @@
 #include "plrdlg.h"
 
 struct Diplomacy_dialog {
-  struct Treaty *treaty;
+  struct treaty *treaty;
   struct gui_dialog *dialog;
 
   GtkWidget *pic0;
@@ -82,12 +82,12 @@ struct city_deal {
 static struct dialog_list *dialog_list;
 static struct Diplomacy_notebook *dipl_main;
 
-static struct Diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct Diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1);
 
 static struct Diplomacy_dialog *find_diplomacy_dialog(struct player *they);
-static void popup_diplomacy_dialog(struct Treaty *ptreaty, struct player *they,
+static void popup_diplomacy_dialog(struct treaty *ptreaty, struct player *they,
                                    struct player *initiator);
 static void diplomacy_dialog_map_callback(GSimpleAction *action,
                                           GVariant *parameter,
@@ -136,7 +136,7 @@ static void diplomacy_main_response(struct gui_dialog *dlg, int response,
 /************************************************************************//**
   Server tells us that either party has accepted treaty
 ****************************************************************************/
-void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void gui_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -153,7 +153,7 @@ void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Someone is initiating meeting with us.
 ****************************************************************************/
-void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator)
 {
   popup_diplomacy_dialog(ptreaty, they, initiator);
@@ -162,7 +162,7 @@ void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
 /************************************************************************//**
   Meeting has been cancelled.
 ****************************************************************************/
-void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
@@ -179,7 +179,7 @@ void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Prepare to clause creation or removal.
 **************************************************************************/
-void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void gui_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   /* Not needed */
 }
@@ -187,7 +187,7 @@ void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Added clause to the meeting
 ****************************************************************************/
-void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -204,7 +204,7 @@ void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Removed clause from meeting.
 ****************************************************************************/
-void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -221,7 +221,7 @@ void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Popup the dialog 10% inside the main-window
 ****************************************************************************/
-static void popup_diplomacy_dialog(struct Treaty *ptreaty, struct player *they,
+static void popup_diplomacy_dialog(struct treaty *ptreaty, struct player *they,
                                    struct player *initiator)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
@@ -756,7 +756,7 @@ static void diplomacy_response(struct gui_dialog *dlg, int response,
 /************************************************************************//**
   Setups diplomacy dialog widgets.
 ****************************************************************************/
-static struct Diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct Diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1)
 {
diff --git a/client/gui-gtk-5.0/diplodlg.c b/client/gui-gtk-5.0/diplodlg.c
index d42f003303..7df13a4059 100644
--- a/client/gui-gtk-5.0/diplodlg.c
+++ b/client/gui-gtk-5.0/diplodlg.c
@@ -51,7 +51,7 @@
 #include "plrdlg.h"
 
 struct Diplomacy_dialog {
-  struct Treaty *treaty;
+  struct treaty *treaty;
   struct gui_dialog *dialog;
 
   GtkWidget *pic0;
@@ -82,12 +82,12 @@ struct city_deal {
 static struct dialog_list *dialog_list;
 static struct Diplomacy_notebook *dipl_main;
 
-static struct Diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct Diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1);
 
 static struct Diplomacy_dialog *find_diplomacy_dialog(struct player *they);
-static void popup_diplomacy_dialog(struct Treaty *ptreaty, struct player *they,
+static void popup_diplomacy_dialog(struct treaty *ptreaty, struct player *they,
                                    struct player *initiator);
 static void diplomacy_dialog_map_callback(GSimpleAction *action,
                                           GVariant *parameter,
@@ -136,7 +136,7 @@ static void diplomacy_main_response(struct gui_dialog *dlg, int response,
 /************************************************************************//**
   Server tells us that either party has accepted treaty
 ****************************************************************************/
-void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void gui_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -153,7 +153,7 @@ void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Someone is initiating meeting with us.
 ****************************************************************************/
-void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator)
 {
   popup_diplomacy_dialog(ptreaty, they, initiator);
@@ -162,7 +162,7 @@ void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
 /************************************************************************//**
   Meeting has been cancelled.
 ****************************************************************************/
-void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
@@ -179,7 +179,7 @@ void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Prepare to clause creation or removal.
 **************************************************************************/
-void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void gui_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   /* Not needed */
 }
@@ -187,7 +187,7 @@ void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Added clause to the meeting
 ****************************************************************************/
-void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -204,7 +204,7 @@ void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Removed clause from meeting.
 ****************************************************************************/
-void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
 
@@ -221,7 +221,7 @@ void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Popup the dialog 10% inside the main-window
 ****************************************************************************/
-static void popup_diplomacy_dialog(struct Treaty *ptreaty, struct player *they,
+static void popup_diplomacy_dialog(struct treaty *ptreaty, struct player *they,
                                    struct player *initiator)
 {
   struct Diplomacy_dialog *pdialog = find_diplomacy_dialog(they);
@@ -756,7 +756,7 @@ static void diplomacy_response(struct gui_dialog *dlg, int response,
 /************************************************************************//**
   Setups diplomacy dialog widgets.
 ****************************************************************************/
-static struct Diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct Diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1)
 {
diff --git a/client/gui-qt/diplodlg.cpp b/client/gui-qt/diplodlg.cpp
index 9eb5086248..0c8f52a288 100644
--- a/client/gui-qt/diplodlg.cpp
+++ b/client/gui-qt/diplodlg.cpp
@@ -54,7 +54,7 @@ typedef city *p_city;
 /************************************************************************//**
   Constructor for diplomacy widget
 ****************************************************************************/
-diplo_wdg::diplo_wdg(struct Treaty *ptreaty,
+diplo_wdg::diplo_wdg(struct treaty *ptreaty,
                      struct player *they, struct player *initiator): QWidget()
 {
   struct player *we;
@@ -781,7 +781,7 @@ void diplo_wdg::response_cancel()
 /************************************************************************//**
   Constructor for diplomacy dialog
 ****************************************************************************/
-diplo_dlg::diplo_dlg(struct Treaty *ptreaty, struct player *they,
+diplo_dlg::diplo_dlg(struct treaty *ptreaty, struct player *they,
                      struct player *initiator) : QTabWidget()
 {
   add_widget(ptreaty, they, initiator);
@@ -791,7 +791,7 @@ diplo_dlg::diplo_dlg(struct Treaty *ptreaty, struct player *they,
 /************************************************************************//**
   Creates new diplomacy widget and adds to diplomacy dialog
 ****************************************************************************/
-void diplo_dlg::add_widget(struct Treaty *ptreaty, struct player *they,
+void diplo_dlg::add_widget(struct treaty *ptreaty, struct player *they,
                            struct player *initiator)
 {
   diplo_wdg *dw;
@@ -916,7 +916,7 @@ void diplo_dlg::reactivate()
   Update a player's acceptance status of a treaty (traditionally shown
   with the thumbs-up/thumbs-down sprite).
 ****************************************************************************/
-void qtg_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void qtg_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   int i;
   diplo_dlg *dd;
@@ -941,7 +941,7 @@ void qtg_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
   Handle the start of a diplomacy meeting - usually by popping up a
   diplomacy dialog.
 ****************************************************************************/
-void qtg_init_meeting(struct Treaty *ptreaty, struct player *they,
+void qtg_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator)
 {
   int i;
@@ -1027,7 +1027,7 @@ void qtg_init_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Prepare to clause creation or removal.
 **************************************************************************/
-void qtg_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void qtg_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   // Not needed
 }
@@ -1035,7 +1035,7 @@ void qtg_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
 /************************************************************************//**
   Update the diplomacy dialog by adding a clause.
 ****************************************************************************/
-void qtg_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void qtg_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   int i;
   diplo_dlg *dd;
@@ -1059,7 +1059,7 @@ void qtg_recv_create_clause(struct Treaty *ptreaty, struct player *they)
   Update the diplomacy dialog when the meeting is canceled (the dialog
   should be closed).
 ****************************************************************************/
-void qtg_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void qtg_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator)
 {
   int i;
@@ -1079,7 +1079,7 @@ void qtg_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
 /************************************************************************//**
   Update the diplomacy dialog by removing a clause.
 ****************************************************************************/
-void qtg_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void qtg_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   int i;
   diplo_dlg *dd;
diff --git a/client/gui-qt/diplodlg.h b/client/gui-qt/diplodlg.h
index 313933702e..6b9115d154 100644
--- a/client/gui-qt/diplodlg.h
+++ b/client/gui-qt/diplodlg.h
@@ -57,13 +57,13 @@ class diplo_wdg: public QWidget
   QTableWidget *text_edit;
 
 public:
-  diplo_wdg(struct Treaty *ptreaty,
+  diplo_wdg(struct treaty *ptreaty,
             struct player *they, struct player *initiator);
   ~diplo_wdg();
   void update_wdg();
   void set_index(int ind);
   int get_index();
-  struct Treaty *treaty;
+  struct treaty *treaty;
 
 private slots:
   void all_advances();
@@ -107,7 +107,7 @@ class diplo_dlg: public QTabWidget
   QMap<struct player *, diplo_wdg *> treaty_list;
 
 public:
-  diplo_dlg(struct Treaty *ptreaty, struct player *they,
+  diplo_dlg(struct treaty *ptreaty, struct player *they,
             struct player *initiator);
   ~diplo_dlg();
   void reactivate();
@@ -115,7 +115,7 @@ public:
   bool init(bool raise);
   diplo_wdg *find_widget(struct player *they);
   void close_widget(struct player *they);
-  void add_widget(struct Treaty *ptreaty, struct player *they,
+  void add_widget(struct treaty *ptreaty, struct player *they,
                   struct player *initiator);
   void make_active(struct player *party);
 
diff --git a/client/gui-qt/qtg_cxxside.h b/client/gui-qt/qtg_cxxside.h
index 8eb26282d0..46c1676c83 100644
--- a/client/gui-qt/qtg_cxxside.h
+++ b/client/gui-qt/qtg_cxxside.h
@@ -146,14 +146,14 @@ void qtg_gui_clear_theme();
 char **qtg_get_gui_specific_themes_directories(int *count);
 char **qtg_get_usable_themes_in_directory(const char *directory, int *count);
 
-void qtg_init_meeting(struct Treaty *ptreaty, struct player *they,
+void qtg_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator);
-void qtg_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void qtg_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator);
-void qtg_prepare_clause_updt(struct Treaty *ptreaty, struct player *they);
-void qtg_recv_create_clause(struct Treaty *ptreaty, struct player *they);
-void qtg_recv_remove_clause(struct Treaty *ptreaty, struct player *they);
-void qtg_recv_accept_treaty(struct Treaty *ptreaty, struct player *they);
+void qtg_prepare_clause_updt(struct treaty *ptreaty, struct player *they);
+void qtg_recv_create_clause(struct treaty *ptreaty, struct player *they);
+void qtg_recv_remove_clause(struct treaty *ptreaty, struct player *they);
+void qtg_recv_accept_treaty(struct treaty *ptreaty, struct player *they);
 
 void qtg_request_action_confirmation(const char *expl,
                                      struct act_confirmation_data *data);
diff --git a/client/gui-sdl2/diplodlg.c b/client/gui-sdl2/diplodlg.c
index e35255b659..0f00278574 100644
--- a/client/gui-sdl2/diplodlg.c
+++ b/client/gui-sdl2/diplodlg.c
@@ -51,7 +51,7 @@
 #include "diplodlg.h"
 
 struct diplomacy_dialog {
-  struct Treaty *treaty;
+  struct treaty *treaty;
   struct advanced_dialog *pdialog;
   struct advanced_dialog *pwants;
   struct advanced_dialog *poffers;
@@ -114,7 +114,7 @@ static struct diplomacy_dialog *get_diplomacy_dialog(struct player *they)
   Update a player's acceptance status of a treaty (traditionally shown
   with the thumbs-up/thumbs-down sprite).
 **************************************************************************/
-void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void gui_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -131,7 +131,7 @@ void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
   Update the diplomacy dialog when the meeting is canceled (the dialog
   should be closed).
 **************************************************************************/
-void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
@@ -171,7 +171,7 @@ static int remove_clause_callback(struct widget *pwidget)
 /**********************************************************************//**
   Prepare to clause creation or removal.
 **************************************************************************/
-void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void gui_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -192,7 +192,7 @@ void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Update the diplomacy dialog by adding a clause.
 **************************************************************************/
-void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -209,7 +209,7 @@ void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Update the diplomacy dialog by removing a clause.
 **************************************************************************/
-void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -910,7 +910,7 @@ static struct advanced_dialog *popup_diplomatic_objects(struct player *pplayer0,
 /**********************************************************************//**
   Open new diplomacy dialog between players.
 **************************************************************************/
-static struct diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1)
 {
@@ -1274,7 +1274,7 @@ static void remove_clause_widget_from_list(struct player *they,
   Handle the start of a diplomacy meeting - usually by popping up a
   diplomacy dialog.
 **************************************************************************/
-void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator)
 {
   struct diplomacy_dialog *pdialog;
diff --git a/client/gui-sdl3/diplodlg.c b/client/gui-sdl3/diplodlg.c
index 9f82b5f4ca..af850fcc30 100644
--- a/client/gui-sdl3/diplodlg.c
+++ b/client/gui-sdl3/diplodlg.c
@@ -47,7 +47,7 @@
 #include "diplodlg.h"
 
 struct diplomacy_dialog {
-  struct Treaty *treaty;
+  struct treaty *treaty;
   struct advanced_dialog *pdialog;
   struct advanced_dialog *pwants;
   struct advanced_dialog *poffers;
@@ -110,7 +110,7 @@ static struct diplomacy_dialog *get_diplomacy_dialog(struct player *they)
   Update a player's acceptance status of a treaty (traditionally shown
   with the thumbs-up/thumbs-down sprite).
 **************************************************************************/
-void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void gui_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -127,7 +127,7 @@ void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
   Update the diplomacy dialog when the meeting is canceled (the dialog
   should be closed).
 **************************************************************************/
-void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
@@ -167,7 +167,7 @@ static int remove_clause_callback(struct widget *pwidget)
 /**********************************************************************//**
   Prepare to clause creation or removal.
 **************************************************************************/
-void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void gui_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -188,7 +188,7 @@ void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Update the diplomacy dialog by adding a clause.
 **************************************************************************/
-void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -205,7 +205,7 @@ void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Update the diplomacy dialog by removing a clause.
 **************************************************************************/
-void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   struct diplomacy_dialog *pdialog = get_diplomacy_dialog(they);
 
@@ -906,7 +906,7 @@ static struct advanced_dialog *popup_diplomatic_objects(struct player *pplayer0,
 /**********************************************************************//**
   Open new diplomacy dialog between players.
 **************************************************************************/
-static struct diplomacy_dialog *create_diplomacy_dialog(struct Treaty *ptreaty,
+static struct diplomacy_dialog *create_diplomacy_dialog(struct treaty *ptreaty,
                                                         struct player *plr0,
                                                         struct player *plr1)
 {
@@ -1270,7 +1270,7 @@ static void remove_clause_widget_from_list(struct player *they,
   Handle the start of a diplomacy meeting - usually by popping up a
   diplomacy dialog.
 **************************************************************************/
-void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator)
 {
   struct diplomacy_dialog *pdialog;
diff --git a/client/gui-stub/diplodlg.c b/client/gui-stub/diplodlg.c
index d3243f3757..a8fda253f9 100644
--- a/client/gui-stub/diplodlg.c
+++ b/client/gui-stub/diplodlg.c
@@ -24,7 +24,7 @@
   Update a player's acceptance status of a treaty (traditionally shown
   with the thumbs-up/thumbs-down sprite).
 **************************************************************************/
-void gui_gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void gui_gui_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   /* PORTME */
 }
@@ -33,7 +33,7 @@ void gui_gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
   Handle the start of a diplomacy meeting - usually by popping up a
   diplomacy dialog.
 **************************************************************************/
-void gui_gui_init_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_gui_init_meeting(struct treaty *ptreaty, struct player *they,
                           struct player *initiator)
 {
   /* PORTME */
@@ -42,7 +42,7 @@ void gui_gui_init_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Update the diplomacy dialog by adding a clause.
 **************************************************************************/
-void gui_gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void gui_gui_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   /* PORTME */
 }
@@ -51,7 +51,7 @@ void gui_gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
   Update the diplomacy dialog when the meeting is canceled (the dialog
   should be closed).
 **************************************************************************/
-void gui_gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_gui_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                                  struct player *initiator)
 {
   /* PORTME */
@@ -60,7 +60,7 @@ void gui_gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Update the diplomacy dialog by removing a clause.
 **************************************************************************/
-void gui_gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void gui_gui_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   /* PORTME */
 }
@@ -68,7 +68,7 @@ void gui_gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Prepare to clause creation or removal.
 **************************************************************************/
-void gui_gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void gui_gui_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   /* PORTME */
 }
diff --git a/client/gui_interface.c b/client/gui_interface.c
index 98f04cb8ab..569aac1554 100644
--- a/client/gui_interface.c
+++ b/client/gui_interface.c
@@ -655,7 +655,7 @@ char **get_usable_themes_in_directory(const char *directory, int *count)
 /**********************************************************************//**
   Call gui_init_meeting callback
 **************************************************************************/
-void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_init_meeting(struct treaty *ptreaty, struct player *they,
                       struct player *initiator)
 {
   funcs.gui_init_meeting(ptreaty, they, initiator);
@@ -664,7 +664,7 @@ void gui_init_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Call gui_recv_cancel_meeting callback
 **************************************************************************/
-void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
+void gui_recv_cancel_meeting(struct treaty *ptreaty, struct player *they,
                              struct player *initiator)
 {
   funcs.gui_recv_cancel_meeting(ptreaty, they, initiator);
@@ -673,7 +673,7 @@ void gui_recv_cancel_meeting(struct Treaty *ptreaty, struct player *they,
 /**********************************************************************//**
   Call gui_prepare_clause_updt callback
 **************************************************************************/
-void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
+void gui_prepare_clause_updt(struct treaty *ptreaty, struct player *they)
 {
   funcs.gui_prepare_clause_updt(ptreaty, they);
 }
@@ -681,7 +681,7 @@ void gui_prepare_clause_updt(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Call gui_recv_create_clause callback
 **************************************************************************/
-void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_create_clause(struct treaty *ptreaty, struct player *they)
 {
   funcs.gui_recv_create_clause(ptreaty, they);
 }
@@ -689,7 +689,7 @@ void gui_recv_create_clause(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Call gui_recv_remove_clause callback
 **************************************************************************/
-void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
+void gui_recv_remove_clause(struct treaty *ptreaty, struct player *they)
 {
   funcs.gui_recv_remove_clause(ptreaty, they);
 }
@@ -697,7 +697,7 @@ void gui_recv_remove_clause(struct Treaty *ptreaty, struct player *they)
 /**********************************************************************//**
   Call gui_recv_accept_treaty callback
 **************************************************************************/
-void gui_recv_accept_treaty(struct Treaty *ptreaty, struct player *they)
+void gui_recv_accept_treaty(struct treaty *ptreaty, struct player *they)
 {
   funcs.gui_recv_accept_treaty(ptreaty, they);
 }
diff --git a/client/gui_interface.h b/client/gui_interface.h
index 1d645e149f..afb60e36b4 100644
--- a/client/gui_interface.h
+++ b/client/gui_interface.h
@@ -154,14 +154,14 @@ struct gui_funcs {
   char **(*get_gui_specific_themes_directories)(int *count);
   char **(*get_usable_themes_in_directory)(const char *directory, int *count);
 
-  void (*gui_init_meeting)(struct Treaty *ptreaty, struct player *they,
+  void (*gui_init_meeting)(struct treaty *ptreaty, struct player *they,
                            struct player *initiator);
-  void (*gui_recv_cancel_meeting)(struct Treaty *ptreaty, struct player *they,
+  void (*gui_recv_cancel_meeting)(struct treaty *ptreaty, struct player *they,
                                   struct player *initiator);
-  void (*gui_prepare_clause_updt)(struct Treaty *ptreaty, struct player *they);
-  void (*gui_recv_create_clause)(struct Treaty *ptreaty, struct player *they);
-  void (*gui_recv_remove_clause)(struct Treaty *ptreaty, struct player *they);
-  void (*gui_recv_accept_treaty)(struct Treaty *ptreaty, struct player *they);
+  void (*gui_prepare_clause_updt)(struct treaty *ptreaty, struct player *they);
+  void (*gui_recv_create_clause)(struct treaty *ptreaty, struct player *they);
+  void (*gui_recv_remove_clause)(struct treaty *ptreaty, struct player *they);
+  void (*gui_recv_accept_treaty)(struct treaty *ptreaty, struct player *they);
 
   void (*request_action_confirmation)(const char *expl,
                                       struct act_confirmation_data *data);
diff --git a/client/include/diplodlg_g.h b/client/include/diplodlg_g.h
index 7f3d18af21..03fc229ccc 100644
--- a/client/include/diplodlg_g.h
+++ b/client/include/diplodlg_g.h
@@ -22,20 +22,20 @@
 #include "gui_proto_constructor.h"
 
 GUI_FUNC_PROTO(void, gui_init_meeting,
-               struct Treaty *ptreaty, struct player *they,
+               struct treaty *ptreaty, struct player *they,
                struct player *initiator)
 GUI_FUNC_PROTO(void, gui_recv_cancel_meeting,
-               struct Treaty *ptreaty, struct player *they,
+               struct treaty *ptreaty, struct player *they,
                struct player *initiator)
 GUI_FUNC_PROTO(void, gui_prepare_clause_updt,
-               struct Treaty *ptreaty, struct player *they)
+               struct treaty *ptreaty, struct player *they)
 GUI_FUNC_PROTO(void, gui_recv_create_clause,
-               struct Treaty *ptreaty, struct player *they)
+               struct treaty *ptreaty, struct player *they)
 GUI_FUNC_PROTO(void, gui_recv_remove_clause,
-               struct Treaty *ptreaty, struct player *they)
-GUI_FUNC_PROTO(void, gui_recv_accept_treaty, struct Treaty *ptreaty,
+               struct treaty *ptreaty, struct player *they)
+GUI_FUNC_PROTO(void, gui_recv_accept_treaty, struct treaty *ptreaty,
                struct player *they)
 
 GUI_FUNC_PROTO(void, close_all_diplomacy_dialogs, void)
 
-#endif  /* FC__DIPLODLG_G_H */
+#endif /* FC__DIPLODLG_G_H */
diff --git a/common/ai.h b/common/ai.h
index 22c568dda3..f829fb9398 100644
--- a/common/ai.h
+++ b/common/ai.h
@@ -31,7 +31,7 @@ extern "C" {
 #  undef DEBUG_AITIMERS
 #endif /* FREECIV_DEBUG */
 
-struct Treaty;
+struct treaty;
 struct player;
 struct adv_choice;
 struct city;
@@ -258,12 +258,12 @@ struct ai_type
 
     /* Called for player AI type when diplomatic treaty requires evaluation. */
     void (*treaty_evaluate)(struct player *pplayer, struct player *aplayer,
-                            struct Treaty *ptreaty);
+                            struct treaty *ptreaty);
 
     /* Called for player AI type when diplomatic treaty has been accepted
      * by both parties. */
     void (*treaty_accepted)(struct player *pplayer, struct player *aplayer,
-                            struct Treaty *ptreaty);
+                            struct treaty *ptreaty);
 
     /* Called for player AI type when first contact with another player has been
      * established. Note that when contact is between two AI players, callback
diff --git a/common/diptreaty.c b/common/diptreaty.c
index 60e034847d..0fca99e0cd 100644
--- a/common/diptreaty.c
+++ b/common/diptreaty.c
@@ -96,11 +96,11 @@ bool could_intel_with_player(const struct player *pplayer,
 /**********************************************************************//**
   Initialize treaty structure between two players.
 **************************************************************************/
-void init_treaty(struct Treaty *ptreaty, 
+void init_treaty(struct treaty *ptreaty,
                  struct player *plr0, struct player *plr1)
 {
-  ptreaty->plr0=plr0;
-  ptreaty->plr1=plr1;
+  ptreaty->plr0 = plr0;
+  ptreaty->plr1 = plr1;
   ptreaty->accept0 = FALSE;
   ptreaty->accept1 = FALSE;
   ptreaty->clauses = clause_list_new();
@@ -109,7 +109,7 @@ void init_treaty(struct Treaty *ptreaty,
 /**********************************************************************//**
   Free the clauses of a treaty.
 **************************************************************************/
-void clear_treaty(struct Treaty *ptreaty)
+void clear_treaty(struct treaty *ptreaty)
 {
   clause_list_iterate(ptreaty->clauses, pclause) {
     free(pclause);
@@ -120,7 +120,7 @@ void clear_treaty(struct Treaty *ptreaty)
 /**********************************************************************//**
   Remove clause from treaty
 **************************************************************************/
-bool remove_clause(struct Treaty *ptreaty, struct player *pfrom, 
+bool remove_clause(struct treaty *ptreaty, struct player *pfrom,
                    enum clause_type type, int val)
 {
   clause_list_iterate(ptreaty->clauses, pclause) {
@@ -142,7 +142,7 @@ bool remove_clause(struct Treaty *ptreaty, struct player *pfrom,
 /**********************************************************************//**
   Add clause to treaty.
 **************************************************************************/
-bool add_clause(struct Treaty *ptreaty, struct player *pfrom, 
+bool add_clause(struct treaty *ptreaty, struct player *pfrom,
                 enum clause_type type, int val,
                 struct player *client_player)
 {
@@ -359,7 +359,7 @@ void free_treaties(void)
 /**********************************************************************//**
   Find currently active treaty between two players.
 **************************************************************************/
-struct Treaty *find_treaty(struct player *plr0, struct player *plr1)
+struct treaty *find_treaty(struct player *plr0, struct player *plr1)
 {
   treaty_list_iterate(treaties, ptreaty) {
     if ((ptreaty->plr0 == plr0 && ptreaty->plr1 == plr1)
@@ -374,7 +374,7 @@ struct Treaty *find_treaty(struct player *plr0, struct player *plr1)
 /**********************************************************************//**
   Add treaty to the global list.
 **************************************************************************/
-void treaty_add(struct Treaty *ptreaty)
+void treaty_add(struct treaty *ptreaty)
 {
   treaty_list_prepend(treaties, ptreaty);
 }
@@ -382,7 +382,7 @@ void treaty_add(struct Treaty *ptreaty)
 /**********************************************************************//**
   Remove treaty from the global list.
 **************************************************************************/
-void treaty_remove(struct Treaty *ptreaty)
+void treaty_remove(struct treaty *ptreaty)
 {
   treaty_list_remove(treaties, ptreaty);
 
diff --git a/common/diptreaty.h b/common/diptreaty.h
index 024d66b5df..ed1fa4535f 100644
--- a/common/diptreaty.h
+++ b/common/diptreaty.h
@@ -76,7 +76,7 @@ struct Clause {
   int value;
 };
 
-struct Treaty {
+struct treaty {
   struct player *plr0, *plr1;
   bool accept0, accept1;
   struct clause_list *clauses;
@@ -89,14 +89,14 @@ bool could_meet_with_player(const struct player *pplayer,
 bool could_intel_with_player(const struct player *pplayer,
                              const struct player *aplayer);
 
-void init_treaty(struct Treaty *ptreaty, 
+void init_treaty(struct treaty *ptreaty,
                  struct player *plr0, struct player *plr1);
-bool add_clause(struct Treaty *ptreaty, struct player *pfrom, 
+bool add_clause(struct treaty *ptreaty, struct player *pfrom,
                 enum clause_type type, int val,
                 struct player *client_player);
-bool remove_clause(struct Treaty *ptreaty, struct player *pfrom, 
+bool remove_clause(struct treaty *ptreaty, struct player *pfrom,
                    enum clause_type type, int val);
-void clear_treaty(struct Treaty *ptreaty);
+void clear_treaty(struct treaty *ptreaty);
 
 void clause_infos_init(void);
 void clause_infos_free(void);
@@ -105,23 +105,23 @@ struct clause_info *clause_info_get(enum clause_type type);
 bool clause_enabled(enum clause_type type);
 
 #define SPECLIST_TAG treaty
-#define SPECLIST_TYPE struct Treaty
+#define SPECLIST_TYPE struct treaty
 #include "speclist.h"
 
 #define treaty_list_iterate(list, p) \
-    TYPED_LIST_ITERATE(struct Treaty, list, p)
+    TYPED_LIST_ITERATE(struct treaty, list, p)
 #define treaty_list_iterate_end  LIST_ITERATE_END
 
 void treaties_init(void);
 void treaties_free(void);
 void free_treaties(void);
 
-struct Treaty *find_treaty(struct player *plr0, struct player *plr1);
+struct treaty *find_treaty(struct player *plr0, struct player *plr1);
 
-void treaty_add(struct Treaty *ptreaty);
-void treaty_remove(struct Treaty *ptreaty);
+void treaty_add(struct treaty *ptreaty);
+void treaty_remove(struct treaty *ptreaty);
 
-typedef void (*treaty_cb)(struct Treaty *, void *data);
+typedef void (*treaty_cb)(struct treaty *, void *data);
 void treaties_iterate(treaty_cb cb, void *data);
 
 #ifdef __cplusplus
diff --git a/doc/HACKING b/doc/HACKING
index 5687e84c1d..b3d6d9ea93 100644
--- a/doc/HACKING
+++ b/doc/HACKING
@@ -339,7 +339,7 @@ this to the civ2 system.
 Diplomacy
 =========================================================================
 A few words about the diplomacy system. When a diplomacy meeting is
-established, a Treaty structure is created on both of the clients and
+established, a treaty structure is created on both of the clients and
 on the server. All these structures are updated concurrently as clauses
 are added and removed.
 
diff --git a/server/diplhand.c b/server/diplhand.c
index 05eab429de..352c97cb88 100644
--- a/server/diplhand.c
+++ b/server/diplhand.c
@@ -60,7 +60,7 @@
   Calls treaty_evaluate function if such is set for AI player.    
 **************************************************************************/
 static void call_treaty_evaluate(struct player *pplayer, struct player *aplayer,
-                                 struct Treaty *ptreaty)
+                                 struct treaty *ptreaty)
 {
   if (is_ai(pplayer)) {
     CALL_PLR_AI_FUNC(treaty_evaluate, pplayer, pplayer, aplayer, ptreaty);
@@ -71,7 +71,7 @@ static void call_treaty_evaluate(struct player *pplayer, struct player *aplayer,
   Calls treaty_accepted function if such is set for AI player.
 **************************************************************************/
 static void call_treaty_accepted(struct player *pplayer, struct player *aplayer,
-                                 struct Treaty *ptreaty)
+                                 struct treaty *ptreaty)
 {
   if (is_ai(pplayer)) {
     CALL_PLR_AI_FUNC(treaty_accepted, pplayer, pplayer, aplayer, ptreaty);
@@ -145,9 +145,9 @@ void set_diplstate_type(struct player_diplstate *state1,
   agreed clauses.
 **************************************************************************/
 void handle_diplomacy_accept_treaty_req(struct player *pplayer,
-					int counterpart)
+                                        int counterpart)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   bool *player_accept, *other_accept;
   enum dipl_reason diplcheck;
   bool worker_refresh_required = FALSE;
@@ -718,10 +718,10 @@ void establish_embassy(struct player *pplayer, struct player *aplayer)
   Handle request to remove clause from treaty.
 **************************************************************************/
 void handle_diplomacy_remove_clause_req(struct player *pplayer,
-					int counterpart, int giver,
-					enum clause_type type, int value)
+                                        int counterpart, int giver,
+                                        enum clause_type type, int value)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   struct player *pgiver = player_by_number(giver);
   struct player *pother = player_by_number(counterpart);
 
@@ -751,10 +751,10 @@ void handle_diplomacy_remove_clause_req(struct player *pplayer,
   Handle request to add clause to treaty between two players.
 **************************************************************************/
 void handle_diplomacy_create_clause_req(struct player *pplayer,
-					int counterpart, int giver,
-					enum clause_type type, int value)
+                                        int counterpart, int giver,
+                                        enum clause_type type, int value)
 {
-  struct Treaty *ptreaty;
+  struct treaty *ptreaty;
   struct player *pgiver = player_by_number(giver);
   struct player *pother = player_by_number(counterpart);
 
@@ -802,9 +802,9 @@ void handle_diplomacy_create_clause_req(struct player *pplayer,
   this with input directly from untrusted source.
 **************************************************************************/
 static void really_diplomacy_cancel_meeting(struct player *pplayer,
-					    struct player *pother)
+                                            struct player *pother)
 {
-  struct Treaty *ptreaty = find_treaty(pplayer, pother);
+  struct treaty *ptreaty = find_treaty(pplayer, pother);
 
   if (ptreaty) {
     dlsend_packet_diplomacy_cancel_meeting(pother->connections,
@@ -843,7 +843,7 @@ void handle_diplomacy_cancel_meeting_req(struct player *pplayer,
   Handle meeting opening request.
 **************************************************************************/
 void handle_diplomacy_init_meeting_req(struct player *pplayer,
-				       int counterpart)
+                                       int counterpart)
 {
   struct player *pother = player_by_number(counterpart);
 
@@ -863,7 +863,7 @@ void handle_diplomacy_init_meeting_req(struct player *pplayer,
   }
 
   if (could_meet_with_player(pplayer, pother)) {
-    struct Treaty *ptreaty;
+    struct treaty *ptreaty;
 
     ptreaty = fc_malloc(sizeof(*ptreaty));
     init_treaty(ptreaty, pplayer, pother);
@@ -890,7 +890,7 @@ void send_diplomatic_meetings(struct connection *dest)
     return;
   }
   players_iterate(other) {
-    struct Treaty *ptreaty = find_treaty(pplayer, other);
+    struct treaty *ptreaty = find_treaty(pplayer, other);
 
     if (ptreaty) {
       fc_assert_action(pplayer != other, continue);
@@ -934,10 +934,11 @@ void cancel_all_meetings(struct player *pplayer)
 **************************************************************************/
 void reject_all_treaties(struct player *pplayer)
 {
-  struct Treaty* treaty;
+  struct treaty *treaty;
+
   players_iterate(pplayer2) {
     treaty = find_treaty(pplayer, pplayer2);
-    if (!treaty) {
+    if (treaty == nullptr) {
       continue;
     }
     treaty->accept0 = FALSE;
diff --git a/server/diplhand.h b/server/diplhand.h
index 1983b989b3..942148e581 100644
--- a/server/diplhand.h
+++ b/server/diplhand.h
@@ -19,7 +19,6 @@
 /* server */
 #include <hand_gen.h>       /* <> so looked from the build directory first. */
 
-struct Treaty;
 struct packet_diplomacy_info;
 struct connection;
 
diff --git a/server/savegame/savegame2.c b/server/savegame/savegame2.c
index 2150d8f3c1..53797bdc73 100644
--- a/server/savegame/savegame2.c
+++ b/server/savegame/savegame2.c
@@ -5404,7 +5404,7 @@ static void sg_load_treaties(struct loaddata *loading)
     if (p0 == NULL || p1 == NULL) {
       log_error("Treaty between unknown players %s and %s", plr0, plr1);
     } else {
-      struct Treaty *ptreaty = fc_malloc(sizeof(*ptreaty));
+      struct treaty *ptreaty = fc_malloc(sizeof(*ptreaty));
 
       init_treaty(ptreaty, p0, p1);
       treaty_add(ptreaty);
diff --git a/server/savegame/savegame3.c b/server/savegame/savegame3.c
index 68ba2adc72..d35dab9b20 100644
--- a/server/savegame/savegame3.c
+++ b/server/savegame/savegame3.c
@@ -7795,7 +7795,7 @@ static void sg_load_treaties(struct loaddata *loading)
     if (p0 == NULL || p1 == NULL) {
       log_error("Treaty between unknown players %s and %s", plr0, plr1);
     } else {
-      struct Treaty *ptreaty = fc_malloc(sizeof(*ptreaty));
+      struct treaty *ptreaty = fc_malloc(sizeof(*ptreaty));
 
       init_treaty(ptreaty, p0, p1);
       treaty_add(ptreaty);
@@ -7854,7 +7854,7 @@ typedef struct {
 /************************************************************************//**
   Save '[treaty_xxx]'.
 ****************************************************************************/
-static void treaty_save(struct Treaty *ptr, void *data_in)
+static void treaty_save(struct treaty *ptr, void *data_in)
 {
   char tpath[512];
   int cidx = 0;
-- 
2.45.2

