月更
This commit is contained in:
@@ -1,60 +1,56 @@
|
||||
<UserControl x:Class="AntdWpfDemo.Views.ToolTipView"
|
||||
<UserControl x:Class="AntDesignWPFDemo.Views.ToolTipView"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntDesignWPF"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntdWpf"
|
||||
|
||||
xmlns:viewmodels="clr-namespace:AntDesignWPFDemo.ViewModels"
|
||||
mc:Ignorable="d"
|
||||
d:DesignHeight="600"
|
||||
d:DesignWidth="930">
|
||||
d:DataContext="{d:DesignInstance Type=viewmodels:ToolTipViewModel}">
|
||||
|
||||
<ScrollViewer>
|
||||
<Grid Margin="16 0">
|
||||
<Grid Margin="16,0">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="*" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
<StackPanel>
|
||||
<Label Style="{StaticResource Ant.H1}" Content="Tooltip" />
|
||||
<Label Content="Tooltip" Style="{StaticResource Ant.H1}" />
|
||||
<TextBlock Style="{StaticResource Ant.P}" Text="A simple text popup tip." />
|
||||
|
||||
<Label Style="{StaticResource Ant.H2}" Content="When To Use" />
|
||||
<Label Content="When To Use" Style="{StaticResource Ant.H2}" />
|
||||
<TextBlock Style="{StaticResource Ant.P}" Text="The tip is shown on mouse enter, and is hidden on mouse leave. The Tooltip doesn't support complex text or operations.
To provide an explanation of a button/text/operation. It's often used instead of the html title attribute." />
|
||||
|
||||
<Label Style="{StaticResource Ant.H2}" Content="Examples" />
|
||||
<Label Content="Examples" Style="{StaticResource Ant.H2}" />
|
||||
</StackPanel>
|
||||
<Grid Grid.Row="1">
|
||||
<Grid.Resources>
|
||||
<Style TargetType="antd:AntButton">
|
||||
<Setter Property="Margin" Value="8 0 0 8" />
|
||||
<Setter Property="Margin" Value="8,0,0,8" />
|
||||
</Style>
|
||||
</Grid.Resources>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition />
|
||||
<ColumnDefinition />
|
||||
</Grid.ColumnDefinitions>
|
||||
<StackPanel Margin="8 0">
|
||||
<StackPanel Margin="8,0">
|
||||
<antd:CodeBox Title="Basic">
|
||||
<antd:CodeBox.Description>
|
||||
The simplest usage.
|
||||
</antd:CodeBox.Description>
|
||||
<antd:CodeBox.Description>The simplest usage.</antd:CodeBox.Description>
|
||||
<antd:CodeBox.Content>
|
||||
<TextBlock Text="Tooltip will show when mouse enter." ToolTip="prompt text" ToolTipService.Placement="Top" ToolTipService.ShowDuration="0" />
|
||||
<TextBlock Text="Tooltip will show when mouse enter."
|
||||
ToolTip="prompt text"
|
||||
ToolTipService.Placement="Top"
|
||||
ToolTipService.ShowDuration="0" />
|
||||
</antd:CodeBox.Content>
|
||||
<antd:CodeBox.Code>
|
||||
<ResourceDictionary Source="pack://application:,,,/AntdWpf;component/Themes/Theme.xaml" />\n\n
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntdWpf"\n\n
|
||||
<WrapPanel>
|
||||
<antd:Switch IsChecked="True" />
|
||||
</WrapPanel>
|
||||
</antd:CodeBox.Code>
|
||||
<antd:CodeBox.Code><ResourceDictionary Source="pack://application:,,,/AntDesignWPF;component/Themes/Theme.xaml" />\n\n
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntDesignWPF"\n\n
|
||||
<WrapPanel>
|
||||
<antd:Switch IsChecked="True" />
|
||||
</WrapPanel></antd:CodeBox.Code>
|
||||
</antd:CodeBox>
|
||||
<antd:CodeBox Title="Arrow pointing at the center">
|
||||
<antd:CodeBox.Description>
|
||||
By specifying `arrowPointAtCenter` prop, the arrow will point to the center of the target element.
|
||||
</antd:CodeBox.Description>
|
||||
<antd:CodeBox.Description>By specifying `arrowPointAtCenter` prop, the arrow will point to the center of the target element.</antd:CodeBox.Description>
|
||||
<antd:CodeBox.Content>
|
||||
<StackPanel>
|
||||
<WrapPanel>
|
||||
@@ -65,20 +61,16 @@
|
||||
</WrapPanel>
|
||||
</StackPanel>
|
||||
</antd:CodeBox.Content>
|
||||
<antd:CodeBox.Code>
|
||||
<ResourceDictionary Source="pack://application:,,,/AntdWpf;component/Themes/Theme.xaml" />\n\n
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntdWpf"\n\n
|
||||
<WrapPanel>
|
||||
<antd:Switch IsChecked="True" />
|
||||
</WrapPanel>
|
||||
</antd:CodeBox.Code>
|
||||
<antd:CodeBox.Code><ResourceDictionary Source="pack://application:,,,/AntDesignWPF;component/Themes/Theme.xaml" />\n\n
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntDesignWPF"\n\n
|
||||
<WrapPanel>
|
||||
<antd:Switch IsChecked="True" />
|
||||
</WrapPanel></antd:CodeBox.Code>
|
||||
</antd:CodeBox>
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Column="1" Margin="8 0">
|
||||
<StackPanel Grid.Column="1" Margin="8,0">
|
||||
<antd:CodeBox Title="Placement">
|
||||
<antd:CodeBox.Description>
|
||||
The ToolTip has 12 placements choice.
|
||||
</antd:CodeBox.Description>
|
||||
<antd:CodeBox.Description>The ToolTip has 12 placements choice. ToolTipService.Placement="Left"</antd:CodeBox.Description>
|
||||
<antd:CodeBox.Content>
|
||||
<Grid MaxWidth="335">
|
||||
<Grid.RowDefinitions>
|
||||
@@ -87,37 +79,35 @@
|
||||
<RowDefinition />
|
||||
</Grid.RowDefinitions>
|
||||
<WrapPanel HorizontalAlignment="Center">
|
||||
<antd:AntButton Content="TL" />
|
||||
<antd:AntButton Content="Top" />
|
||||
<antd:AntButton Content="TR" />
|
||||
<antd:AntButton Content="TL" ToolTip="Prompt Text" ToolTipService.Placement="Top"/>
|
||||
<antd:AntButton Content="Top" ToolTip="Prompt Text" ToolTipService.Placement="Top"/>
|
||||
<antd:AntButton Content="TR" ToolTip="Prompt Text" ToolTipService.Placement="Top"/>
|
||||
</WrapPanel>
|
||||
<StackPanel Grid.Row="1" HorizontalAlignment="Left">
|
||||
<antd:AntButton Content="LT" />
|
||||
<antd:AntButton Content="Left" />
|
||||
<antd:AntButton Content="LB" />
|
||||
<antd:AntButton Content="LT" ToolTip="Prompt Text" ToolTipService.Placement="Left"/>
|
||||
<antd:AntButton Content="Left" ToolTip="Prompt Text" ToolTipService.Placement="Left"/>
|
||||
<antd:AntButton Content="LB" ToolTip="Prompt Text" ToolTipService.Placement="Left"/>
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Row="1" HorizontalAlignment="Right">
|
||||
<antd:AntButton Content="RT" />
|
||||
<antd:AntButton Content="Right" />
|
||||
<antd:AntButton Content="RB" />
|
||||
<antd:AntButton Content="RT" ToolTip="Prompt Text" ToolTipService.Placement="Right"/>
|
||||
<antd:AntButton Content="Right" ToolTip="Prompt Text" ToolTipService.Placement="Right"/>
|
||||
<antd:AntButton Content="RB" ToolTip="Prompt Text" ToolTipService.Placement="Right"/>
|
||||
</StackPanel>
|
||||
<WrapPanel Grid.Row="2" HorizontalAlignment="Center">
|
||||
<antd:AntButton Content="BL" />
|
||||
<antd:AntButton Content="Bottom" />
|
||||
<antd:AntButton Content="BR" />
|
||||
<antd:AntButton Content="BL" ToolTip="Prompt Text" ToolTipService.Placement="Center"/>
|
||||
<antd:AntButton Content="Bottom" ToolTip="Prompt Text" ToolTipService.Placement="Center"/>
|
||||
<antd:AntButton Content="BR" ToolTip="Prompt Text" ToolTipService.Placement="Center"/>
|
||||
</WrapPanel>
|
||||
</Grid>
|
||||
</antd:CodeBox.Content>
|
||||
<antd:CodeBox.Code>
|
||||
<ResourceDictionary Source="pack://application:,,,/AntdWpf;component/Themes/Theme.xaml" />\n\n
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntdWpf"\n\n
|
||||
<WrapPanel>
|
||||
<antd:Switch IsChecked="True" />
|
||||
</WrapPanel>
|
||||
</antd:CodeBox.Code>
|
||||
<antd:CodeBox.Code><ResourceDictionary Source="pack://application:,,,/AntDesignWPF;component/Themes/Theme.xaml" />\n\n
|
||||
xmlns:antd="https://github.com/ShrlAlgo/AntDesignWPF"\n\n
|
||||
<WrapPanel>
|
||||
<antd:Switch IsChecked="True" />
|
||||
</WrapPanel></antd:CodeBox.Code>
|
||||
</antd:CodeBox>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</ScrollViewer>
|
||||
</UserControl>
|
||||
</UserControl>
|
||||
Reference in New Issue
Block a user