Skip to main content

Posts

Showing posts with the label UWP RelativePanel

UWP - RelativePanel example

MainPage.xaml <Page x:Class="UniversalAppTutorials.MainPage" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:UniversalAppTutorials" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" > <RelativePanel Background="AliceBlue" Padding="50"> <TextBlock x:Name="SignInText" Text="Sign In" RelativePanel.AlignHorizontalCenterWithPanel="True" Foreground="Black" FontSize="30" FontWeight="Normal" CharacterSpacing="200" /> <TextBox x:Name="UserName" H...

UWP - RelativePanel stretch example

MainPage.xaml <Page x:Class="UniversalAppTutorials.MainPage" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:UniversalAppTutorials" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" > <RelativePanel Background="AliceBlue" Padding="50"> <!-- Stretch element horizontally, parent left to right edge. --> <Rectangle x:Name="Red" Fill="Red" Height="50" RelativePanel.AlignLeftWithPanel="True" RelativePanel.AlignRightWithPanel="True" /> <!-- Stretch element ver...

UWP - Understanding RelativePanel elements position

MainPage.xaml <Page x:Class="UniversalAppTutorials.MainPage" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:UniversalAppTutorials" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" > <RelativePanel Background="AliceBlue" Padding="50"> <Rectangle x:Name="Red" Fill="Red" Width="50" Height="50" RelativePanel.AlignHorizontalCenterWithPanel="True" RelativePanel.AlignVerticalCenterWithPanel="True" /> <Rectangle x:Name="Green" Fill="Green" ...