Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Left aligned navigation buttons in Nitrox launcher #948

Merged
merged 1 commit into from
Mar 7, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Left aligned navigation buttons in Nitrox launcher
  • Loading branch information
Measurity committed Mar 7, 2020
commit 57c3c597dc26e26ca87fd81ab6bd6117e09dbeac
2 changes: 2 additions & 0 deletions NitroxLauncher/App.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,12 @@
</Style.Resources>
</Style>

<!-- Make sure the navigation items align vertically with the "NITROX" header. -->
<Style TargetType="Grid" x:Key="MainNavigationGrid">
<Style.Resources>
<Style TargetType="Button" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Margin" Value="0 10" />
<Setter Property="HorizontalAlignment" Value="Left"></Setter>
<Style.Triggers>
<Trigger Property="ap:ButtonProperties.Selected" Value="True">
<Setter Property="Foreground" Value="White" />
Expand Down
3 changes: 2 additions & 1 deletion NitroxLauncher/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<StackPanel Grid.Row="0" Margin="0,28,0,0" x:Name="SideBarPanel">
<!-- Make sure the navigation items align vertically with the "NITROX" header. -->
<StackPanel Grid.Row="0" Margin="28,28,0,0" x:Name="SideBarPanel" HorizontalAlignment="Left">
<Button Click="ButtonNavigation_Click" Tag="{StaticResource LaunchGamePage}" ToolTip="Play the game" Content="PLAY GAME" />
<Button Click="ButtonNavigation_Click" Tag="{StaticResource ServerPage}" ToolTip="Configure server options" Content="SERVER" />
<Button Click="ButtonNavigation_Click" Tag="{StaticResource OptionPage}" ToolTip="Launcher settings" Content="OPTIONS" />
Expand Down