摘要: EventSetter:当事件触发的时候会执行Handler的事件处理程序 样式的触发器: 使用触发器可自动完成简单的样式的改变,不需要使用代码,也可以完成不少工作。 触发器通过Style.Trigger集合链接到样式。每个样式可以有任意多个触发器。每个触发器都是System.Windows.Tri 阅读全文
posted @ 2021-11-18 16:39 zyl2 阅读(299) 评论(0) 推荐(0)
摘要: 样式定义 <Window.Resources> <Style x:Key="FocusVisual"> <Setter Property="Control.Template"> <Setter.Value> <ControlTemplate> <Rectangle Margin="2" SnapsT 阅读全文
posted @ 2021-11-18 16:24 zyl2 阅读(169) 评论(0) 推荐(0)
摘要: 资源的加载 同一程序集下加载URI:"Pack://application:,,,/Images/Logo.png" 或者"/Images/Logo.png" 不同程序集下加载URI:"Pack://application:,,,/Zhaoxi.Assets;component/Images/Log 阅读全文
posted @ 2021-11-18 16:13 zyl2 阅读(300) 评论(0) 推荐(0)
摘要: public class BreakWrapPanel : Panel { public static readonly DependencyProperty IsBreakForceProperty = DependencyProperty.RegisterAttached("BreakForce 阅读全文
posted @ 2021-11-18 16:01 zyl2 阅读(48) 评论(0) 推荐(0)
摘要: 1.Border控件:是一种装饰控件,为控件添加边界 <Border BorderThickness="5,0,0,0" BorderBrush="Red" CornerRadius="5" > //BorderThickness定义边界的笔大小,BorderBrush边界颜色 CornerRadi 阅读全文
posted @ 2021-11-18 15:41 zyl2 阅读(101) 评论(0) 推荐(0)
摘要: wpf无边窗体实现有两种方式: 第一种: <Window x:Class="Zhaoxi.LayoutStudy.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http:/ 阅读全文
posted @ 2021-11-18 15:24 zyl2 阅读(794) 评论(0) 推荐(0)