Re-organise main menu screen (#25173)

- The dummy control of 2px size has annoyed me for almost 5 years.
- Why is it in the top-right.
- Why is the server address not labelled.
This commit is contained in:
metalgearsloth
2024-02-17 05:55:42 +11:00
committed by GitHub
parent 7461091af0
commit 1a438e644f
2 changed files with 40 additions and 37 deletions

View File

@@ -2,44 +2,46 @@
xmlns:pllax="clr-namespace:Content.Client.Parallax" xmlns:pllax="clr-namespace:Content.Client.Parallax"
xmlns:clog="clr-namespace:Content.Client.Changelog"> xmlns:clog="clr-namespace:Content.Client.Changelog">
<pllax:ParallaxControl /> <pllax:ParallaxControl />
<LayoutContainer>
<BoxContainer Name="VBox" <BoxContainer Name="VBox"
Orientation="Vertical" Orientation="Vertical"
StyleIdentifier="mainMenuVBox"> HorizontalAlignment="Center"
VerticalAlignment="Center"
HorizontalExpand="True"
VerticalExpand="True"
StyleIdentifier="mainMenuVBox"
SeparationOverride="3">
<TextureRect Name="Logo" <TextureRect Name="Logo"
Stretch="KeepCentered" /> Stretch="KeepCentered"/>
<BoxContainer Orientation="Horizontal" <GridContainer Columns="2">
SeparationOverride="4">
<Label Text="{Loc 'main-menu-username-label'}" /> <Label Text="{Loc 'main-menu-username-label'}" />
<LineEdit Name="UsernameBox" <LineEdit Name="UsernameBox"
Access="Public" Access="Public"
PlaceHolder="{Loc 'main-menu-username-text'}" PlaceHolder="{Loc 'main-menu-username-text'}"
HorizontalExpand="True" /> HorizontalExpand="True" />
</BoxContainer> <Label Text="{Loc 'main-menu-address-label'}"/>
<LineEdit Name="AddressBox" <LineEdit Name="AddressBox"
Access="Public" Access="Public"
Text="localhost" Text="localhost"
PlaceHolder="server address:port" PlaceHolder="server address:port"
HorizontalExpand="True" /> HorizontalExpand="True" />
</GridContainer>
<Button Name="DirectConnectButton" <Button Name="DirectConnectButton"
Access="Public" Access="Public"
Text="{Loc 'main-menu-direct-connect-button'}" Text="{Loc 'main-menu-direct-connect-button'}"
TextAlign="Center" TextAlign="Center"
StyleIdentifier="mainMenu" /> StyleIdentifier="mainMenu"/>
<Control MinSize="0 2" />
<Button Name="OptionsButton" <Button Name="OptionsButton"
Access="Public" Access="Public"
Text="{Loc 'main-menu-options-button'}" Text="{Loc 'main-menu-options-button'}"
TextAlign="Center" TextAlign="Center"
StyleIdentifier="mainMenu" /> StyleIdentifier="mainMenu"/>
<Button Name="QuitButton" <Button Name="QuitButton"
Access="Public" Access="Public"
Text="{Loc 'main-menu-quit-button'}" Text="{Loc 'main-menu-quit-button'}"
TextAlign="Center" TextAlign="Center"
StyleIdentifier="mainMenu" /> StyleIdentifier="mainMenu"/>
<clog:ChangelogButton <clog:ChangelogButton
Name="ChangelogButton" Name="ChangelogButton"
Access="Public"/> Access="Public"/>
</BoxContainer> </BoxContainer>
</LayoutContainer>
</Control> </Control>

View File

@@ -5,6 +5,7 @@ main-menu-failed-to-connect = Failed to connect:
{$reason} {$reason}
main-menu-username-label = Username: main-menu-username-label = Username:
main-menu-username-text = Username main-menu-username-text = Username
main-menu-address-label = Server Address:
main-menu-join-public-server-button = Join Public Server main-menu-join-public-server-button = Join Public Server
main-menu-join-public-server-button-tooltip = Cannot connect to public server with a debug build. main-menu-join-public-server-button-tooltip = Cannot connect to public server with a debug build.
main-menu-direct-connect-button = Direct Connect main-menu-direct-connect-button = Direct Connect