mekasu0124

Untitled

Feb 24th, 2024
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 2.75 KB | None | 0 0
  1. <Window xmlns="https://github.com/avaloniaui"
  2.         xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  3.         xmlns:d="http://schemas.microsoft.com/e/xpression/blend/2008"
  4.         xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5.         xmlns:vm="using:SplashScreen.ViewModels"
  6.         mc:Ignorable="d"
  7.         x:Class="SplashScreen.Splash"
  8.         x:DataType="vm:SplashViewModel"
  9.         Width="500"
  10.         Height="600"
  11.         SystemDecorations="None"
  12.         WindowStartupLocation="CenterScreen"
  13.         Background="Transparent"
  14.         TransparencyLevelHint="Transparent"
  15.         TransparencyBackgroundFallback="Transparent"
  16.         Title="Diary - Loading Screen">
  17.  
  18.     <Design.DataContext>
  19.         <vm:SplashViewModel />
  20.     </Design.DataContext>
  21.  
  22.     <Window.Styles>
  23.         <Style Selector="Border">
  24.             <Setter Property="Background" Value="{Binding Background}" />
  25.             <Setter Property="CornerRadius" Value="10" />
  26.             <Setter Property="Padding" Value="10" />
  27.         </Style>
  28.  
  29.         <Style Selector="StackPanel">
  30.             <Setter Property="VerticalAlignment" Value="Center" />
  31.             <Setter Property="HorizontalAlignment" Value="Center" />
  32.             <Setter Property="Spacing" Value="30" />
  33.             <Setter Property="Height" Value="200" />
  34.             <Setter Property="Width" Value="400" />
  35.         </Style>
  36.  
  37.         <Style Selector="TextBlock">
  38.             <Setter Property="Foreground" Value="{Binding Foreground}" />
  39.             <Setter Property="VerticalAlignment" Value="Center" />
  40.             <Setter Property="HorizontalAlignment" Value="Center" />
  41.             <Setter Property="TextAlignment" Value="Center" />
  42.             <Setter Property="FontSize" Value="20" />
  43.             <Setter Property="FontWeight" Value="Bold" />
  44.         </Style>
  45.  
  46.         <Style Selector="Button">
  47.             <Setter Property="Foreground" Value="{Binding Foreground}" />
  48.             <Setter Property="Background" Value="{Binding Background}" />
  49.             <Setter Property="CornerRadius" Value="20" />
  50.             <Setter Property="FontSize" Value="20" />
  51.             <Setter Property="HorizontalAlignment" Value="Center" />
  52.             <Setter Property="VerticalAlignment" Value="Center" />
  53.             <Setter Property="HorizontalContentAlignment" Value="Center" />
  54.             <Setter Property="VerticalContentAlignment" Value="Center" />
  55.  
  56.             <Style Selector="^:pointerover /template/ ContentPresenter">
  57.                 <Setter Property="Foreground" Value="{Binding Foreground}" />
  58.                 <Setter Property="Background" Value="{Binding Background}" />
  59.                 <Setter Property="BorderBrush" Value="{Binding Border}" />
  60.                 <Setter Property="BorderThickness" Value="2" />
  61.             </Style>
  62.         </Style>
  63.  
  64.         <Style Selector="Image">
  65.             <Setter Property="Width" Value="150" />
  66.             <Setter Property="Height" Value="150" />
  67.         </Style>
  68.     </Window.Styles>
  69.  
  70.     <Border>
  71.         <StackPanel>
  72.             <Image Source="/Assets/logo.ico"></Image>
  73.             <TextBlock Text="{Binding StartUpMessage}" />
  74.             <Button Command="{Binding Cancel}" />
  75.         </StackPanel>
  76.     </Border>
  77. </Window>
Advertisement
Add Comment
Please, Sign In to add comment