Mercurial > repos > IBBoard.WarFoundry.GUI.GTK
changeset 156:08b30dc56af4
Re #417: Improve WarFoundry installation experience
* Make it more obvious how to get data files in GTK# UI
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Sat, 12 May 2012 20:11:33 +0100 |
parents | 7b091ea86819 |
children | 2d1dd73a3289 |
files | gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmNewArmy.cs gtk-gui/gui.stetic |
diffstat | 2 files changed, 107 insertions(+), 65 deletions(-) [+] |
line wrap: on
line diff
--- a/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmNewArmy.cs Sat May 12 19:56:24 2012 +0100 +++ b/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmNewArmy.cs Sat May 12 20:11:33 2012 +0100 @@ -12,9 +12,11 @@ private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblArmyName; private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblArmySize; private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblGameSystem; - private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblRaceList; private global::Gtk.ComboBoxEntry systemCombo; private global::Gtk.Entry txtArmyName; + private global::Gtk.VBox vbox2; + private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblRaceList; + private global::Gtk.Label lblGetMore; private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnCancel; private global::IBBoard.GtkSharp.Translatable.TranslatableButton bttnCreate; @@ -63,7 +65,6 @@ w3.LeftAttach = ((uint)(1)); w3.RightAttach = ((uint)(2)); w3.XOptions = ((global::Gtk.AttachOptions)(4)); - w3.YOptions = ((global::Gtk.AttachOptions)(4)); // Container child table1.Gtk.Table+TableChild this.hbox2 = new global::Gtk.HBox (); this.hbox2.Name = "hbox2"; @@ -118,23 +119,13 @@ w8.XOptions = ((global::Gtk.AttachOptions)(4)); w8.YOptions = ((global::Gtk.AttachOptions)(4)); // Container child table1.Gtk.Table+TableChild - this.lblRaceList = new global::IBBoard.GtkSharp.Translatable.TranslatableLabel (); - this.lblRaceList.Name = "lblRaceList"; - this.lblRaceList.LabelProp = global::Mono.Unix.Catalog.GetString ("race"); - this.table1.Add (this.lblRaceList); - global::Gtk.Table.TableChild w9 = ((global::Gtk.Table.TableChild)(this.table1 [this.lblRaceList])); - w9.TopAttach = ((uint)(1)); - w9.BottomAttach = ((uint)(2)); - w9.XOptions = ((global::Gtk.AttachOptions)(4)); - w9.YOptions = ((global::Gtk.AttachOptions)(4)); - // Container child table1.Gtk.Table+TableChild this.systemCombo = global::Gtk.ComboBoxEntry.NewText (); this.systemCombo.Name = "systemCombo"; this.table1.Add (this.systemCombo); - global::Gtk.Table.TableChild w10 = ((global::Gtk.Table.TableChild)(this.table1 [this.systemCombo])); - w10.LeftAttach = ((uint)(1)); - w10.RightAttach = ((uint)(2)); - w10.YOptions = ((global::Gtk.AttachOptions)(4)); + global::Gtk.Table.TableChild w9 = ((global::Gtk.Table.TableChild)(this.table1 [this.systemCombo])); + w9.LeftAttach = ((uint)(1)); + w9.RightAttach = ((uint)(2)); + w9.YOptions = ((global::Gtk.AttachOptions)(4)); // Container child table1.Gtk.Table+TableChild this.txtArmyName = new global::Gtk.Entry (); this.txtArmyName.CanFocus = true; @@ -142,27 +133,53 @@ this.txtArmyName.IsEditable = true; this.txtArmyName.InvisibleChar = '#'; this.table1.Add (this.txtArmyName); - global::Gtk.Table.TableChild w11 = ((global::Gtk.Table.TableChild)(this.table1 [this.txtArmyName])); - w11.TopAttach = ((uint)(2)); - w11.BottomAttach = ((uint)(3)); - w11.LeftAttach = ((uint)(1)); - w11.RightAttach = ((uint)(2)); - w11.XOptions = ((global::Gtk.AttachOptions)(4)); - w11.YOptions = ((global::Gtk.AttachOptions)(4)); - w1.Add (this.table1); - global::Gtk.Box.BoxChild w12 = ((global::Gtk.Box.BoxChild)(w1 [this.table1])); - w12.Position = 0; + global::Gtk.Table.TableChild w10 = ((global::Gtk.Table.TableChild)(this.table1 [this.txtArmyName])); + w10.TopAttach = ((uint)(2)); + w10.BottomAttach = ((uint)(3)); + w10.LeftAttach = ((uint)(1)); + w10.RightAttach = ((uint)(2)); + w10.XOptions = ((global::Gtk.AttachOptions)(4)); + w10.YOptions = ((global::Gtk.AttachOptions)(4)); + // Container child table1.Gtk.Table+TableChild + this.vbox2 = new global::Gtk.VBox (); + this.vbox2.Name = "vbox2"; + this.vbox2.Spacing = 6; + // Container child vbox2.Gtk.Box+BoxChild + this.lblRaceList = new global::IBBoard.GtkSharp.Translatable.TranslatableLabel (); + this.lblRaceList.Name = "lblRaceList"; + this.lblRaceList.LabelProp = global::Mono.Unix.Catalog.GetString ("race"); + this.vbox2.Add (this.lblRaceList); + global::Gtk.Box.BoxChild w11 = ((global::Gtk.Box.BoxChild)(this.vbox2 [this.lblRaceList])); + w11.Position = 0; + w11.Expand = false; + w11.Fill = false; + // Container child vbox2.Gtk.Box+BoxChild + this.lblGetMore = new global::Gtk.Label (); + this.lblGetMore.Name = "lblGetMore"; + this.lblGetMore.LabelProp = global::Mono.Unix.Catalog.GetString ("<a href=\"http://warfoundry.co.uk/Downloads/datafiles/\">Get more</a>"); + this.lblGetMore.UseMarkup = true; + this.vbox2.Add (this.lblGetMore); + global::Gtk.Box.BoxChild w12 = ((global::Gtk.Box.BoxChild)(this.vbox2 [this.lblGetMore])); + w12.Position = 1; w12.Expand = false; w12.Fill = false; - w12.Padding = ((uint)(6)); + this.table1.Add (this.vbox2); + global::Gtk.Table.TableChild w13 = ((global::Gtk.Table.TableChild)(this.table1 [this.vbox2])); + w13.TopAttach = ((uint)(1)); + w13.BottomAttach = ((uint)(2)); + w13.XOptions = ((global::Gtk.AttachOptions)(4)); + w1.Add (this.table1); + global::Gtk.Box.BoxChild w14 = ((global::Gtk.Box.BoxChild)(w1 [this.table1])); + w14.Position = 0; + w14.Padding = ((uint)(6)); // Internal child IBBoard.WarFoundry.GUI.GTK.FrmNewArmy.ActionArea - global::Gtk.HButtonBox w13 = this.ActionArea; - w13.CanFocus = true; - w13.Events = ((global::Gdk.EventMask)(256)); - w13.Name = "WarFoundrySharp.FrmNewArmy_ActionArea"; - w13.Spacing = 6; - w13.BorderWidth = ((uint)(5)); - w13.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(4)); + global::Gtk.HButtonBox w15 = this.ActionArea; + w15.CanFocus = true; + w15.Events = ((global::Gdk.EventMask)(256)); + w15.Name = "WarFoundrySharp.FrmNewArmy_ActionArea"; + w15.Spacing = 6; + w15.BorderWidth = ((uint)(5)); + w15.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(4)); // Container child WarFoundrySharp.FrmNewArmy_ActionArea.Gtk.ButtonBox+ButtonBoxChild this.bttnCancel = new global::IBBoard.GtkSharp.Translatable.TranslatableButton (); this.bttnCancel.CanFocus = true; @@ -171,9 +188,9 @@ this.bttnCancel.UseUnderline = true; this.bttnCancel.Label = "gtk-cancel"; this.AddActionWidget (this.bttnCancel, -6); - global::Gtk.ButtonBox.ButtonBoxChild w14 = ((global::Gtk.ButtonBox.ButtonBoxChild)(w13 [this.bttnCancel])); - w14.Expand = false; - w14.Fill = false; + global::Gtk.ButtonBox.ButtonBoxChild w16 = ((global::Gtk.ButtonBox.ButtonBoxChild)(w15 [this.bttnCancel])); + w16.Expand = false; + w16.Fill = false; // Container child WarFoundrySharp.FrmNewArmy_ActionArea.Gtk.ButtonBox+ButtonBoxChild this.bttnCreate = new global::IBBoard.GtkSharp.Translatable.TranslatableButton (); this.bttnCreate.Sensitive = false; @@ -184,10 +201,10 @@ this.bttnCreate.UseUnderline = true; this.bttnCreate.Label = "gtk-ok"; this.AddActionWidget (this.bttnCreate, -5); - global::Gtk.ButtonBox.ButtonBoxChild w15 = ((global::Gtk.ButtonBox.ButtonBoxChild)(w13 [this.bttnCreate])); - w15.Position = 1; - w15.Expand = false; - w15.Fill = false; + global::Gtk.ButtonBox.ButtonBoxChild w17 = ((global::Gtk.ButtonBox.ButtonBoxChild)(w15 [this.bttnCreate])); + w17.Position = 1; + w17.Expand = false; + w17.Fill = false; if ((this.Child != null)) { this.Child.ShowAll (); }
--- a/gtk-gui/gui.stetic Sat May 12 19:56:24 2012 +0100 +++ b/gtk-gui/gui.stetic Sat May 12 20:11:33 2012 +0100 @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="utf-8"?> <stetic-interface> <configuration> - <images-root-path>..</images-root-path> + <images-root-path>../../IBBoard.WarFoundry.GUI.GTK</images-root-path> <target-gtk-version>2.12</target-gtk-version> </configuration> <import> @@ -365,11 +365,10 @@ <property name="RightAttach">2</property> <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="YExpand">True</property> <property name="YFill">True</property> <property name="YShrink">False</property> </packing> @@ -475,25 +474,6 @@ </packing> </child> <child> - <widget class="IBBoard.GtkSharp.Translatable.TranslatableLabel" id="lblRaceList"> - <property name="MemberName" /> - <property name="LabelProp" translatable="yes">race</property> - </widget> - <packing> - <property name="TopAttach">1</property> - <property name="BottomAttach">2</property> - <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.ComboBoxEntry" id="systemCombo"> <property name="MemberName" /> <property name="IsTextCombo">True</property> @@ -537,12 +517,57 @@ <property name="YShrink">False</property> </packing> </child> + <child> + <widget class="Gtk.VBox" id="vbox2"> + <property name="MemberName" /> + <property name="Spacing">6</property> + <child> + <widget class="IBBoard.GtkSharp.Translatable.TranslatableLabel" id="lblRaceList"> + <property name="MemberName" /> + <property name="LabelProp" translatable="yes">race</property> + </widget> + <packing> + <property name="Position">0</property> + <property name="AutoSize">True</property> + <property name="Expand">False</property> + <property name="Fill">False</property> + </packing> + </child> + <child> + <widget class="Gtk.Label" id="lblGetMore"> + <property name="MemberName" /> + <property name="Ypad">10</property> + <property name="LabelProp" translatable="yes"><a href="http://warfoundry.co.uk/Downloads/datafiles/">get more</a></property> + <property name="UseMarkup">True</property> + </widget> + <packing> + <property name="Position">1</property> + <property name="AutoSize">True</property> + <property name="Expand">False</property> + <property name="Fill">False</property> + </packing> + </child> + <child> + <placeholder /> + </child> + </widget> + <packing> + <property name="TopAttach">1</property> + <property name="BottomAttach">2</property> + <property name="AutoSize">True</property> + <property name="XOptions">Fill</property> + <property name="XExpand">False</property> + <property name="XFill">True</property> + <property name="XShrink">False</property> + <property name="YExpand">True</property> + <property name="YFill">True</property> + <property name="YShrink">False</property> + </packing> + </child> </widget> <packing> <property name="Position">0</property> <property name="AutoSize">True</property> - <property name="Expand">False</property> - <property name="Fill">False</property> <property name="Padding">6</property> </packing> </child>