changeset 96:b4416ca69153

Fixes #309: Add initial preference dialog with language support * Hook up events so that everything translates itself when languages change Re #308: Make GTK# UI translatable * Update English and French translations (using Google Translate) * Begin to standardise on WinForms names for widgets for maximum reusability of translation files * Make some preference and credit buttons translatable
author IBBoard <dev@ibboard.co.uk>
date Sun, 02 Jan 2011 15:12:31 +0000
parents ea4069bbe6e9
children 6d2c8ad0d8f1
files FrmAbout.cs FrmAboutCredits.cs FrmAddEquipment.cs FrmEditEquipment.cs FrmMainWindow.cs FrmNewArmy.cs FrmNewUnit.cs FrmPreferences.cs FrmReplaceEquipment.cs Widgets/UnitDisplayWidget.cs gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmAboutCredits.cs gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmPreferences.cs gtk-gui/IBBoard.WarFoundry.GUI.GTK.Widgets.UnitDisplayWidget.cs gtk-gui/gui.stetic translations/en.translation translations/fr.translation
diffstat 16 files changed, 272 insertions(+), 135 deletions(-) [+]
line wrap: on
line diff
--- a/FrmAbout.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmAbout.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -5,6 +5,7 @@
 using System;
 using Gtk;
 using IBBoard.GtkSharp.Translatable;
+using IBBoard.Lang;
 
 namespace IBBoard.WarFoundry.GUI.GTK
 {
@@ -25,9 +26,21 @@
 		private FrmAbout()
 		{
 			this.Build();
+			Translation.TranslationChanged += Retranslate;
 			Translate();
 		}
 
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
+
 		protected virtual void CloseClicked(object sender, System.EventArgs e)
 		{
 			Respond(ResponseType.Close);
--- a/FrmAboutCredits.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmAboutCredits.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -2,8 +2,8 @@
 // 
 //  The file and the library/program it is in are licensed and distributed, without warranty, under the GNU Affero GPL license, either version 3 of the License or (at your option) any later version. Please see COPYING for more information and the full license.
 
-using System;
 using IBBoard.GtkSharp.Translatable;
+using IBBoard.Lang;
 
 namespace IBBoard.WarFoundry.GUI.GTK
 {
@@ -12,8 +12,20 @@
 		public FrmAboutCredits()
 		{
 			this.Build();
+			Translation.TranslationChanged += Retranslate;
 			Translate();
 		}
+
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
 	}
 }
 
--- a/FrmAddEquipment.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmAddEquipment.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -33,9 +33,21 @@
 			equipColumn.PackStart(equipCell, true);
 			equipColumn.SetCellDataFunc(equipCell, GtkWarFoundryUtil.RenderWarFoundryObjectName);
 			lstEquipment.AppendColumn(equipColumn);
+			Translation.TranslationChanged += Retranslate;
 			Translate();
 		}
 
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
+
 		protected override void Translate()
 		{
 			base.Translate();
--- a/FrmEditEquipment.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmEditEquipment.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -28,9 +28,21 @@
 		public FrmEditEquipment()
 		{
 			this.Build();
+			Translation.TranslationChanged += Retranslate;
 			Translate();
 		}
 
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
+
 		public void ListenToWidgets()
 		{
 			rbEquipAll.Clicked += RadioButtonClicked;
--- a/FrmMainWindow.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmMainWindow.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -148,7 +148,8 @@
 			WarFoundryCore.GameSystemChanged += new GameSystemChangedDelegate(OnGameSystemChanged);
 			WarFoundryCore.ArmyChanged += new ArmyChangedDelegate(OnArmyChanged);
 			Destroyed += new EventHandler(OnWindowDestroyed);
-			TranslateWindow();
+			Translation.TranslationChanged += Retranslate;
+			Translate();
 			UnitAddedMethod = new ObjectAddDelegate(OnUnitAdded);
 			UnitRemovedMethod = new ObjectRemoveDelegate(OnUnitRemoved);
 			PointsValueChangedMethod = new DoubleValChangedDelegate(OnPointsValueChanged);
@@ -219,13 +220,24 @@
 			}
 		}
 
-		private void TranslateWindow()
+		protected override void Translate()
 		{
-			ControlTranslator.TranslateWidget(this);
+			base.Translate();
 			SetAppTitle();
 			treeUnits.GetColumn(0).Title = Translation.GetTranslation("armyCategoryColumnTitle", "categories");
 		}
 
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
+
 		private void FileLoadingFinished(List<FileLoadFailure> failures)
 		{
 			foreach (FileLoadFailure failure in failures)
--- a/FrmNewArmy.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmNewArmy.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -36,7 +36,6 @@
 			raceColumn.PackStart(raceCell, true);
 			lstRaces.AppendColumn(raceColumn);
 			raceColumn.SetCellDataFunc(raceCell, GtkWarFoundryUtil.RenderWarFoundryObjectName);
-			Translate();
 			
 			if (gameSystem != null)
 			{
@@ -46,6 +45,20 @@
 			{
 				ComboBoxUtils.SelectIndex(systemCombo, 0);
 			}
+			
+			Translation.TranslationChanged += Retranslate;
+			Translate();
+		}
+
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
 		}
 
 		protected override void Translate()
--- a/FrmNewUnit.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmNewUnit.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -43,9 +43,22 @@
 			
 			lstUnitTypes.Model = store;
 			lstUnitTypes.Selection.Changed += new EventHandler(OnSelectionChanged);
+
+			Translation.TranslationChanged += Retranslate;
 			Translate();
 		}
 
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
+
 		protected override void Translate()
 		{
 			base.Translate();
--- a/FrmPreferences.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmPreferences.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -26,14 +26,30 @@
 			this.Build();
 			BuildPreferenceCategoryTree();
 			BuildLanguageList();
+
+			Translation.TranslationChanged += Retranslate;
 			Translate();
 		}
 
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
+
 		protected override void Translate()
 		{
 			base.Translate();
 			frameLabel.Text = Translation.GetTranslation("languagesGroup", "languages");
-
+			TreeStore model = ((TreeStore)preferencesTree.Model);
+			TreeIter iter;
+			model.GetIterFirst(out iter);
+			model.SetValue(iter, 0, Translation.GetTranslation("languagePrefSection", "Language"));
 		}
 
 		private void RenderPreference(TreeViewColumn column, CellRenderer cell, TreeModel model, TreeIter iter)
--- a/FrmReplaceEquipment.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/FrmReplaceEquipment.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -6,6 +6,7 @@
 using Gtk;
 using IBBoard.GtkSharp;
 using IBBoard.GtkSharp.Translatable;
+using IBBoard.Lang;
 using IBBoard.WarFoundry.API.Objects;
 using IBBoard.WarFoundry.GUI.GTK.UIControl.Interfaces;
 using IBBoard.WarFoundry.GUI.GTK.Util;
@@ -16,12 +17,13 @@
 	public partial class FrmReplaceEquipment : TranslatableDialog, IReplaceEquipmentUI
 	{
 		private static ILog log = LogManager.GetLogger(typeof(FrmReplaceEquipment));
+
 		public event SingleArgMethodInvoker<UnitEquipmentItem> UnitEquipmentItemChoiceChanged;
 		public event MethodInvoker UnitEquipmentAmountTypeChanged;
 		public event MethodInvoker UnitEquipmentAmountChanged;
 
 		private bool isRatioLimited;
-		
+
 		public FrmReplaceEquipment()
 		{
 			this.Build();
@@ -32,8 +34,22 @@
 			equipColumn.PackStart(equipCell, true);
 			equipColumn.SetCellDataFunc(equipCell, GtkWarFoundryUtil.RenderWarFoundryObjectName);
 			lstEquipment.AppendColumn(equipColumn);			
+
+			Translation.TranslationChanged += Retranslate;
+			Translate();
 		}
-		
+
+		private void Retranslate()
+		{
+			Translate();
+		}
+
+		public override void Dispose()
+		{
+			Translation.TranslationChanged -= Retranslate;
+			base.Dispose();
+		}
+
 		public void ListenToWidgets()
 		{
 			rbEquipAll.Clicked += RadioButtonClicked;
@@ -43,7 +59,7 @@
 			percentageAmount.ValueChanged += SpinButtonValueChanged;
 			lstEquipment.Selection.Changed += OnSelectionChanged;
 		}
-		
+
 		public void IgnoreWidgets()
 		{
 			rbEquipAll.Clicked -= RadioButtonClicked;
@@ -53,7 +69,7 @@
 			percentageAmount.ValueChanged -= SpinButtonValueChanged;
 			lstEquipment.Selection.Changed -= OnSelectionChanged;
 		}
-		
+
 		private void OnUnitEquipmentAmountChanged()
 		{
 			if (UnitEquipmentAmountChanged != null)
@@ -61,7 +77,7 @@
 				UnitEquipmentAmountChanged();
 			}
 		}
-		
+
 		private void OnUnitEquipmentAmountTypeChanged()
 		{
 			if (UnitEquipmentAmountChanged != null)
@@ -69,7 +85,7 @@
 				UnitEquipmentAmountTypeChanged();
 			}
 		}
-		
+
 		protected void OnSelectionChanged(object o, EventArgs e)
 		{
 			if (UnitEquipmentItemChoiceChanged != null)
@@ -127,41 +143,41 @@
 			this.Hide();
 			return okayClicked;
 		}
-		
+
 		protected virtual void CancelButtonClicked(object sender, System.EventArgs e)
 		{
 			log.Debug("Cancel clicked");
 			Respond(ResponseType.Cancel);
 		}	
-		
+
 		protected virtual void OkayButtonClicked(object sender, System.EventArgs e)
 		{
 			log.Debug("Okay clicked");
 			Respond(ResponseType.Ok);
 		}		
-		
+
 		public void SetOkayEnabledState(bool enabled)
 		{
 			buttonOk.Sensitive = enabled;
 		}
-				
+
 		protected virtual void SpinButtonValueChanged(object sender, System.EventArgs e)
 		{
 			OnUnitEquipmentAmountChanged();
 		}		
-		
+
 		protected virtual void RadioButtonClicked(object sender, System.EventArgs e)
 		{
 			OnUnitEquipmentAmountTypeChanged();
 		}
-		
+
 		public void SetNumericAmountEnabledState(bool enabled)
 		{
 			double minPercent = GetMinPercentage();
 			rbEquipNumeric.Sensitive = enabled && !(isRatioLimited && minPercent == 100);
 			numericAmount.Sensitive = rbEquipNumeric.Sensitive;
 		}		
-		
+
 		public void SetPercentageAmountEnabledState(bool enabled)
 		{
 			if (enabled)
@@ -195,7 +211,7 @@
 			percentageAmount.GetRange(out min, out max);
 			return min;
 		}
-		
+
 		public UnitEquipmentItem SelectedUnitEquipmentItem
 		{
 			get
@@ -203,7 +219,7 @@
 				return (UnitEquipmentItem)TreeUtils.GetSelectedItem(lstEquipment);
 			}
 		}
-		
+
 		public bool IsRatioEquipmentAmount
 		{
 			get
@@ -211,7 +227,7 @@
 				return !rbEquipNumeric.Active;
 			}
 		}
-		
+
 		public int EquipmentNumericAmount
 		{
 			get
@@ -224,7 +240,7 @@
 				numericAmount.Value = value;
 			}
 		}
-		
+
 		public double EquipmentPercentageAmount
 		{
 			get
--- a/Widgets/UnitDisplayWidget.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/Widgets/UnitDisplayWidget.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -59,14 +59,14 @@
 		private void SetButtonsEnabledState()
 		{			
 			UnitEquipmentItem equipItem = GetSelectedEquipmentItem();
-			bttnReplaceEquipment.Sensitive = (equipItem != null && equipItem.HasAlternatives());
-			bttnEditEquipment.Sensitive = (UnitEquipmentUtil.CanEditEquipmentAmount(unit, equipItem));
-			bttnRemoveEquipment.Sensitive = (equipItem != null && !equipItem.IsRequired);
+			bttnReplaceWeapon.Sensitive = (equipItem != null && equipItem.HasAlternatives());
+			bttnEditWeapon.Sensitive = (UnitEquipmentUtil.CanEditEquipmentAmount(unit, equipItem));
+			bttnRemoveWeapon.Sensitive = (equipItem != null && !equipItem.IsRequired);
 		}
 
 		private void SetAddButtonEnabledState()
 		{
-			bttnAddEquipment.Sensitive = AddEquipmentUIControl.HasEquipmentToAdd(unit);
+			bttnAddWeapon.Sensitive = AddEquipmentUIControl.HasEquipmentToAdd(unit);
 		}
 
 		private UnitEquipmentItem GetSelectedEquipmentItem()
--- a/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmAboutCredits.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmAboutCredits.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -11,7 +11,7 @@
 		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblDevelopers;
 		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblTestersCommon;
 		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblTestersGtk;
-		private global::Gtk.Button bttnClose;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnClose;
 
 		protected virtual void Build()
 		{
@@ -129,7 +129,7 @@
 			w9.BorderWidth = ((uint)(5));
 			w9.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(4));
 			// Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
-			this.bttnClose = new global::Gtk.Button();
+			this.bttnClose = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
 			this.bttnClose.CanDefault = true;
 			this.bttnClose.CanFocus = true;
 			this.bttnClose.Name = "bttnClose";
--- a/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmPreferences.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmPreferences.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -13,15 +13,18 @@
 		private global::Gtk.ComboBox languageList;
 		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblLanguage;
 		private global::Gtk.Label frameLabel;
-		private global::Gtk.Button bttnCancel;
-		private global::Gtk.Button bttnOkay;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnCancel;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnOkay;
 
 		protected virtual void Build()
 		{
 			global::Stetic.Gui.Initialize(this);
 			// Widget IBBoard.WarFoundry.GUI.GTK.FrmPreferences
 			this.Name = "IBBoard.WarFoundry.GUI.GTK.FrmPreferences";
+			this.TypeHint = ((global::Gdk.WindowTypeHint)(1));
 			this.WindowPosition = ((global::Gtk.WindowPosition)(4));
+			this.SkipPagerHint = true;
+			this.SkipTaskbarHint = true;
 			// Internal child IBBoard.WarFoundry.GUI.GTK.FrmPreferences.VBox
 			global::Gtk.VBox w1 = this.VBox;
 			w1.Name = "dialog1_VBox";
@@ -93,7 +96,7 @@
 			w10.BorderWidth = ((uint)(5));
 			w10.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(4));
 			// Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
-			this.bttnCancel = new global::Gtk.Button();
+			this.bttnCancel = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
 			this.bttnCancel.CanDefault = true;
 			this.bttnCancel.CanFocus = true;
 			this.bttnCancel.Name = "bttnCancel";
@@ -105,7 +108,7 @@
 			w11.Expand = false;
 			w11.Fill = false;
 			// Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
-			this.bttnOkay = new global::Gtk.Button();
+			this.bttnOkay = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
 			this.bttnOkay.CanDefault = true;
 			this.bttnOkay.CanFocus = true;
 			this.bttnOkay.Name = "bttnOkay";
--- a/gtk-gui/IBBoard.WarFoundry.GUI.GTK.Widgets.UnitDisplayWidget.cs	Sat Jan 01 20:55:07 2011 +0000
+++ b/gtk-gui/IBBoard.WarFoundry.GUI.GTK.Widgets.UnitDisplayWidget.cs	Sun Jan 02 15:12:31 2011 +0000
@@ -13,7 +13,6 @@
 		private global::Gtk.HSeparator hseparator1;
 		private global::Gtk.HBox hbox2;
 		private global::Gtk.Table table1;
-		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel equipmentLabel;
 		private global::Gtk.ScrolledWindow GtkScrolledWindow2;
 		private global::Gtk.NodeView equipmentList;
 		private global::Gtk.ScrolledWindow GtkScrolledWindow3;
@@ -21,12 +20,13 @@
 		private global::Gtk.ScrolledWindow GtkScrolledWindow4;
 		private global::Gtk.NodeView abilitiesList;
 		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblAbilities;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblEquip;
 		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblNotes;
 		private global::Gtk.VBox vbox3;
-		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnAddEquipment;
-		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnEditEquipment;
-		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnReplaceEquipment;
-		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnRemoveEquipment;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnAddWeapon;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnEditWeapon;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnReplaceWeapon;
+		private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnRemoveWeapon;
 
 		protected virtual void Build()
 		{
@@ -103,14 +103,6 @@
 			this.table1.RowSpacing = ((uint)(6));
 			this.table1.ColumnSpacing = ((uint)(6));
 			// Container child table1.Gtk.Table+TableChild
-			this.equipmentLabel = new global::IBBoard.GtkSharp.Translatable.TranslatableLabel();
-			this.equipmentLabel.Name = "equipmentLabel";
-			this.equipmentLabel.LabelProp = global::Mono.Unix.Catalog.GetString("equipment:");
-			this.table1.Add(this.equipmentLabel);
-			global::Gtk.Table.TableChild w9 = ((global::Gtk.Table.TableChild)(this.table1[this.equipmentLabel]));
-			w9.XOptions = ((global::Gtk.AttachOptions)(4));
-			w9.YOptions = ((global::Gtk.AttachOptions)(4));
-			// Container child table1.Gtk.Table+TableChild
 			this.GtkScrolledWindow2 = new global::Gtk.ScrolledWindow();
 			this.GtkScrolledWindow2.Name = "GtkScrolledWindow2";
 			this.GtkScrolledWindow2.ShadowType = ((global::Gtk.ShadowType)(1));
@@ -121,10 +113,10 @@
 			this.equipmentList.HeadersVisible = false;
 			this.GtkScrolledWindow2.Add(this.equipmentList);
 			this.table1.Add(this.GtkScrolledWindow2);
-			global::Gtk.Table.TableChild w11 = ((global::Gtk.Table.TableChild)(this.table1[this.GtkScrolledWindow2]));
-			w11.LeftAttach = ((uint)(1));
-			w11.RightAttach = ((uint)(2));
-			w11.YOptions = ((global::Gtk.AttachOptions)(4));
+			global::Gtk.Table.TableChild w10 = ((global::Gtk.Table.TableChild)(this.table1[this.GtkScrolledWindow2]));
+			w10.LeftAttach = ((uint)(1));
+			w10.RightAttach = ((uint)(2));
+			w10.YOptions = ((global::Gtk.AttachOptions)(4));
 			// Container child table1.Gtk.Table+TableChild
 			this.GtkScrolledWindow3 = new global::Gtk.ScrolledWindow();
 			this.GtkScrolledWindow3.Name = "GtkScrolledWindow3";
@@ -136,12 +128,12 @@
 			this.notesView.Editable = false;
 			this.GtkScrolledWindow3.Add(this.notesView);
 			this.table1.Add(this.GtkScrolledWindow3);
-			global::Gtk.Table.TableChild w13 = ((global::Gtk.Table.TableChild)(this.table1[this.GtkScrolledWindow3]));
-			w13.TopAttach = ((uint)(2));
-			w13.BottomAttach = ((uint)(3));
-			w13.LeftAttach = ((uint)(1));
-			w13.RightAttach = ((uint)(2));
-			w13.YOptions = ((global::Gtk.AttachOptions)(4));
+			global::Gtk.Table.TableChild w12 = ((global::Gtk.Table.TableChild)(this.table1[this.GtkScrolledWindow3]));
+			w12.TopAttach = ((uint)(2));
+			w12.BottomAttach = ((uint)(3));
+			w12.LeftAttach = ((uint)(1));
+			w12.RightAttach = ((uint)(2));
+			w12.YOptions = ((global::Gtk.AttachOptions)(4));
 			// Container child table1.Gtk.Table+TableChild
 			this.GtkScrolledWindow4 = new global::Gtk.ScrolledWindow();
 			this.GtkScrolledWindow4.Name = "GtkScrolledWindow4";
@@ -153,20 +145,28 @@
 			this.abilitiesList.HeadersVisible = false;
 			this.GtkScrolledWindow4.Add(this.abilitiesList);
 			this.table1.Add(this.GtkScrolledWindow4);
-			global::Gtk.Table.TableChild w15 = ((global::Gtk.Table.TableChild)(this.table1[this.GtkScrolledWindow4]));
-			w15.TopAttach = ((uint)(1));
-			w15.BottomAttach = ((uint)(2));
-			w15.LeftAttach = ((uint)(1));
-			w15.RightAttach = ((uint)(2));
-			w15.YOptions = ((global::Gtk.AttachOptions)(4));
+			global::Gtk.Table.TableChild w14 = ((global::Gtk.Table.TableChild)(this.table1[this.GtkScrolledWindow4]));
+			w14.TopAttach = ((uint)(1));
+			w14.BottomAttach = ((uint)(2));
+			w14.LeftAttach = ((uint)(1));
+			w14.RightAttach = ((uint)(2));
+			w14.YOptions = ((global::Gtk.AttachOptions)(4));
 			// Container child table1.Gtk.Table+TableChild
 			this.lblAbilities = new global::IBBoard.GtkSharp.Translatable.TranslatableLabel();
 			this.lblAbilities.Name = "lblAbilities";
 			this.lblAbilities.LabelProp = global::Mono.Unix.Catalog.GetString("abilities:");
 			this.table1.Add(this.lblAbilities);
-			global::Gtk.Table.TableChild w16 = ((global::Gtk.Table.TableChild)(this.table1[this.lblAbilities]));
-			w16.TopAttach = ((uint)(1));
-			w16.BottomAttach = ((uint)(2));
+			global::Gtk.Table.TableChild w15 = ((global::Gtk.Table.TableChild)(this.table1[this.lblAbilities]));
+			w15.TopAttach = ((uint)(1));
+			w15.BottomAttach = ((uint)(2));
+			w15.XOptions = ((global::Gtk.AttachOptions)(4));
+			w15.YOptions = ((global::Gtk.AttachOptions)(4));
+			// Container child table1.Gtk.Table+TableChild
+			this.lblEquip = new global::IBBoard.GtkSharp.Translatable.TranslatableLabel();
+			this.lblEquip.Name = "lblEquip";
+			this.lblEquip.LabelProp = global::Mono.Unix.Catalog.GetString("equipment:");
+			this.table1.Add(this.lblEquip);
+			global::Gtk.Table.TableChild w16 = ((global::Gtk.Table.TableChild)(this.table1[this.lblEquip]));
 			w16.XOptions = ((global::Gtk.AttachOptions)(4));
 			w16.YOptions = ((global::Gtk.AttachOptions)(4));
 			// Container child table1.Gtk.Table+TableChild
@@ -187,49 +187,49 @@
 			this.vbox3.Name = "vbox3";
 			this.vbox3.Spacing = 6;
 			// Container child vbox3.Gtk.Box+BoxChild
-			this.bttnAddEquipment = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
-			this.bttnAddEquipment.CanFocus = true;
-			this.bttnAddEquipment.Name = "bttnAddEquipment";
-			this.bttnAddEquipment.UseUnderline = true;
-			this.bttnAddEquipment.Label = global::Mono.Unix.Catalog.GetString("add");
-			this.vbox3.Add(this.bttnAddEquipment);
-			global::Gtk.Box.BoxChild w19 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnAddEquipment]));
+			this.bttnAddWeapon = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
+			this.bttnAddWeapon.CanFocus = true;
+			this.bttnAddWeapon.Name = "bttnAddWeapon";
+			this.bttnAddWeapon.UseUnderline = true;
+			this.bttnAddWeapon.Label = global::Mono.Unix.Catalog.GetString("add");
+			this.vbox3.Add(this.bttnAddWeapon);
+			global::Gtk.Box.BoxChild w19 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnAddWeapon]));
 			w19.Position = 0;
 			w19.Expand = false;
 			w19.Fill = false;
 			// Container child vbox3.Gtk.Box+BoxChild
-			this.bttnEditEquipment = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
-			this.bttnEditEquipment.Sensitive = false;
-			this.bttnEditEquipment.CanFocus = true;
-			this.bttnEditEquipment.Name = "bttnEditEquipment";
-			this.bttnEditEquipment.UseUnderline = true;
-			this.bttnEditEquipment.Label = global::Mono.Unix.Catalog.GetString("edit");
-			this.vbox3.Add(this.bttnEditEquipment);
-			global::Gtk.Box.BoxChild w20 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnEditEquipment]));
+			this.bttnEditWeapon = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
+			this.bttnEditWeapon.Sensitive = false;
+			this.bttnEditWeapon.CanFocus = true;
+			this.bttnEditWeapon.Name = "bttnEditWeapon";
+			this.bttnEditWeapon.UseUnderline = true;
+			this.bttnEditWeapon.Label = global::Mono.Unix.Catalog.GetString("edit");
+			this.vbox3.Add(this.bttnEditWeapon);
+			global::Gtk.Box.BoxChild w20 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnEditWeapon]));
 			w20.Position = 1;
 			w20.Expand = false;
 			w20.Fill = false;
 			// Container child vbox3.Gtk.Box+BoxChild
-			this.bttnReplaceEquipment = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
-			this.bttnReplaceEquipment.Sensitive = false;
-			this.bttnReplaceEquipment.CanFocus = true;
-			this.bttnReplaceEquipment.Name = "bttnReplaceEquipment";
-			this.bttnReplaceEquipment.UseUnderline = true;
-			this.bttnReplaceEquipment.Label = global::Mono.Unix.Catalog.GetString("replace");
-			this.vbox3.Add(this.bttnReplaceEquipment);
-			global::Gtk.Box.BoxChild w21 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnReplaceEquipment]));
+			this.bttnReplaceWeapon = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
+			this.bttnReplaceWeapon.Sensitive = false;
+			this.bttnReplaceWeapon.CanFocus = true;
+			this.bttnReplaceWeapon.Name = "bttnReplaceWeapon";
+			this.bttnReplaceWeapon.UseUnderline = true;
+			this.bttnReplaceWeapon.Label = global::Mono.Unix.Catalog.GetString("replace");
+			this.vbox3.Add(this.bttnReplaceWeapon);
+			global::Gtk.Box.BoxChild w21 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnReplaceWeapon]));
 			w21.Position = 2;
 			w21.Expand = false;
 			w21.Fill = false;
 			// Container child vbox3.Gtk.Box+BoxChild
-			this.bttnRemoveEquipment = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
-			this.bttnRemoveEquipment.Sensitive = false;
-			this.bttnRemoveEquipment.CanFocus = true;
-			this.bttnRemoveEquipment.Name = "bttnRemoveEquipment";
-			this.bttnRemoveEquipment.UseUnderline = true;
-			this.bttnRemoveEquipment.Label = global::Mono.Unix.Catalog.GetString("remove");
-			this.vbox3.Add(this.bttnRemoveEquipment);
-			global::Gtk.Box.BoxChild w22 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnRemoveEquipment]));
+			this.bttnRemoveWeapon = new global::IBBoard.GtkSharp.Translatable.TranslatableButton();
+			this.bttnRemoveWeapon.Sensitive = false;
+			this.bttnRemoveWeapon.CanFocus = true;
+			this.bttnRemoveWeapon.Name = "bttnRemoveWeapon";
+			this.bttnRemoveWeapon.UseUnderline = true;
+			this.bttnRemoveWeapon.Label = global::Mono.Unix.Catalog.GetString("remove");
+			this.vbox3.Add(this.bttnRemoveWeapon);
+			global::Gtk.Box.BoxChild w22 = ((global::Gtk.Box.BoxChild)(this.vbox3[this.bttnRemoveWeapon]));
 			w22.Position = 3;
 			w22.Expand = false;
 			w22.Fill = false;
@@ -253,10 +253,10 @@
 			this.unitName.KeyPressEvent += new global::Gtk.KeyPressEventHandler(this.OnUnitNameKeyPress);
 			this.unitSize.FocusOutEvent += new global::Gtk.FocusOutEventHandler(this.OnUnitSizeFocusOut);
 			this.unitSize.KeyPressEvent += new global::Gtk.KeyPressEventHandler(this.OnUnitSizeKeyPress);
-			this.bttnAddEquipment.Clicked += new global::System.EventHandler(this.OnBttnAddEquipmentClicked);
-			this.bttnEditEquipment.Clicked += new global::System.EventHandler(this.HandleEditButtonClicked);
-			this.bttnReplaceEquipment.Clicked += new global::System.EventHandler(this.HandleReplaceButtonClicked);
-			this.bttnRemoveEquipment.Clicked += new global::System.EventHandler(this.HandleRemoveButtonActivated);
+			this.bttnAddWeapon.Clicked += new global::System.EventHandler(this.OnBttnAddEquipmentClicked);
+			this.bttnEditWeapon.Clicked += new global::System.EventHandler(this.HandleEditButtonClicked);
+			this.bttnReplaceWeapon.Clicked += new global::System.EventHandler(this.HandleReplaceButtonClicked);
+			this.bttnRemoveWeapon.Clicked += new global::System.EventHandler(this.HandleRemoveButtonActivated);
 		}
 	}
 }
--- a/gtk-gui/gui.stetic	Sat Jan 01 20:55:07 2011 +0000
+++ b/gtk-gui/gui.stetic	Sun Jan 02 15:12:31 2011 +0000
@@ -788,23 +788,6 @@
                 <property name="RowSpacing">6</property>
                 <property name="ColumnSpacing">6</property>
                 <child>
-                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableLabel" id="equipmentLabel">
-                    <property name="MemberName" />
-                    <property name="LabelProp" translatable="yes">equipment:</property>
-                  </widget>
-                  <packing>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
                   <widget class="Gtk.ScrolledWindow" id="GtkScrolledWindow2">
                     <property name="MemberName" />
                     <property name="ShadowType">In</property>
@@ -907,6 +890,23 @@
                   </packing>
                 </child>
                 <child>
+                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableLabel" id="lblEquip">
+                    <property name="MemberName" />
+                    <property name="LabelProp" translatable="yes">equipment:</property>
+                  </widget>
+                  <packing>
+                    <property name="AutoSize">True</property>
+                    <property name="XOptions">Fill</property>
+                    <property name="YOptions">Fill</property>
+                    <property name="XExpand">False</property>
+                    <property name="XFill">True</property>
+                    <property name="XShrink">False</property>
+                    <property name="YExpand">False</property>
+                    <property name="YFill">True</property>
+                    <property name="YShrink">False</property>
+                  </packing>
+                </child>
+                <child>
                   <widget class="IBBoard.GtkSharp.Translatable.TranslatableLabel" id="lblNotes">
                     <property name="MemberName" />
                     <property name="LabelProp" translatable="yes">notes:</property>
@@ -936,7 +936,7 @@
                 <property name="MemberName" />
                 <property name="Spacing">6</property>
                 <child>
-                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnAddEquipment">
+                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnAddWeapon">
                     <property name="MemberName" />
                     <property name="CanFocus">True</property>
                     <property name="Type">TextOnly</property>
@@ -952,7 +952,7 @@
                   </packing>
                 </child>
                 <child>
-                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnEditEquipment">
+                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnEditWeapon">
                     <property name="MemberName" />
                     <property name="Sensitive">False</property>
                     <property name="CanFocus">True</property>
@@ -969,7 +969,7 @@
                   </packing>
                 </child>
                 <child>
-                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnReplaceEquipment">
+                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnReplaceWeapon">
                     <property name="MemberName" />
                     <property name="Sensitive">False</property>
                     <property name="CanFocus">True</property>
@@ -986,7 +986,7 @@
                   </packing>
                 </child>
                 <child>
-                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnRemoveEquipment">
+                  <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnRemoveWeapon">
                     <property name="MemberName" />
                     <property name="Sensitive">False</property>
                     <property name="CanFocus">True</property>
@@ -2328,7 +2328,7 @@
         <property name="Size">1</property>
         <property name="LayoutStyle">End</property>
         <child>
-          <widget class="Gtk.Button" id="bttnClose">
+          <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnClose">
             <property name="MemberName" />
             <property name="CanDefault">True</property>
             <property name="CanFocus">True</property>
@@ -2348,7 +2348,10 @@
   </widget>
   <widget class="Gtk.Dialog" id="IBBoard.WarFoundry.GUI.GTK.FrmPreferences" design-size="400 300">
     <property name="MemberName" />
+    <property name="TypeHint">Dialog</property>
     <property name="WindowPosition">CenterOnParent</property>
+    <property name="SkipPagerHint">True</property>
+    <property name="SkipTaskbarHint">True</property>
     <property name="Buttons">2</property>
     <property name="HelpButton">False</property>
     <child internal-child="VBox">
@@ -2477,7 +2480,7 @@
         <property name="Size">2</property>
         <property name="LayoutStyle">End</property>
         <child>
-          <widget class="Gtk.Button" id="bttnCancel">
+          <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnCancel">
             <property name="MemberName" />
             <property name="CanDefault">True</property>
             <property name="CanFocus">True</property>
@@ -2494,7 +2497,7 @@
           </packing>
         </child>
         <child>
-          <widget class="Gtk.Button" id="bttnOkay">
+          <widget class="IBBoard.GtkSharp.Translatable.TranslatableButton" id="bttnOkay">
             <property name="MemberName" />
             <property name="CanDefault">True</property>
             <property name="CanFocus">True</property>
--- a/translations/en.translation	Sat Jan 01 20:55:07 2011 +0000
+++ b/translations/en.translation	Sun Jan 02 15:12:31 2011 +0000
@@ -28,15 +28,16 @@
 <translation id="bttnCancel">Cancel</translation>
 <translation id="buttonCancel">Cancel</translation>
 <translation id="buttonOk">OK</translation>
+<translation id="bttnOkay">OK</translation>
 <translation id="bttnSelectSystem">Select system</translation>
 <translation id="saveArmyDialog">Save army</translation>
 <translation id="defaultUnitName">Unit of {0} {1}</translation>
 <translation id="statusPanelPoints">{0} pts / {1} pts</translation>
-<translation id="bttnAddEquipment">Add</translation>
-<translation id="bttnEditEquipment">Edit</translation>
-<translation id="bttnRemoveEquipment">Remove</translation>
-<translation id="bttnReplaceEquipment">Replace</translation>
-<translation id="equipmentLabel">Equipment:</translation>
+<translation id="bttnAddWeapon">Add</translation>
+<translation id="bttnEditWeapon">Edit</translation>
+<translation id="bttnRemoveWeapon">Remove</translation>
+<translation id="bttnReplaceWeapon">Replace</translation>
+<translation id="lblEquip">Equipment:</translation>
 <translation id="lblAbilities">Abilities:</translation>
 <translation id="lblNotes">Notes:</translation>
 <translation id="IBBoard.WarFoundry.GUI.GTK.FrmNewArmy">Create Army</translation>
@@ -65,6 +66,7 @@
 <translation id="lblEquipment">Equipment:</translation>
 <translation id="IBBoard.WarFoundry.GUI.GTK.FrmEditEquipment">Edit Equipment</translation>
 <translation id="frmEditEquipmentColumnTitle">Equipment</translation>
+<translation id="IBBoard.WarFoundry.GUI.GTK.FrmReplaceEquipment">Replace Equipment</translation>
 <translation id="IBBoard.WarFoundry.GUI.GTK.FrmAbout">About WarFoundry</translation>
 <translation id="bttnClose">Close</translation>
 <translation id="bttnCredits">Credits</translation>
--- a/translations/fr.translation	Sat Jan 01 20:55:07 2011 +0000
+++ b/translations/fr.translation	Sun Jan 02 15:12:31 2011 +0000
@@ -1,5 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <translations xmlns="http://ibboard.co.uk/translation" lang="fr">
+	<!-- This sample translation is based on the original French translation for the WinForms interface, plus additional translations made using Google Translate by IBBoard -->
 	<translation id="menuFile">_Fichier</translation>
 	<translation id="menuEdit">_Édition</translation>
 	<translation id="menuHelp">_Aide</translation>
@@ -108,10 +109,19 @@
 	<translation id="requirementUnitTypeAtLeastSingle">{1} {0}</translation>
 	<translation id="requirementUnitTypeAtLeastJoiner">{0}, {1}</translation>
 	<translation id="requirementUnitTypeAtLeast">{0} peut être sélectionné seulement si l'objet suivant est sélectionné : {1}</translation>
-<!-- TODO -->
-<translation id="IBBoard.WarFoundry.GUI.GTK.FrmPreferences">Preferences</translation>
-<translation id="languagePrefSection">Language</translation>
-<translation id="lblLanguage">Language:</translation>
-<translation id="languagesGroup">Language</translation>
-<translation id="miPreferences">_Preferences</translation>
+<!-- TODO: Check and/or correct the following additions -->
+<translation id="IBBoard.WarFoundry.GUI.GTK.FrmPreferences">Préférences</translation>
+<translation id="languagePrefSection">Langue</translation>
+<translation id="lblLanguage">Langue:</translation>
+<translation id="languagesGroup">Langue</translation>
+<translation id="miPreferences">_Préférences</translation>
+<translation id="bttnCredits">Crédits</translation>
+<translation id="lblWarFoundryCopyright">© 2007-2011, IBBoard et d'autres</translation>
+<translation id="lblWarFoundryDesc">WarFoundry est un outil open-source de création de l'armée qui vous permet de créer des listes pour les systèmes de jeu multiples.</translation>
+<translation id="IBBoard.WarFoundry.GUI.GTK.FrmAboutCredits">Crédits</translation>
+<translation id="lblTestersCommon">Testeurs (WarFoundry général):</translation>
+<translation id="lblTestersGtk">Testeurs (interface utilisateur):</translation>
+<translation id="bttnClose">Fermer</translation>
+<translation id="armyCategoryColumnTitle">Catégories de l'armée</translation>
+<translation id="IBBoard.WarFoundry.GUI.GTK.FrmReplaceEquipment">Remplacer l'équipement pour unité</translation>
 </translations>