<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:TouchKeyboard.Keyboard" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"> <Style x:Key="MyFocusVisual">
<Setter Property="Control.Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Control}">
<Grid Margin="4 2">
<Rectangle x:Name="r1" StrokeThickness="" Stroke="Black" StrokeDashArray="2 2"/>
<Border x:Name="border" Width="{TemplateBinding ActualWidth}" Height="{TemplateBinding ActualHeight}" CornerRadius="" BorderThickness="" />
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style> <Style x:Key="ShadowStyle">
<Setter Property="Control.Foreground" Value="LightGray" />
</Style> <Style x:Key="InformButton" TargetType="{x:Type Button}">
<Setter Property="OverridesDefaultStyle" Value="True"/>
<Setter Property="Margin" Value=""/>
<Setter Property="FontFamily" Value="Verdana"/>
<Setter Property="FontSize" Value="18px"/>
<Setter Property="FontWeight" Value="Bold"/>
<Setter Property="FocusVisualStyle" Value="{StaticResource MyFocusVisual}" />
<Setter Property="Background" >
<Setter.Value>
<LinearGradientBrush StartPoint="0,0" EndPoint="0,1" >
<GradientStop Color="#FF0EFF1D" Offset="0.059"/>
<GradientStop Color="#FFF7FFF7" Offset=""/>
</LinearGradientBrush>
</Setter.Value>
</Setter>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type Button}">
<Border x:Name="border"
BorderThickness=""
Padding="4,2"
CornerRadius="" Height="Auto" Width="Auto" SnapsToDevicePixels="False" BorderBrush="#FF858585">
<Border.Effect>
<DropShadowEffect BlurRadius="" Direction="" ShadowDepth="" Opacity="0.425" RenderingBias="Quality"/>
</Border.Effect>
<Border.Background>
<LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
<GradientStop Color="#FFCECECE" Offset=""/>
<GradientStop Color="#FFF7FFF7"/>
</LinearGradientBrush>
</Border.Background>
<Grid >
<ContentPresenter HorizontalAlignment="Center"
VerticalAlignment="Center" x:Name="contentShadow"
Style="{StaticResource ShadowStyle}"/>
<ContentPresenter HorizontalAlignment="Center"
VerticalAlignment="Center" x:Name="content"/>
</Grid>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="border" Property="BorderBrush" Value="#FF4788c8" />
<Setter Property="Foreground" Value="#FF4788c8" />
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter Property="Background" >
<Setter.Value>
<LinearGradientBrush StartPoint="0,0" EndPoint="0,1" >
<GradientStop Color="#FFFFD190" Offset="0.50"/>
<GradientStop Color="Orange" Offset="0.95"/>
<GradientStop Color="#FFFFD190" Offset=""/>
</LinearGradientBrush>
</Setter.Value>
</Setter> <Setter TargetName="content" Property="RenderTransform" >
<Setter.Value>
<TranslateTransform Y="1.0" />
</Setter.Value>
</Setter>
</Trigger>
<Trigger Property="IsDefaulted" Value="True">
<Setter TargetName="border" Property="BorderBrush" Value="#FF282828" />
</Trigger>
<Trigger Property="IsFocused" Value="True">
<Setter TargetName="border" Property="BorderBrush" Value="#FF282828" />
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="border" Property="Opacity" Value="0.7" />
<Setter Property="Foreground" Value="Gray" />
</Trigger> </ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style> <Style TargetType="{x:Type local:TouchScreenKeyboard}">
<Setter Property="Background" Value="White"/>
<Setter Property="Width" Value=""/>
<Setter Property="Height" Value=""/> <Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:TouchScreenKeyboard}">
<Border
CornerRadius=""
Focusable="False" BorderBrush="{x:Null}" BorderThickness="">
<Border BorderBrush="{x:Null}" BorderThickness="" CornerRadius="">
<Border.Background>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#FFDADADA" Offset="0.442"/>
<GradientStop Color="#FFEFEFEF"/>
<GradientStop Color="#FFEDEDED" Offset=""/>
</LinearGradientBrush>
</Border.Background>
<Border BorderThickness="1,1,1,5" CornerRadius="">
<Border.BorderBrush>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0.809">
<GradientStop Color="#FF4E4E4E" Offset="0.638"/>
<GradientStop Color="#FFCCCCCC" Offset=""/>
</LinearGradientBrush>
</Border.BorderBrush>
<Border BorderBrush="{x:Null}" BorderThickness="2,4,2,0" CornerRadius="" Padding=""> <StackPanel Orientation="Vertical"> <StackPanel Orientation="Horizontal" > <Button Command="local:TouchScreenKeyboard.Cmd1" Style="{StaticResource InformButton}" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd2" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd3" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.CmdBackspace" Width="" Height="" Content="回删"/> </StackPanel>
<StackPanel Orientation="Horizontal">
<Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd4" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd5" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd6" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.CmdClear" Width="" Height="" Content="清空"/>
</StackPanel> <StackPanel Orientation="Horizontal">
<Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd7" Width="" Height="" Content="" /> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd8" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd9" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.CmdEnter" Width="" Height="" Content="确定"/> </StackPanel> <StackPanel Orientation="Horizontal">
<Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.Cmd0" Width="" Height="" Content=""/> <Button Style="{StaticResource InformButton}" Command="local:TouchScreenKeyboard.CmdGreaterThan" Width="" Height="" Content="."/> <Button Style="{StaticResource InformButton}" Width="" Height="" Content=" iEvent~" FontSize=""/> </StackPanel> </StackPanel>
</Border> </Border>
</Border> </Border>
</ControlTemplate>
</Setter.Value>
</Setter>
<Setter Property="Opacity" Value="0.98"/>
</Style> </ResourceDictionary>

WPF 数字小键盘Themes的更多相关文章

  1. WinForm数字小键盘/WPF数字小键盘

    模仿原本的WinForm触摸屏小键盘制作WPF触摸屏小键盘 原WinForm触摸屏小键盘样式(WinForm采用Krypton系列控件)如下图: Designer代码如下: // // BtnNum1 ...

  2. Ay.Framework.WPF 2.0建立项目到底有多快

    2015-3-31 今天我已经优化了很多地方,让客户使用起来几乎是傻瓜式使用了,废话不多说,我们开始吧. 默认的我提供了一些图片,但是也只占用了8M多,2.0版本目前总共有45M左右大小,毕竟包含了f ...

  3. WPF 使用DMSkin for WPF 快速搭建漂亮的WPF程序

    DMSkin-for-WPF是一个基于WPF的.Net WPF开源界面库,实现了无边框的WPF开发方案,内置部分控件模板. 你可以参照模板自行修改完善.(以下简称DFW). 核心 DFW实现了比较完美 ...

  4. WPF系列教程——(一)仿TIM QQ界面 - 简书

    原文:WPF系列教程--(一)仿TIM QQ界面 - 简书 TIM QQ 我们先来看一下TIM QQ长什么样,整体可以将界面分为三个部分 TIM QQ 1. 准备 阅读本文假设你已经有XAML布局的基 ...

  5. Open-source Tutorial - Material Design for WPF UI

    安装 Material Design Themes 通过 NuGet 包管理器搜索自动安装 通过 NuGet 包管理器控制台手动安装 Install-Package MaterialDesignThe ...

  6. 基于WPF系统框架设计(5)-Ribbon整合Avalondock 2.0实现多文档界面设计(二)

    AvalonDock 是一个.NET库,用于在停靠模式布局(docking)中排列一系列WPF/WinForm控件.最新发布的版本原生支持MVVM框架.Aero Snap特效并具有更好的性能. Ava ...

  7. C# WPF实用的注册窗体

    时间如流水,只能流去不流回! 点赞再看,养成习惯,这是您给我创作的动力! 本文 Dotnet9 https://dotnet9.com 已收录,站长乐于分享dotnet相关技术,比如Winform.W ...

  8. C# WPF抽屉效果实现(C# WPF Material Design UI: Navigation Drawer & PopUp Menu)

    时间如流水,只能流去不流回! 点赞再看,养成习惯,这是您给我创作的动力! 本文 Dotnet9 https://dotnet9.com 已收录,站长乐于分享dotnet相关技术,比如Winform.W ...

  9. .NET CORE(C#) WPF简单菜单MVVM绑定

    微信公众号:Dotnet9,网站:Dotnet9,问题或建议:请网站留言, 如果对您有所帮助:欢迎赞赏. .NET CORE(C#) WPF简单菜单MVVM绑定 阅读导航 本文背景 代码实现 本文参考 ...

随机推荐

  1. 用XCA(X Certificate and key management)可视化程序管理SSL 证书(2)--生成SSL证书请求

    在上个章节中,我们提到了怎样安装XCA(X Certificate and key management)程序.这个章节我们開始正式介绍怎样用XCA生成证书请求.假设大家用过java的话.肯定知道jd ...

  2. 一切皆为 JavaScript

    JavaScript起源于Netscape公司的LiveScript语言,这是一种基于对象和事件驱动的client脚本语言.最初的设计是为了检验HTML表单输入的正确性. 早些年,JavaScript ...

  3. JVM查找类文件的顺序(转)

    配置classpath 根据path环境变量的原理,可以定义一个名为classpath环境变量,将要运行的class文件所在目录定义在该变量中. 例:set classpath=c:\ classpa ...

  4. Cocos2d-x-lua游戏两个场景互相切换MainScene01切换到MainScene02

    /* 场景一lua代码 */ require "MainScene02" local dic_size = CCDirector:sharedDirector():getWinSi ...

  5. C++不支持Unicode,即使utf8

    今天,字符串unicode我们已经不需要常理的理由,但是,一些有编程语言的悠久历史.这仍然是一个头疼. 尽管第三方库支持的假设,C++事实上没有真正有效地支持unicode.即使utf8.(注意:本文 ...

  6. C语言中字符串如何转换为二进制、八进制、十进制、十六进制

    在C语言某个程序当中需要把文本16进制转换成对应的16进制数,比如字符串"0x1a"转换成10进制的26,可以用以下函数来实现 相关函数: atof, atoi, atol, st ...

  7. stripslashes和addslashes的区别

    我们在向mysql写入数据时,比如: mysql_query(”update table set `title`=’kuhanzhu’s blog’”); 那就会出错.同asp时一样,数据库都会对单引 ...

  8. 华为C8816电信版ROOT过程

    华为C8816电信版ROOT方法, 网上的方法都不太靠谱.. 昨天弄了好久, 最终搞定.. 整理了一下.. 实用到的就方便多了. <方法不再啰嗦, 都有说明> 1. 获取手机解锁passw ...

  9. cpe移植framework后,。解决问题的现有数据库

    最近,该公司的业务需求,原始订单apk的形式CPE.渗透framework层.这被剥离cpe,从事相当长的一段,终于有时间来写博客,记下遇到的问题,未来. 第一个问题是,原来的apk有些事情,移植fr ...

  10. mongodb - 前端form表单数据传输,在保存和清除的数据格式的处理程序的 - 非递归

    //处理时间段,将ISODate("2014-10-09T18: 37: 50.0Z") 兑换 2014-10-09 18:37:50这样的格式 //截至处理6层树形结构数据,当多 ...