Page MenuHomeWildfire Games

Move credits page tab style to Modern
ClosedPublic

Authored by elexis on Aug 12 2017, 2:13 PM.

Details

Summary

The idea behind our style files is that we use the same style throughout the GUI.
So if we want to use tab buttons in other places than the credits page (for example the options page),
we should move it to common/.

Test Plan

Make sure that you can still open the credits page.
Notice there should be the rename ForegroundBox -> TabForeground (same for background) in either this patch (credits.js) or D785.

Diff Detail

Repository
rP 0 A.D. Public Repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

elexis created this revision.Aug 12 2017, 2:13 PM
Vulcan added a subscriber: Vulcan.Aug 12 2017, 3:44 PM
Executing section Default...
Executing section Source...
Executing section JS...
Executing section XML GUI...
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/public/gui/credits/credits.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/public/gui/credits/credits.xml
|   1|   1| <?xml version="1.0" encoding="utf-8"?>
|   2|    |-
|   3|   2| <!--
|   4|   3| ==========================================
|   5|   4| - CREDITS PAGE -
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/public/gui/credits/credits.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/public/gui/credits/credits.xml
|   5|   5| - CREDITS PAGE -
|   6|   6| ==========================================
|   7|   7| -->
|   8|    |-
|   9|   8| <objects>
|  10|   9| 	<script file="gui/common/functions_global_object.js"/>
|  11|  10| 	<script directory="gui/credits/"/>
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/public/gui/credits/credits.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/public/gui/credits/credits.xml
|  28|  28| 		</object>
|  29|  29| 
|  30|  30| 		<object type="image" sprite="ModernFade" size="220 30 100%-20 100%-54">
|  31|    |-			<object name="creditsText" type="text" style="textPanel" scroll_top="true" />
|    |  31|+			<object name="creditsText" type="text" style="textPanel" scroll_top="true"/>
|  32|  32| 		</object>
|  33|  33| 
|  34|  34| 		<!-- Close dialog -->
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|   1|   1| <?xml version="1.0" encoding="utf-8"?>
|   2|    |-
|   3|   2| <!--
|   4|   3|   - This file contains the sprites for the 'modern' style GUI.
|   5|   4|   -
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|   4|   4|   - This file contains the sprites for the 'modern' style GUI.
|   5|   5|   -
|   6|   6|   -->
|   7|    |-
|   8|   7| <sprites>
|   9|   8| 
|  10|   9| 	<!--
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|  12|  12| 	- Scrollbar -
|  13|  13| 	==========================================
|  14|  14| 	-->
|  15|    |-	<sprite name = "ModernScrollBack">
|  16|    |-		<image backcolor="43 42 40"
|  17|    |-			size="0 0 100% 100%"
|  18|    |-			border="true"
|  19|    |-			bordercolor="0 0 0"
|  20|    |-		/>
|  21|    |-		<image texture = "global/modern/scrollback.png"
|  22|    |-			real_texture_placement = "0 0 15 128"
|  23|    |-			size = "0 0 100% 100%"
|  24|    |-		/>
|  25|    |-	</sprite>
|  26|    |-	<sprite name = "ModernScrollBar">
|  27|    |-		<image texture = "global/modern/scrollbar.png"
|  28|    |-			real_texture_placement = "0 0 15 15"
|  29|    |-			size = "0 0 100% 100%"
|  30|    |-		/>
|    |  15|+	<sprite name="ModernScrollBack">
|    |  16|+		<image backcolor="43 42 40" size="0 0 100% 100%" border="true" bordercolor="0 0 0"/>
|    |  17|+		<image texture="global/modern/scrollback.png" real_texture_placement="0 0 15 128" size="0 0 100% 100%"/>
|    |  18|+	</sprite>
|    |  19|+	<sprite name="ModernScrollBar">
|    |  20|+		<image texture="global/modern/scrollbar.png" real_texture_placement="0 0 15 15" size="0 0 100% 100%"/>
|  31|  21| 	</sprite>
|  32|  22| 	<!--
|  33|  23| 	==========================================
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|  34|  34| 	- Window -
|  35|  35| 	==========================================
|  36|  36| 	-->
|  37|    |-	<sprite name = "ModernWindow">
|    |  37|+	<sprite name="ModernWindow">
|  38|  38| 
|  39|  39| 		<!-- background -->
|  40|    |-		<image backcolor = "12 12 12"/>
|  41|    |-		<image texture = "global/modern/background.png"
|  42|    |-			texture_size = "0 0 1024 1024"
|  43|    |-			size = "12 22 100%-12 100%-12"
|  44|    |-		/>
|    |  40|+		<image backcolor="12 12 12"/>
|    |  41|+		<image texture="global/modern/background.png" texture_size="0 0 1024 1024" size="12 22 100%-12 100%-12"/>
|  45|  42| 
|  46|  43| 		<!-- shading -->
|  47|  44| 		<!-- we just mirror the same texture on the top and bottom -->
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|  45|  45| 
|  46|  46| 		<!-- shading -->
|  47|  47| 		<!-- we just mirror the same texture on the top and bottom -->
|  48|    |-		<image texture = "global/modern/shadow-high.png"
|  49|    |-			texture_size = "0 0 1024 256"
|  50|    |-			size = "12 100%-268 100%-12 100%-12"
|  51|    |-		/>
|  52|    |-
|  53|    |-		<image texture = "global/modern/shadow-high.png"
|  54|    |-			texture_size = "1024 256 0 0"
|  55|    |-			size = "12 22 100%-12 268"
|  56|    |-		/>
|    |  48|+		<image texture="global/modern/shadow-high.png" texture_size="0 0 1024 256" size="12 100%-268 100%-12 100%-12"/>
|    |  49|+
|    |  50|+		<image texture="global/modern/shadow-high.png" texture_size="1024 256 0 0" size="12 22 100%-12 268"/>
|  57|  51| 
|  58|  52| 		<!-- top and bottom edge -->
|  59|  53| 		<image texture = "global/modern/border.png"
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|  56|  56| 		/>
|  57|  57| 
|  58|  58| 		<!-- top and bottom edge -->
|  59|    |-		<image texture = "global/modern/border.png"
|  60|    |-			real_texture_placement = "0 0 2048 8"
|  61|    |-			size = "10 18 100%-10 26"
|  62|    |-		/>
|  63|    |-		<image texture = "global/modern/border.png"
|  64|    |-			real_texture_placement = "0 0 2048 8"
|  65|    |-			size = "10 100%-16 100%-10 100%-8"
|  66|    |-		/>
|    |  59|+		<image texture="global/modern/border.png" real_texture_placement="0 0 2048 8" size="10 18 100%-10 26"/>
|    |  60|+		<image texture="global/modern/border.png" real_texture_placement="0 0 2048 8" size="10 100%-16 100%-10 100%-8"/>
|  67|  61| 
|  68|  62| 		<!-- title frame -->
|  69|  63| 		<image texture = "global/modern/titlebar-middle.png"
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/sprites.xml
|  66|  66| 		/>
|  67|  67| 
|  68|  68| 		<!-- title frame -->
|  69|    |-		<image texture = "global/modern/titlebar-middle.png"
|  70|    |-			real_texture_placement = "0 0 128 32"
|  71|    |-			size = "50%-128 4 50%+128 37"
|  72|    |-		/>
|  73|    |-		<image texture = "global/modern/titlebar-left

http://jw:8080/job/phabricator_lint/387/ for more details.

Build is green

Updating workspaces.
Build (release)...
Build (debug)...
Running release tests...
Running cxxtest tests (306 tests)..................................................................................................................................................................................................................................................................................................................OK!
Running debug tests...
Running cxxtest tests (306 tests)..................................................................................................................................................................................................................................................................................................................OK!
Checking XML files...

http://jw:8080/job/phabricator/1847/ for more details.

vladislavbelov accepted this revision.Aug 13 2017, 9:52 PM
This revision is now accepted and ready to land.Aug 13 2017, 9:52 PM
bb requested changes to this revision.Aug 17 2017, 3:00 PM
bb added a subscriber: bb.

the ForegoundBox is declared in the summary already with the same values (not sure if BackGroundTab == TabBackground also), so merge those.

This revision now requires changes to proceed.Aug 17 2017, 3:00 PM
In D786#31549, @bb wrote:

the ForegoundBox is declared in the summary already with the same values (not sure if BackGroundTab == TabBackground also), so merge those.

There're not the same, it has different values and the summary ones hasn't a one line. Also I think it has different meanings.

After the showcased bugfix, we still can't merge the pages because, as Vladislav said, the summary screen button styles only work for horizontal alignment on that specific page.

If we wanted to recreate the summary screen style on this page, then

  1. we'd need a border around the list of names and
  2. The tab button background color must be equal to the credit namelist background color.

It is usually expected that

  1. The selected tab button is lighter than the unselected one.

The summary page solves this by having the content background-color lighter than the surrounding background color.
But here we have the opposite - dark gray on light gray.

So I'm going to either add more GUI elements to the credits page or rename the styles.

binaries/data/mods/mod/gui/common/modern/sprites.xml
735 ↗(On Diff #3091)

Every tab button here and in the summary screen has 4 lines making up that border.

This credits page TabForeground style only has 3 lines (top line missing).

That last line here logically contradicts the first line (both set the background color) and
if that last 100% here is changed to a 2, then the missing "top" line magically reappears and the credits tabs don't look as ugly anymore too.

Mentioned bugfix / screenshot reproduce:

diff --git a/binaries/data/mods/public/gui/credits/sprites.xml b/binaries/data/mods/public/gui/credits/sprites.xml
index a9eda6f..50e2ab4 100644
--- a/binaries/data/mods/public/gui/credits/sprites.xml
+++ b/binaries/data/mods/public/gui/credits/sprites.xml
@@ -2,18 +2,28 @@
 
 <sprites>
        <sprite name="BackgroundBox">
+               <!-- Semi-transparent golden background -->
                <image backcolor="50 35 0 120" size="0 0 100% 100%"/>
+               <!-- Left -->
                <image backcolor="gold" size="0 0 1 100%"/>
+               <!-- Top -->
                <image backcolor="gold" size="1 0 100%-1 1"/>
+               <!-- Right -->
                <image backcolor="gold" size="100%-1 0 100% 100%"/>
+               <!-- Bottom -->
                <image backcolor="gold" size="0 100%-1 100% 100%"/>
        </sprite>
 
        <sprite name="ForegroundBox">
+               <!-- Enlighten background slightly -->
                <image backcolor="255 255 255 40" size="0 0 100% 100%"/>
+               <!-- Left -->
                <image backcolor="gold" size="0 0 2 100%"/>
+               <!-- Bottom -->
                <image backcolor="gold" size="2 100%-2 100%-2 100%"/>
+               <!-- Right -->
                <image backcolor="gold" size="100%-2 0 100% 100%"/>
-               <image backcolor="gold" size="0 0 100% 100%"/>
+               <!-- Top -->
+               <image backcolor="gold" size="2 0 100%-2 2"/>
        </sprite>
 </sprites>
elexis updated this revision to Diff 3175.Aug 19 2017, 4:29 AM
elexis edited edge metadata.

Fix the graphics bug in the credits page ForegroundBox style (the last image of the sprite overwrites all prior properties).
So the page will look like on the screenshot after this fix.

Remove the unused ForegroundBox style from the summary screen.

The credits page (vertical) style will be reused by the options page tabbing and is likely to be reused in other cases too.
The summary screen (horizontal) style needs the adjustTabDividers JS code to work. It won't be trivial to reproduce on another page.
But if we use another horizontal style sometime, it should reuse the same style.
Therefore, move both tab styles to the Modern theme.

Build is green

Updating workspaces.
Build (release)...
Build (debug)...
Running release tests...
Running cxxtest tests (306 tests)..................................................................................................................................................................................................................................................................................................................OK!
Running debug tests...
Running cxxtest tests (306 tests)..................................................................................................................................................................................................................................................................................................................OK!
Checking XML files...

http://jw:8080/job/phabricator/1877/ for more details.

Executing section Default...
Executing section Source...
Executing section JS...

binaries/data/mods/public/gui/credits/credits.js
|  41| »   »   button.onPress·=·(i·=>·function()·{selectPanel(i);})(i);
|    | [NORMAL] ESLintBear (no-shadow):
|    | 'i' is already declared in the upper scope.

binaries/data/mods/public/gui/credits/credits.js
|  41| »   »   button.onPress·=·(i·=>·function()·{selectPanel(i);})(i);
|    | [NORMAL] JSHintBear:
|    | Don't make functions within a loop.

binaries/data/mods/public/gui/summary/summary.js
| 154| »   [0,·1].forEach(i·=>·Engine.GetGUIObjectByName("chart["·+·i·+·"]").series_color·=·player_colors);
|    | [NORMAL] ESLintBear (no-return-assign):
|    | Arrow function should not return assignment.

binaries/data/mods/public/gui/summary/summary.js
| 437| »   let·mapType·=·g_Settings.MapTypes.find(mapType·=>·mapType.Name·==·g_GameData.sim.mapSettings.mapType);
|    | [NORMAL] ESLintBear (no-shadow):
|    | 'mapType' is already declared in the upper scope.

binaries/data/mods/public/gui/summary/summary.js
|  17| }
|    | [NORMAL] JSHintBear:
|    | Missing semicolon.
Executing section XML GUI...
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/styles.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/styles.xml
|   1|    |-<?xml version = "1.0" encoding = "utf-8"?>
|   2|    |-
|    |   1|+<?xml version="1.0" encoding="utf-8"?>
|   3|   2| <styles>
|   4|   3| 	<!--
|   5|   4| 	==========================================
|    | [INFO] XMLBear:
|    | XML can be formatted better.
|----|    | /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/styles.xml
|    |++++| /mnt/data/jenkins-phabricator/workspace/phabricator_lint/binaries/data/mods/mod/gui/common/modern/styles.xml
|   7|   7| 	- be called by every object before any other style is loaded.
|   8|   8| 	==========================================
|   9|   9| 	-->
|  10|    |-	<style name="default"
|  11|    |-		absolute="false"
|  12|    |-		enabled="true"
|  13|    |-		ghost="false"
|  14|    |-		hidden="false"
|  15|    |-		size="0 0 100% 100%"
|  16|    |-		z="0"
|  17|    |-		font="sans-14"
|  18|    |-		buffer_zone="5"
|  19|    |-		multiline="false"
|  20|    |-	/>
|  21|    |-	<style name = "ModernWindow"
|  22|    |-		sprite = "ModernWindow"
|  23|    |-		buffer_zone = "12"
|  24|    |-		text_align = "left"
|  25|    |-		text_valign = "top"
|  26|    |-	/>
|  27|    |-	<style name = "ModernDialog"
|  28|    |-		sprite = "ModernDialog"
|  29|    |-		buffer_zone = "12"
|  30|    |-		text_align = "left"
|  31|    |-		text_valign = "top"
|  32|    |-	/>
|  33|    |-	<style name = "ModernList"
|  34|    |-		buffer_zone = "5"
|  35|    |-		font = "sans-bold-stroke-14"
|  36|    |-		heading_height="25"
|  37|    |-		scrollbar = "true"
|  38|    |-		scrollbar_style = "ModernScrollBar"
|  39|    |-		sprite = "ModernDarkBoxGoldNoTop"
|  40|    |-		sprite_selectarea = "ModernDarkBoxWhite"
|  41|    |-		sprite_heading = "ModernDarkBoxGoldNoBottom"
|  42|    |-		textcolor = "white"
|  43|    |-		textcolor_selected = "white"
|  44|    |-		text_align = "left"
|  45|    |-		text_valign = "center"
|  46|    |-		sound_selected = "audio/interface/ui/ui_button_click.ogg"
|  47|    |-	/>
|  48|    |-	<style name="ModernDropDown"
|  49|    |-		dropdown_buffer="1"
|  50|    |-		font="sans-bold-14"
|  51|    |-		textcolor="white"
|  52|    |-		text_align="left"
|  53|    |-		text_valign="center"
|  54|    |-
|  55|    |-		sprite="ModernDarkBoxGold"
|  56|    |-		sprite_disabled="ModernDarkBoxGoldDisabled"
|  57|    |-		button_width="16"
|  58|    |-		sprite2="ModernDropDownArrow"
|  59|    |-		sprite2_disabled="ModernDropDownArrowDisabled"
|  60|    |-		sprite2_pressed="ModernDropDownArrowHighlight"
|  61|    |-
|  62|    |-		buffer_zone="8"
|  63|    |-		dropdown_size="224"
|  64|    |-		sprite_list="BlackBorderOnGray"
|  65|    |-		sprite_selectarea="ModernDarkBoxWhite"
|  66|    |-		textcolor_selected="white"
|  67|    |-		textcolor_disabled="140 140 140 255"
|  68|    |-
|  69|    |-		scrollbar="true"
|  70|    |-		scrollbar_style="ModernScrollBar"
|  71|    |-
|  72|    |-		sound_opened="audio/interface/ui/ui_button_click.ogg"
|  73|    |-		sound_closed="audio/interface/ui/ui_button_click.ogg"
|  74|    |-		sound_selected="audio/interface/ui/ui_button_click.ogg"
|  75|    |-	/>
|  76|    |-	<style name="ModernLabelText"
|  77|    |-		font="sans-bold-stroke-14"
|  78|    |-		textcolor="white"
|  79|    |-		textcolor_disabled="140 140 140 255"
|  80|    |-		text_align="center"
|  81|    |-		text_valign="center"
|  82|    |-	/>
|  83|    |-	<style name="ModernRightLabelText"
|  84|    |-		font="sans-bold-stroke-14"
|  85|    |-		textcolor="white"
|  86|    |-		textcolor_disabled="140 140 140 255"
|  87|    |-		text_align="right"
|  88|    |-		text_valign="center"
|  89|    |-	/>
|  90|    |-	<style name="ModernLeftLabelText"
|  91|    |-		font="sans-bold-stroke-14"
|  92|    |-		textcolor="white"
|  93|    |-		textcolor_disabled="140 140 140 255"
|  94|    |-		text_align="left"
|  95|    |-		text_valign="center"
|  96|    |-	/>
|  97|    |-	<style name="ModernTopLabelText"
|  98|    |-		font="sans-bold-stroke-14"
|  99|    |-		textcolor="white"
| 100|    |-		text_align="center"
| 101|    |-		text_valign="top"
| 102|    |-	/>
| 103|    |-	<style name="ModernLeftTopLabelText"
| 104|    |-		font="sans-bold-stroke-14"
| 105|    |-		textcolor="white"
| 106|    |-		text_align="left"
| 107|    |-		text_valign="top"
| 108|    |-	/>
| 109|    |-	<style name="ModernText"
| 110|    |-		font="sans-14"
| 111|    |-		textcolor="white"
| 112|    |-		text_align="left"
| 113|    |-		text_valign="top"
| 114|    |-		scrollbar="true"
| 115|    |-		scrollbar_style="ModernScrollBar"
| 116|    |-	/>
| 117|    |-	<style name="ModernTextPanel"
| 118|    |-		buffer_zone="8"
| 119|    |-		scrollbar="true"
| 120|    |-		scrollbar_style="ModernScrollBar"
| 121|    |-		textcolor="white"
| 122|    |-		text_align="left"
| 123|    |-		text_valign="center"
| 124|    |-		sprite="ModernDarkBoxGold"
| 125|    |-	/>
| 126|    |-	<style name="ModernInput"
| 127|    |-		sprite="ModernDarkBoxWhite"
| 128|    |-		sprite_selectarea="color:150 0 0"
| 129|    |-		textcolor="white"
| 130|    |-		textcolor_selected="white"
| 131|    |-	/>
| 132|    |-	<style name="ModernTickBox"
| 133|    |-		sprite="ModernTickOff"
| 134|    |-		sprite2="ModernTickOn"
| 135|    |-		sprite_disabled="ModernTickDisabledOff"
| 136|    |-		sprite2_disabled="ModernTickDisabledOn"
| 137|    |-		square_side="22"
| 138|    |-		sound_pressed="audio/interface/ui/ui_button_click.ogg"
| 139|    |-	/>
| 140|    |-	<style name="ModernSlider"
| 141|    |-		sprite="ModernSliderButton"
| 142|    |-		sprite_bar="ModernSliderLine"
| 143|    |-		button_width="20"
| 144|    |-		tooltip_style="sliderTooltip"
| 145|    |-	/>
| 146|    |-	<style name="ModernButtonRed"
| 147|    |-		sprite="ModernButtonRed"
| 148|    |-		sprite_disabled="ModernButtonRedDisabled"
| 149|    |-		sprite_over="ModernButtonRedOver"
| 150|    |-		sprite_pressed="ModernButtonRed"
| 151|    |-		font="sans-bold-stroke-14"
| 152|    |-		textcolor="white"
| 153|    |-		textcolor_disabled="210 210 210 160"
| 154|    |-		text_align="center"
| 155|    |-		text_valign="center"
| 156|    |-		sound_pressed="audio/interface/ui/ui_button_click.ogg"
| 157|    |-	/>
| 158|    |-	<style name="ModernButtonGray"
| 159|    |-		sprite="ModernButtonGray"
| 160|    |-		sprite_disabled="ModernButtonGrayDisabled"
| 161|    |-		sprite_over="ModernButtonGrayOver"
| 162|    |-		sprite_pressed="ModernButtonGray"
| 163|    |-		font="sans-bold-stroke-14"
| 164|    |-		textcolor="white"
| 165|    |-		text_align="center"
| 166|    |-		text_valign="center"
| 167|    |-		sound_pressed="audio/interface/ui/ui_button_click.ogg"
| 168|    |-	/>
| 169|    |-	<style name="ModernTabButton"
| 170|    |-		sound_pressed="audio/interface/ui/ui_button_click.ogg"
|

http://jw:8080/job/phabricator_lint/413/ for more details.

There was also the idea to arrange the 5 option category buttons in tabs with 2 rows and 3 columns.
Then we'd have to use the Vertical style, so the patch still complies with that case.

binaries/data/mods/mod/gui/common/modern/sprites.xml
600 ↗(On Diff #3175)

Vladislav gave an ack on irc, but If the selected credit page button change isn't liked, it can be improved later.

Either the first three lines or the last line were wrong in the current svn code, so I assume it was only the last line and that this is the intended style.

binaries/data/mods/public/gui/summary/summary.xml
96 ↗(On Diff #3175)

Splitting ModernTabButton style to horizontal and vertical variant, so that we don't need to specify the sprite.
Besides, the sprite wouldn't have to be set to begin with, because the JS code already sets that property.
However it seems counterintuitive to not set a style for a button in the XML manifest.

This revision was automatically updated to reflect the committed changes.