mirror of
https://github.com/knah/VRCMelonAssistant.git
synced 2024-09-29 08:41:43 +13:00
Fix sidebar image scaling
This commit is contained in:
parent
d121c02336
commit
4ca4e53890
7 changed files with 6 additions and 10 deletions
|
@ -216,7 +216,7 @@ namespace ModAssistant
|
||||||
sidebar = new BitmapImage(new Uri(Path.Combine(location, name + ".side.png")));
|
sidebar = new BitmapImage(new Uri(Path.Combine(location, name + ".side.png")));
|
||||||
}
|
}
|
||||||
MainWindow.Instance.BackgroundImage.ImageSource = background;
|
MainWindow.Instance.BackgroundImage.ImageSource = background;
|
||||||
MainWindow.Instance.SideImage.ImageSource = sidebar;
|
MainWindow.Instance.SideImage.Source = sidebar;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
@ -15,11 +15,7 @@
|
||||||
<ImageBrush x:Name="BackgroundImage" Stretch="{DynamicResource BackgroundImageStretch}"/>
|
<ImageBrush x:Name="BackgroundImage" Stretch="{DynamicResource BackgroundImageStretch}"/>
|
||||||
</Rectangle.Fill>
|
</Rectangle.Fill>
|
||||||
</Rectangle>
|
</Rectangle>
|
||||||
<Rectangle>
|
<Image x:Name="SideImage" UseLayoutRounding="True" SnapsToDevicePixels="True" HorizontalAlignment="Left" VerticalAlignment="{DynamicResource SideImageYPosition}" Width="1272" Height="689" Stretch="Fill"/>
|
||||||
<Rectangle.Fill>
|
|
||||||
<ImageBrush x:Name="SideImage" Stretch="None" AlignmentX="Left" AlignmentY="{DynamicResource SideImageYPosition}"/>
|
|
||||||
</Rectangle.Fill>
|
|
||||||
</Rectangle>
|
|
||||||
<Grid Margin="10">
|
<Grid Margin="10">
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
<RowDefinition Height="*"/>
|
<RowDefinition Height="*"/>
|
||||||
|
|
BIN
ModAssistant/Resources/SidebarTemplate-1272-689.png
Normal file
BIN
ModAssistant/Resources/SidebarTemplate-1272-689.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
|
@ -75,6 +75,6 @@
|
||||||
|
|
||||||
<!--Background and Side image settings.-->
|
<!--Background and Side image settings.-->
|
||||||
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
||||||
<AlignmentY x:Key="SideImageYPosition">Bottom</AlignmentY> <!-- Bottom, Center, Top -->
|
<VerticalAlignment x:Key="SideImageYPosition">Bottom</VerticalAlignment> <!-- Bottom, Center, Top -->
|
||||||
|
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
|
|
@ -63,6 +63,6 @@
|
||||||
|
|
||||||
<!-- Background and Side image settings. -->
|
<!-- Background and Side image settings. -->
|
||||||
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
||||||
<AlignmentY x:Key="SideImageYPosition">Bottom</AlignmentY> <!-- Bottom, Center, Top -->
|
<VerticalAlignment x:Key="SideImageYPosition">Bottom</VerticalAlignment> <!-- Bottom, Center, Top -->
|
||||||
|
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
|
|
@ -74,6 +74,6 @@
|
||||||
|
|
||||||
<!--Background and Side image settings.-->
|
<!--Background and Side image settings.-->
|
||||||
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
||||||
<AlignmentY x:Key="SideImageYPosition">Bottom</AlignmentY> <!-- Bottom, Center, Top -->
|
<VerticalAlignment x:Key="SideImageYPosition">Bottom</VerticalAlignment> <!-- Bottom, Center, Top -->
|
||||||
|
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
|
|
@ -90,6 +90,6 @@
|
||||||
<SolidColorBrush x:Key="OptionsIconColor" Color="{DynamicResource ResourceKey=StandardIcon}"/>
|
<SolidColorBrush x:Key="OptionsIconColor" Color="{DynamicResource ResourceKey=StandardIcon}"/>
|
||||||
|
|
||||||
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
<Stretch x:Key="BackgroundImageStretch">UniformToFill</Stretch> <!-- Fill, None, Uniform, UniformToFill -->
|
||||||
<AlignmentY x:Key="SideImageYPosition">Bottom</AlignmentY> <!-- Bottom, Center, Top -->
|
<VerticalAlignment x:Key="SideImageYPosition">Bottom</VerticalAlignment> <!-- Bottom, Center, Top -->
|
||||||
|
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
|
Loading…
Reference in a new issue