-
Notifications
You must be signed in to change notification settings - Fork 735
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2348 from unoplatform/mergify/bp/release/beta/2.0…
…/pr-2345 [iOS] Fix double margin on Image (bp #2345)
- Loading branch information
Showing
4 changed files
with
157 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
114 changes: 114 additions & 0 deletions
114
src/SamplesApp/UITests.Shared/Windows_UI_Xaml_Controls/ImageTests/Image_Margin.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
<Page | ||
x:Class="UITests.Shared.Windows_UI_Xaml_Controls.ImageTests.Image_Margin" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:UITests.Shared.Windows_UI_Xaml_Controls.ImageTests" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<Grid> | ||
<Grid.ColumnDefinitions> | ||
<ColumnDefinition Width="*" /> | ||
<ColumnDefinition Width="*" /> | ||
<ColumnDefinition Width="*" /> | ||
</Grid.ColumnDefinitions> | ||
<Grid.RowDefinitions> | ||
<RowDefinition Height="*" /> | ||
<RowDefinition Height="*" /> | ||
<RowDefinition Height="*" /> | ||
</Grid.RowDefinitions> | ||
|
||
<Grid Grid.Row="0" | ||
Grid.Column="0" | ||
Background="Orange" | ||
Width="100" | ||
Height="100"> | ||
<StackPanel HorizontalAlignment="Stretch" | ||
VerticalAlignment="Center"> | ||
<Image Source="ms-appx:///Assets/ingredient3.png" | ||
Stretch="Uniform" | ||
Margin="0,0" /> | ||
</StackPanel> | ||
</Grid> | ||
|
||
<Grid Grid.Row="0" | ||
Grid.Column="1" | ||
Background="Orange" | ||
Width="100" | ||
Height="100"> | ||
<StackPanel HorizontalAlignment="Stretch" | ||
VerticalAlignment="Center"> | ||
<Image Source="ms-appx:///Assets/ingredient3.png" | ||
Stretch="Uniform" | ||
Margin="20,0" /> | ||
</StackPanel> | ||
</Grid> | ||
|
||
<Grid Grid.Row="0" | ||
Grid.Column="2" | ||
Background="Orange" | ||
Width="100" | ||
Height="100"> | ||
<StackPanel HorizontalAlignment="Stretch" | ||
VerticalAlignment="Center"> | ||
<Image Source="ms-appx:///Assets/ingredient3.png" | ||
Stretch="Uniform" | ||
Margin="0,20" /> | ||
</StackPanel> | ||
</Grid> | ||
|
||
<Grid Grid.Row="1" | ||
Grid.Column="0" | ||
Background="Orange" | ||
Width="100" | ||
Height="100"> | ||
<StackPanel HorizontalAlignment="Stretch" | ||
VerticalAlignment="Center"> | ||
<Image Source="ms-appx:///Assets/ingredient3.png" | ||
Stretch="Uniform" | ||
Margin="20,0,0,0" /> | ||
</StackPanel> | ||
</Grid> | ||
|
||
<Grid Grid.Row="1" | ||
Grid.Column="1" | ||
Background="Orange" | ||
Width="100" | ||
Height="100"> | ||
<StackPanel HorizontalAlignment="Stretch" | ||
VerticalAlignment="Center"> | ||
<Image Source="ms-appx:///Assets/ingredient3.png" | ||
Stretch="Uniform" | ||
Margin="0,20,0,0" /> | ||
</StackPanel> | ||
</Grid> | ||
|
||
<Grid Grid.Row="1" | ||
Grid.Column="2" | ||
Background="Orange" | ||
Width="100" | ||
Height="100"> | ||
<StackPanel HorizontalAlignment="Stretch" | ||
VerticalAlignment="Center"> | ||
<Image Source="ms-appx:///Assets/ingredient3.png" | ||
Stretch="Uniform" | ||
Margin="0,0,20,0" /> | ||
</StackPanel> | ||
</Grid> | ||
|
||
<Grid Grid.Row="2" | ||
Grid.Column="0" | ||
Background="Orange" | ||
Width="100" | ||
Height="100"> | ||
<StackPanel HorizontalAlignment="Stretch" | ||
VerticalAlignment="Center"> | ||
<Image Source="ms-appx:///Assets/ingredient3.png" | ||
Stretch="Uniform" | ||
Margin="0,0,0,20" /> | ||
</StackPanel> | ||
</Grid> | ||
</Grid> | ||
</Page> |
32 changes: 32 additions & 0 deletions
32
src/SamplesApp/UITests.Shared/Windows_UI_Xaml_Controls/ImageTests/Image_Margin.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.IO; | ||
using System.Linq; | ||
using System.Runtime.InteropServices.WindowsRuntime; | ||
using Uno.UI.Samples.Controls; | ||
using Windows.Foundation; | ||
using Windows.Foundation.Collections; | ||
using Windows.UI.Xaml; | ||
using Windows.UI.Xaml.Controls; | ||
using Windows.UI.Xaml.Controls.Primitives; | ||
using Windows.UI.Xaml.Data; | ||
using Windows.UI.Xaml.Input; | ||
using Windows.UI.Xaml.Media; | ||
using Windows.UI.Xaml.Navigation; | ||
|
||
// The Blank Page item template is documented at https://go.microsoft.com/fwlink/?LinkId=234238 | ||
|
||
namespace UITests.Shared.Windows_UI_Xaml_Controls.ImageTests | ||
{ | ||
/// <summary> | ||
/// An empty page that can be used on its own or navigated to within a Frame. | ||
/// </summary> | ||
[SampleControlInfo] | ||
public sealed partial class Image_Margin : Page | ||
{ | ||
public Image_Margin() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters