当前位置: 首页 > news >正文

七彩建设集团官方网站网络服务类型有哪几种

七彩建设集团官方网站,网络服务类型有哪几种,深圳ppt设计制作公司,广州在线网站制作推荐HandyControl是一套WPF控件库,它几乎重写了所有原生样式,同时包含80余款自定义控件(正逐步增加),下面我们开始使用。 1、准备 1.1 创建项目 C# WPF应用(.NET Framework)创建项目 1.2 添加包 1.3 在App.xaml中引用…

HandyControl是一套WPF控件库,它几乎重写了所有原生样式,同时包含80余款自定义控件(正逐步增加),下面我们开始使用。

1、准备

1.1 创建项目

C#  WPF应用(.NET Framework)创建项目

1.2 添加包

1.3  在App.xaml中引用HandyControl的皮肤和主题:

<Application.Resources><ResourceDictionary><ResourceDictionary.MergedDictionaries><ResourceDictionary Source="pack://application:,,,/HandyControl;component/Themes/SkinDefault.xaml"/><ResourceDictionary Source="pack://application:,,,/HandyControl;component/Themes/Theme.xaml"/></ResourceDictionary.MergedDictionaries></ResourceDictionary>
</Application.Resources>

1.4 窗体文件xaml添加引用

xmlns:hc="https://handyorg.github.io/handycontrol"

2、窗体

2.1 改Window为hc:Window

<hc:Window x:Class="HandyControlTest.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:hc="https://handyorg.github.io/handycontrol"xmlns:local="clr-namespace:HandyControlTest"mc:Ignorable="d"Title="MainWindow" Height="450" Width="800"><Grid></Grid>
</hc:Window>

2.2 修改窗体的xaml.cs文件

修改窗体类名,否则报错:“分部声明一定不能指定不同的基类”

public partial class MainWindow : Window

                                      ↓

public partial class MainWindow : HandyControl.Controls.Window

 2.3 扩展属性

 2.4 代码修改

CloseButtonBackground="Blue" CloseButtonForeground="White"
CloseButtonHoverBackground="Red" CloseButtonHoverForeground="Black"
OtherButtonBackground="Green" OtherButtonForeground="White"
OtherButtonHoverBackground="Yellow" OtherButtonHoverForeground="Black"

2.5 运行结果

 

 2.6 其它参数

NonClientAreaBackground用来设置了标题栏的背景色。NonClientAreaForeground用来设置标题栏的前景色,不仅仅可以用来设置标题的前景色,也可以设置NonClientAreaContent中控件的默认前景色。NonClientAreaHeight用来设置标题栏的高度。下面看一段代码:

<hc:Window x:Class="TestDemo.View.WindowTest"xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"xmlns:hc="https://handyorg.github.io/handycontrol"Title="WindowTest" Height="200" Width="400"NonClientAreaBackground ="LightBlue" NonClientAreaForeground="Red"NonClientAreaHeight="100"><hc:Window.NonClientAreaContent ><Border BorderThickness="1" BorderBrush="Black"><StackPanel HorizontalAlignment="Left" Orientation="Horizontal"><Button Margin="5,0,0,0" Content="登录"/><TextBlock Text="服务未连接" VerticalAlignment="Center" Margin="5,0,0,0" /></StackPanel></Border></hc:Window.NonClientAreaContent>
</hc:Window>

 运行效果:

3、 按钮

3.1 代码

<Grid><StackPanel Orientation="Vertical"><StackPanel Orientation="Horizontal"><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonBaseBaseStyle}" Foreground="Black" /><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonDanger}" /><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonDashedDanger}" /><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonDashedInfo}" /><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonInfo}" /><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonPrimary}" /></StackPanel><StackPanel Orientation="Horizontal"><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonWarning}" /><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonSuccess}" /><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonSuccess}" hc:BorderElement.CornerRadius="15"/><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonDanger.Small}" /><Button Margin="10,10" Width="45"Style="{StaticResource ButtonIcon}" hc:IconElement.Geometry="{StaticResource AddGeometry}"Foreground="Green"/><Button Margin="10,10" Width="45"Style="{StaticResource ButtonIcon}" hc:IconElement.Geometry="{StaticResource RemoveGeometry}"Foreground="Green"/><Button Margin="10,10" Width="45" Height="45"Style="{StaticResource ButtonIcon}" hc:IconElement.Geometry="{StaticResource SuccessGeometry}"Foreground="White"Background="{DynamicResource {x:Static SystemColors.HighlightBrushKey}}"/><Button Content="按钮" Margin="10,10" Width="75"Style="{StaticResource ButtonWarning}" hc:IconElement.Geometry="{StaticResource SuccessGeometry}"Foreground="Black"/></StackPanel></StackPanel>
</Grid>

3.2 运行效果

 

http://www.bjxfkj.com.cn/article/107999.html

相关文章:

  • 做企业网站服务器深圳团购网站设计价格
  • 本地郑州网站建设营销网站定制公司
  • 贵阳网站建设托管谁帮58同城做的网站吗
  • php 微信 网站开发如何搭建购物平台
  • 网站首页图片大全装修网站开发思路
  • 做告状网站高德地图在海外能用吗
  • 怎么做自己的html网站宣化网站制作公司
  • 做配色的网站竭诚网络网站建设开发
  • 网站界面设计考试建设项目验收公示网站
  • 访客留言网站云主机网站源码
  • 建设网站图片大全做框架表格网站
  • 光谷网站建设公司响应式网站 英语
  • 网上免费做网站建设厅电工证查询网站
  • 网站建设与管理试卷中国最新军事新闻50字
  • ssh框架做音乐网站哈尔滨seo网络推广
  • 建设一中校园网站一级a做爰网站免费
  • 帮忙做任务网站哈尔滨网站制作多少钱
  • 由音乐学院做的网站云主机搭建wordpress
  • 有关网站建设账务处理免费简单网页制作成品
  • 阿里巴巴电子商务网站网站建设文书
  • 东莞市官网网站建设自媒体视频剪辑去哪里学
  • 建一个网站需要什么条件浪网站制作
  • 图片库网站建设花都网站开发公司
  • 类似情侣空间的网站开发织梦资讯门户网站模板
  • 免费素材下载网站有哪些做a的视频在线观看网站
  • 商城开发网站建设开发门户型网站有哪些
  • 温州哪里有网站建设制作书签图片大全简单漂亮
  • 宿迁宿豫网站建设广东建筑信息平台
  • 建立了公司门户网站做影视会员网站
  • 瑞安门户网站建设嘉兴路街道网站建设