MainWindow.xaml
(开头部分) 6KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<Window x:Class="Micro.Ui.RunningTextStyle.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:Micro.Ui.RunningTextStyle"
xmlns:pp="clr-namespace:Micro.Ui.RunningTextStyle.Controls"
xmlns:cvt="clr-namespace:Micro.Ui.RunningTextStyle.Converters"
mc:Ignorable="d" WindowStartupLocation="CenterScreen"
Title="WPF走马灯效果" Height="450" Width="780">
<Window.Resources>
<cvt:GenericTypeConverter x:Key="genericTypeConverter"/>
</Window.Resources>
<Grid>
<Grid DockPanel.Dock="Top">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<pp:RunningText Grid.Column="1" Padding="12 6" Space="0" Speed="120" FontSize="12" Direction="RightToLeft" Background="#5D6B99" Foreground="#FFFFFF"
Text="滚动轮播文字(走马灯效果);可调节滚动速度、首尾间距...">
<pp:RunningText.Style>
<Style TargetType="{x:Type pp:RunningText}">
<Setter Property="VerticalAlignment" Value="Top" />
<Style.Triggers>
<Trigger Property="Direction" Value="BottomToTop">
<Setter Property="VerticalAlignment" Value="Stretch" />
<Setter Property="HorizontalAlignment" Value="Left" />
</Trigger>
<Trigger Property="Direction" Value="TopToBottom">
<Setter Property="VerticalAlignment" Value="Stretch" />
<Setter Property="HorizontalAlignment" Value="Left" />
</Trigger>
</Style.Triggers>
</Style>
</pp:RunningText.Style>
</pp:RunningText>
<pp:RunningText Grid.Row="1" Padding="12 6" Space="0" Speed="120" FontSize="12" Direction="BottomToTop" Background="#5D6B99" Foreground="#FFFFFF"
Text="滚动轮播文字(走马灯效果);可调节滚动速度、首尾间距...">
<pp:RunningText.Style>
<Style TargetType="{x:Type pp:RunningText}">
<Setter Property="VerticalAlignment" Value="Top" />
<Style.Triggers>
<Trigger Property="Direction" Value="BottomToTop">
<Setter Property="VerticalAlignment" Value="Stretch" />
<Setter Property="HorizontalAlignment" Value="Left" />
</Trigger>
<Trigger Property="Direction" Value="TopToBottom">
<Setter Property="VerticalAlignment" Value="Stretch" />
<Setter Property="HorizontalAlignment" Value="Left" />
</Trigger>
</Style.Triggers>
</Style>
后面还有 43 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
