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

洛阳做网站公司在哪近期国内新闻

洛阳做网站公司在哪,近期国内新闻,北京移动端网站建设,国外二级域名免费申请1#xff0c;创建翻转面板的资源字典#xff1a;FlippPanel.xaml。 无外观控件同样必须给样式指定类型#xff08; ControlTemplate TargetTypess:FlipPanel#xff09;#xff0c;相关详情参考#xff1a;WPF之创建无外观控件-CSDN博客#xff09…1创建翻转面板的资源字典FlippPanel.xaml。 无外观控件同样必须给样式指定类型 ControlTemplate TargetTypess:FlipPanel相关详情参考WPF之创建无外观控件-CSDN博客。 ResourceDictionary xmlnshttp://schemas.microsoft.com/winfx/2006/xaml/presentationxmlns:xhttp://schemas.microsoft.com/winfx/2006/xamlxmlns:ssclr-namespace:无外观控件xmlns:localclr-namespace:无外观控件.ThemesStyle TargetTypess:FlipPanelSetter PropertyTemplateSetter.ValueControlTemplate TargetTypess:FlipPanelGridGrid.RowDefinitionsRowDefinition Heightauto/RowDefinitionRowDefinition Heightauto/RowDefinition/Grid.RowDefinitions!--1为给模板添加VisualStateManager元素模板必须使用布局面板。布局面板包含控件的两个可视化对象和VisualStateManager元素该元素不可见--VisualStateManager.VisualStateGroupsVisualStateGroup NameViewStatesVisualStateGroup.Transitions!--两个可视对象切换时间以及伴随的ToggleButton切换动画--VisualTransition ToNormal GeneratedDuration00:00:01Storyboard DoubleAnimation To0 Storyboard.TargetNamePART_Rota Storyboard.TargetPropertyAngle /DoubleAnimation/Storyboard/VisualTransitionVisualTransition ToFlipped GeneratedDuration00:00:2Storyboard DoubleAnimation To180 Storyboard.TargetNamePART_Rota Storyboard.TargetPropertyAngle /DoubleAnimation/Storyboard/VisualTransition/VisualStateGroup.TransitionsVisualState NameNormalStoryboard DoubleAnimation To0 Storyboard.TargetNamefront Storyboard.TargetPropertyOpacity Duration00:00:00/DoubleAnimation!--ToggleButton旋转动画不能省否则动画异常--DoubleAnimation To0 Storyboard.TargetNamePART_Rota Storyboard.TargetPropertyAngle/DoubleAnimation/Storyboard/VisualStateVisualState NameFlippedStoryboard DoubleAnimation To0 Storyboard.TargetNameback Storyboard.TargetPropertyOpacity Duration00:00:00/DoubleAnimation!--ToggleButton旋转动画不能省否则动画异常--DoubleAnimation To180 Storyboard.TargetNamePART_Rota Storyboard.TargetPropertyAngle Duration00:00:00 /DoubleAnimation/Storyboard/VisualState/VisualStateGroup/VisualStateManager.VisualStateGroupsBorder x:Namefront BorderBrush{TemplateBinding BorderBrush} CornerRadius{TemplateBinding CornerRadius} BorderThickness{TemplateBinding BorderThickness} Background{TemplateBinding Background}ContentPresenter Content{TemplateBinding FrontContent}/ContentPresenter/BorderBorder x:Nameback BorderBrush{TemplateBinding BorderBrush} CornerRadius{TemplateBinding CornerRadius} BorderThickness{TemplateBinding BorderThickness} Background{TemplateBinding Background}ContentPresenter Content{TemplateBinding BackContent}/ContentPresenter/BorderToggleButton Grid.Row1 Height40 NameFlipButton RenderTransformOrigin0.5,0.5ToggleButton.RenderTransformRotateTransform x:NamePART_Rota /RotateTransform/ToggleButton.RenderTransformToggleButton.TemplateControlTemplate TargetTypeToggleButtonToggleButton Grid.Column1 Grid.Row1 NameFlipButtonToggleButton.TemplateControlTemplate TargetTypeToggleButtonRectangle Rectangle.FillDrawingBrush StretchNoneDrawingBrush.DrawingGeometryDrawing BrushWhiteGeometryDrawing.PenPen BrushBlack Thickness2/Pen/GeometryDrawing.PenGeometryDrawing.GeometryGeometryGroupEllipseGeometry RadiusX15 RadiusY15/EllipseGeometryCombinedGeometry GeometryCombineModeIntersectCombinedGeometry.Geometry1EllipseGeometry RadiusX7.5 RadiusY7.5/EllipseGeometry/CombinedGeometry.Geometry1CombinedGeometry.Geometry2PathGeometry FiguresM-7.5,0 L0,-7.5 L7.5,-7.5 L0,0 L7.5,7.5 L0,7.5 Z/PathGeometry/CombinedGeometry.Geometry2/CombinedGeometry/GeometryGroup/GeometryDrawing.Geometry/GeometryDrawing/DrawingBrush.Drawing/DrawingBrush/Rectangle.Fill/Rectangle/ControlTemplate/ToggleButton.Template/ToggleButton/ControlTemplate/ToggleButton.Template/ToggleButton/Grid/ControlTemplate/Setter.Value/Setter/Style /ResourceDictionary VisualStateManager只能在布局面板下进行状态管理。 2在generic.xaml中添加资源字典FlipPanel.xaml. ResourceDictionaryxmlnshttp://schemas.microsoft.com/winfx/2006/xaml/presentationxmlns:xhttp://schemas.microsoft.com/winfx/2006/xamlResourceDictionary.MergedDictionariesResourceDictionary Source无外观控件;component/Themes/colorpicker.xaml/ResourceDictionaryResourceDictionary Source无外观控件;component/Themes/FlipPanel.xaml/ResourceDictionary/ResourceDictionary.MergedDictionaries /ResourceDictionary 3,编写代码 [TemplatePart(Name FlipButton, Type typeof(ToggleButton))]//该特性只是进行提示无其他意义可舍去[TemplateVisualState(GroupName Normal, Name ViewStates)]//该特性提示存在可视化切换无其他实际意义可舍去[TemplateVisualState(GroupName Flipped, Name ViewStates)]public class FlipPanel : Control{public static readonly DependencyProperty CornerRadiusProperty;public static readonly DependencyProperty FrontContentProperty;public static readonly DependencyProperty BackContentProperty;public static readonly DependencyProperty IsFlippedProperty;static FlipPanel(){DefaultStyleKeyProperty.OverrideMetadata(typeof(FlipPanel), new FrameworkPropertyMetadata(typeof(FlipPanel)));CornerRadiusProperty DependencyProperty.Register(CornerRadius, typeof(CornerRadius), typeof(FlipPanel));FrontContentProperty DependencyProperty.Register(FrontContent, typeof(object), typeof(FlipPanel));BackContentProperty DependencyProperty.Register(BackContent, typeof(object), typeof(FlipPanel));IsFlippedProperty DependencyProperty.Register(IsFlipped, typeof(bool), typeof(FlipPanel));}/// summary/// 设置控件边框倒角/// /summarypublic CornerRadius CornerRadius{get{return (CornerRadius)this.GetValue(CornerRadiusProperty);}set{this.SetValue(CornerRadiusProperty, value);}}/// summary/// 前置内容/// /summarypublic object FrontContent{get{return this.GetValue(FrontContentProperty);}set{this.SetValue(FrontContentProperty, value);}}/// summary/// 后置内容/// /summarypublic object BackContent{get{return GetValue(BackContentProperty);}set{this.SetValue(BackContentProperty, value);}}/// summary/// 是否翻转/// /summarypublic bool IsFlipped{get{return (bool)GetValue(IsFlippedProperty);}set{SetValue(IsFlippedProperty, value);ChangeVisualState(true);}}public override void OnApplyTemplate(){ToggleButton btn GetTemplateChild(FlipButton) as ToggleButton;btn.Click Btn_Click;ChangeVisualState(false);base.OnApplyTemplate();}private void Btn_Click(object sender, RoutedEventArgs e){IsFlipped !IsFlipped;}void ChangeVisualState(bool useTransition){if (IsFlipped){VisualStateManager.GoToState(this, Flipped, useTransition);}else{VisualStateManager.GoToState(this, Normal, useTransition);}}} 4在UI上添加控件 local:FlipPanel Grid.Row1 IsFlippedTruelocal:FlipPanel.FrontContentStackPanelButton Content前1/ButtonButton Content前2/ButtonButton Content前3/ButtonButton Content前3/ButtonButton Content前4/Button/StackPanel/local:FlipPanel.FrontContentlocal:FlipPanel.BackContentStackPanelButton Content后1/Button/StackPanel/local:FlipPanel.BackContent/local:FlipPanel 5效果 6Demo 链接 https://download.csdn.net/download/lingxiao16888/89253829?spm1001.2014.3001.5501
http://www.hkea.cn/news/14567619/

相关文章:

  • 甘肃省长城建设集团网站无代码网站开发
  • 南宁网站建设平台网页设计与制作教程欧静敏
  • 个人网站备案地址选择化妆品营销型网站模板
  • 高端品牌网站建设策略网站建设需求有什么用
  • 梅州市城乡建设局网站怎么做百度推广网站
  • 做心理咨询可以在哪些网站发贴wordpress把文章转语音
  • 天水做网站的wordpress淘宝客单页主题
  • 个人做淘宝客网站好做吗定制高端网站的公司
  • 怎么建立自己的公司网站在线做抽奖网站
  • 贵阳网站建设托管长沙app下载
  • 图片网站模版衣服网站模板
  • 摩托车网站建设青浦做网站价格
  • 中英文的网站是怎么做的广州网上推广平台
  • 外包公司网站世界500强企业名单
  • 恩施网站建设公司海口百度seo公司
  • 建设银行信用卡官网站河北做网站
  • 公司网站维护与更新全网业务自助商城
  • 专业 旅游网站建设wordpress使用技巧
  • 提供做网站公司有哪些dedecms本地可以更换网站模板出现网站模板不存在
  • 天猫网站建设的目的网站的优点有哪些
  • 重庆建站网站企业单页淘宝客网站2014年行吗
  • 域名证书查询网站如何开启wordpress mu
  • oa网站开发模板域名服务器地址
  • 网站设计相似侵权吗公共资源交易中心总结
  • 电子商务网站建设与推广做外贸网站用什么软件
  • 二级域名免费网站怎么申请wordpress 写文章页面
  • 做外汇看哪个网站软件产品如何做网站推广
  • 织梦网站建设实验报告vps lnmp wordpress
  • 我想注册一个网站怎么注册创建网站成功案例
  • 网站建设教程吧网站建设方案对比分析报告