目录

  • 明确定义什么样式
  • 抛弃原始样式
    • 定义圆角窗体样式
    • 调整窗体最大化最小化和关闭样式
    • 定义样式文件
  • 使用统一样式的方式
    • 引用样式达到达到统一风格
  • 窗体的事件处理
    • 窗体拖动事件处理
    • 窗体大小调整事件处理
  • Dome案例

明确定义什么样式

要统一窗体风格样式,就要明确自己要使用什么样的风格样式,我这里使用统一的 圆角边框,调整原始窗体的最大化最小化和关闭按钮的窗体样式。

抛弃原始样式

定义圆角窗体样式

我们需要设置WPF的窗体样式为None,其次,我们需要设置AllowTransParency为True,BackGround为Transparent,OpacityMask为White,这样设置才能保证当我们设置为圆角的时候,四个角能够透明显示。圆角使用Border元素即可简单实现,首先要明确它的几个属性,BorderThickness用来表示Border的粗细程度,BorderBrush用来表示Border的颜色,CornerRadius表明四个角的弯曲度。实现代码如下:

<Window x:Class="WpfApp1.Point.Window1"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:WpfApp1.Point"mc:Ignorable="d"Title="Window1" Height="450" Width="800"WindowStyle="None" AllowsTransparency="True" Background="Transparent" OpacityMask="White" WindowStartupLocation="CenterScreen"><Grid Background="Transparent"><Border BorderThickness="5" BorderBrush="DarkGreen" CornerRadius="10,10,10,10" Name="top"></Border></Grid>
</Window>

运行效果如下(窗体圆角透明):

调整窗体最大化最小化和关闭样式

代码如下:

    <Window.Resources><!-- Close Button --><Style x:Key="CloseRadialButton" TargetType="Button"><Setter Property="SnapsToDevicePixels" Value="true" /><Setter Property="OverridesDefaultStyle" Value="true" /><Setter Property="MinHeight" Value="13" /><Setter Property="MinWidth" Value="13" /><Setter Property="Opacity" Value=".75"/><Setter Property="Template"><Setter.Value><ControlTemplate TargetType="Button"><Grid><Ellipse x:Name="borderBtn" Width="18" Height="18" StrokeThickness="2" Fill="#FFE52B2B" Stroke="White"></Ellipse><!--按钮内容--><Grid><Canvas HorizontalAlignment="Left" VerticalAlignment="Top" Margin="5"><Line StrokeThickness="2" Stroke="White" X1="0" Y1="0" X2="8" Y2="8"></Line><Line StrokeThickness="2" Stroke="White" X1="0" Y1="8" X2="8" Y2="0"></Line></Canvas></Grid></Grid><ControlTemplate.Triggers><Trigger Property="Button.IsMouseOver"  Value="True"><Setter Property="Opacity" Value="1" /></Trigger></ControlTemplate.Triggers></ControlTemplate></Setter.Value></Setter></Style><!-- Minimize Button --><Style x:Key="MinimizeRadialButton" TargetType="Button"><Setter Property="SnapsToDevicePixels" Value="true" /><Setter Property="OverridesDefaultStyle" Value="true" /><Setter Property="MinHeight" Value="13" /><Setter Property="MinWidth" Value="13" /><Setter Property="Opacity" Value=".75" /><Setter Property="Template"><Setter.Value><ControlTemplate TargetType="Button"><Grid><Rectangle Width="18" Height="16" Fill="White" Opacity=".1" RadiusX="4" RadiusY="4" StrokeThickness="2"></Rectangle><Rectangle Width="18" Height="16" StrokeThickness="2" RadiusX="4" RadiusY="4" Stroke="White"></Rectangle><!--按钮内容--><Grid><Canvas HorizontalAlignment="Left" VerticalAlignment="Top" Margin="5"><Line StrokeThickness="2" Stroke="White" X1="0" Y1="4" X2="8" Y2="4"></Line></Canvas></Grid></Grid><ControlTemplate.Triggers><Trigger Property="Button.IsMouseOver"  Value="True"><Setter Property="Opacity" Value="1" /></Trigger></ControlTemplate.Triggers></ControlTemplate></Setter.Value></Setter></Style><!-- Maximize Button --><Style x:Key="MaximizeRadialButton" TargetType="Button"><Setter Property="SnapsToDevicePixels" Value="true" /><Setter Property="OverridesDefaultStyle" Value="true" /><Setter Property="MinHeight" Value="13" /><Setter Property="MinWidth" Value="13" /><Setter Property="Opacity" Value=".75" /><Setter Property="Template"><Setter.Value><ControlTemplate TargetType="Button"><Grid><Rectangle Width="18" Height="16" Fill="White" Opacity=".1" RadiusX="4" RadiusY="4" StrokeThickness="2"></Rectangle><Rectangle Width="18" Height="16" StrokeThickness="2" RadiusX="4" RadiusY="4" Stroke="White"></Rectangle><!--按钮内容--><Grid><Canvas HorizontalAlignment="Left" VerticalAlignment="Top"  Margin="4"><Rectangle Width="10" Height="8" StrokeThickness="2" RadiusX="2" RadiusY="2" Stroke="White"></Rectangle></Canvas></Grid></Grid><ControlTemplate.Triggers><Trigger Property="Button.IsMouseOver"  Value="True"><Setter Property="Opacity" Value="1" /></Trigger></ControlTemplate.Triggers></ControlTemplate></Setter.Value></Setter></Style><!-- Skin Button --><Style x:Key="SkinRadialButton" TargetType="Button"><Setter Property="SnapsToDevicePixels" Value="true" /><Setter Property="OverridesDefaultStyle" Value="true" /><Setter Property="MinHeight" Value="13" /><Setter Property="MinWidth" Value="13" /><Setter Property="Opacity" Value=".75" /><Setter Property="Template"><Setter.Value><ControlTemplate TargetType="Button"><Grid><!--按钮内容--><Grid><Image Source="../Images/Skin.png" Width="18" Height="18" ></Image></Grid></Grid><ControlTemplate.Triggers><Trigger Property="Button.IsMouseOver"  Value="True"><Setter Property="Opacity" Value="1" /></Trigger></ControlTemplate.Triggers></ControlTemplate></Setter.Value></Setter></Style></Window.Resources><Grid Background="Transparent"><Border BorderThickness="5" BorderBrush="DarkGreen" CornerRadius="10,10,10,10" Name="top"><Grid><Grid.RowDefinitions><RowDefinition Height="Auto" /><RowDefinition /></Grid.RowDefinitions><Border    Padding="15" CornerRadius="10, 10, 0, 0"><Border.Background><LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0"><GradientStop Color="Green"/><GradientStop Color="Black" Offset="1"/></LinearGradientBrush></Border.Background></Border><TextBlock Foreground="White" Text="窗体标题" HorizontalAlignment="Center" VerticalAlignment="Center" FontWeight="Normal" /><StackPanel Orientation="Horizontal" FlowDirection="RightToLeft"><Button x:Name="CloseBtn" Style="{StaticResource CloseRadialButton}"HorizontalAlignment="Left" VerticalAlignment="Center" Margin="10,0,0,0" /><Button x:Name="MaxBtn" Style="{StaticResource MaximizeRadialButton}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="7,0,0,0" /><Button x:Name="MinBtn" Style="{StaticResource MinimizeRadialButton}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="7,0,0,0" /><Button x:Name="SkinBtn" Style="{StaticResource SkinRadialButton}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="7,0,0,0" /></StackPanel></Grid></Border></Grid>

运行效果如下:

定义样式文件

使用这种方式应用样式不可能减少我们工作量的,我们需要把它定义成样式文件,这样新的窗体直接引用该样式即可实现这样的样式风格。
1:添加一个用户资源字典存储样式信息
样式文件1:

<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"x:Class="Demo_Common.Resource_Dictionaries.MacStyledWindow"><ResourceDictionary.MergedDictionaries><!-- Resource Dictionary containing Buttons used for the Mac Window titlebar buttons--><ResourceDictionary Source="MacStyledTitleBarButtons.xaml" /></ResourceDictionary.MergedDictionaries><!-- Border defining the frame of the Window --><Style x:Key="MacwindowBorder" TargetType="Border"><Setter Property="CornerRadius" Value="10, 10, 0, 0" /><Setter Property="Background" Value="#ababab" /><Setter Property="BorderBrush" Value="DimGray" /><Setter Property="BorderThickness" Value="1" /><Setter Property="HorizontalAlignment" Value="Stretch" /><Setter Property="VerticalAlignment" Value="Stretch" /></Style><!-- Window Template --><ControlTemplate x:Key="MacWindowTemplate" TargetType="{x:Type Window}"><Grid><!--this border(MacWindowFrame) used for Drag-Resize--><Border Name="MacWindowFrame" Style="{StaticResource MacwindowBorder}"><Grid><Grid.RowDefinitions><RowDefinition Height="Auto" /><RowDefinition /></Grid.RowDefinitions><!-- The title bar. --><Border    Padding="15" CornerRadius="10, 10, 0, 0" Name="top"><Border.Background><LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0"><GradientStop Color="Green"/><GradientStop Color="Black" Offset="1"/></LinearGradientBrush></Border.Background></Border><TextBlock Foreground="White" Text="{TemplateBinding Title}" HorizontalAlignment="Center" VerticalAlignment="Center" FontWeight="Normal" /><StackPanel Orientation="Horizontal" FlowDirection="RightToLeft"><Button x:Name="CloseBtn" Style="{StaticResource CloseRadialButton}"HorizontalAlignment="Left" VerticalAlignment="Center" Margin="10,0,0,0" /><Button x:Name="MaxBtn" Style="{StaticResource MaximizeRadialButton}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="7,0,0,0" /><Button x:Name="MinBtn" Style="{StaticResource MinimizeRadialButton}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="7,0,0,0" /></StackPanel><Border  Grid.Row="1 "><Border.Background><ImageBrush x:Name="MyBgImg" TileMode="Tile" Viewbox="0, 0, 100, 100" ViewboxUnits="Absolute" Viewport="0, 0, 100, 100" ViewportUnits="Absolute" ImageSource="../Image/slider.png" Opacity=".25"/></Border.Background></Border></Grid></Border></Grid></ControlTemplate><!-- Mac Window Style --><Style x:Key="MacWindowStyle" TargetType="Window"><Setter Property="Background" Value="Transparent" /><Setter Property="WindowStyle" Value="None" /><Setter Property="AllowsTransparency" Value="True" /><Setter Property="Opacity" Value="0.95" /><Setter Property="Template" Value="{StaticResource MacWindowTemplate}" /></Style></ResourceDictionary>

样式文件2:

<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"><!-- Close Button --><Style x:Key="CloseRadialButton" TargetType="Button"><Setter Property="SnapsToDevicePixels" Value="true" /><Setter Property="OverridesDefaultStyle" Value="true" /><Setter Property="MinHeight" Value="13" /><Setter Property="MinWidth" Value="13" /><Setter Property="Opacity" Value=".75"/><Setter Property="Template"><Setter.Value><ControlTemplate TargetType="Button"><Grid><Ellipse x:Name="borderBtn" Width="18" Height="18" StrokeThickness="2" Fill="#FFE52B2B" Stroke="White"></Ellipse><!--按钮内容--><Grid><Canvas HorizontalAlignment="Left" VerticalAlignment="Top" Margin="5"><Line StrokeThickness="2" Stroke="White" X1="0" Y1="0" X2="8" Y2="8"></Line><Line StrokeThickness="2" Stroke="White" X1="0" Y1="8" X2="8" Y2="0"></Line></Canvas></Grid></Grid><ControlTemplate.Triggers><Trigger Property="Button.IsMouseOver"  Value="True"><Setter Property="Opacity" Value="1" /></Trigger></ControlTemplate.Triggers></ControlTemplate></Setter.Value></Setter></Style><!-- Minimize Button --><Style x:Key="MinimizeRadialButton" TargetType="Button"><Setter Property="SnapsToDevicePixels" Value="true" /><Setter Property="OverridesDefaultStyle" Value="true" /><Setter Property="MinHeight" Value="13" /><Setter Property="MinWidth" Value="13" /><Setter Property="Opacity" Value=".75" /><Setter Property="Template"><Setter.Value><ControlTemplate TargetType="Button"><Grid><Rectangle Width="18" Height="16" Fill="White" Opacity=".1" RadiusX="4" RadiusY="4" StrokeThickness="2"></Rectangle><Rectangle Width="18" Height="16" StrokeThickness="2" RadiusX="4" RadiusY="4" Stroke="White"></Rectangle><!--按钮内容--><Grid><Canvas HorizontalAlignment="Left" VerticalAlignment="Top" Margin="5"><Line StrokeThickness="2" Stroke="White" X1="0" Y1="4" X2="8" Y2="4"></Line></Canvas></Grid></Grid><ControlTemplate.Triggers><Trigger Property="Button.IsMouseOver"  Value="True"><Setter Property="Opacity" Value="1" /></Trigger></ControlTemplate.Triggers></ControlTemplate></Setter.Value></Setter></Style><!-- Maximize Button --><Style x:Key="MaximizeRadialButton" TargetType="Button"><Setter Property="SnapsToDevicePixels" Value="true" /><Setter Property="OverridesDefaultStyle" Value="true" /><Setter Property="MinHeight" Value="13" /><Setter Property="MinWidth" Value="13" /><Setter Property="Opacity" Value=".75" /><Setter Property="Template"><Setter.Value><ControlTemplate TargetType="Button"><Grid><Rectangle Width="18" Height="16" Fill="White" Opacity=".1" RadiusX="4" RadiusY="4" StrokeThickness="2"></Rectangle><Rectangle Width="18" Height="16" StrokeThickness="2" RadiusX="4" RadiusY="4" Stroke="White"></Rectangle><!--按钮内容--><Grid><Canvas HorizontalAlignment="Left" VerticalAlignment="Top"  Margin="4"><Rectangle Width="10" Height="8" StrokeThickness="2" RadiusX="2" RadiusY="2" Stroke="White"></Rectangle></Canvas></Grid></Grid><ControlTemplate.Triggers><Trigger Property="Button.IsMouseOver"  Value="True"><Setter Property="Opacity" Value="1" /></Trigger></ControlTemplate.Triggers></ControlTemplate></Setter.Value></Setter></Style></ResourceDictionary>

使用统一样式的方式

引用样式达到达到统一风格

样式创建完成其实就可以通过应用样式(Style="{StaticResource MacWindowStyle}")的方式达到统一的效果了,如下:

<Window x:Class="WpfApp1.Point.Window1"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"mc:Ignorable="d"Title="测试2" Height="450" Width="800"        Style="{StaticResource MacWindowStyle}"></Window>

运行效果:

窗体的事件处理

引用完样式启动程序你会发现,窗体不能拖动,不能最大最小化,关闭按钮也只是摆设,因为我们没有给窗体做事件处理。

窗体拖动事件处理

可以在窗体初始化是注册鼠标左键按下事件,调用Window.DragMove()方法完成工作区域内拖动处理。
代码如下:

public Window1()
{InitializeComponent();this.MouseLeftButtonDown += DragWindow;
}
private void DragWindow(object sender, MouseButtonEventArgs e)
{this.DragMove();
}

窗体大小调整事件处理

由于要涉及到和Win32交互,我们需要订阅SourceInitialized事件。
一样的我们需要在窗体初始化时订阅该事件。
代码如下:

 public Window1(){InitializeComponent();this.SourceInitialized += new EventHandler(WSInitialized);//调整大小}

由于涉及到SourceInitialized Event,我们就需要使用到HwndSource,它主要功能就是WPF放入到Win32窗体中。让我们看看WindowSourceInitialized事件:

void WSInitialized(object sender, EventArgs e)
{hs = PresentationSource.FromVisual(this) as HwndSource;hs.AddHook(new HwndSourceHook(WndProc));
}

接下来我们看到,窗体Hook了一个 HwndSourceHook的委托,这个委托能够接受所有经过Windows的消息。我们来看看WndProc函数:

Dictionary<int, int> messages = new Dictionary<int, int>();private IntPtr WndProc(IntPtr hwnd, int msg, IntPtr wParam, IntPtr lParam, ref bool handled)
{Debug.Print(string.Format("窗体消息: {0}, wParam: {1} , lParam: {2}", msg.ToString(), wParam.ToString(), lParam.ToString()));if (messages.ContainsKey(msg) == false){messages.Add(msg, msg);// 添加接收到的WIndows信息到ListBox中listMsg.Items.Add(msg);}return new IntPtr();
}

这个函数会接收到所有windows消息,打印到Debug台上。

接下来,知道了事件处理流程,我们开始讨论拖拉窗体的问题。

首先,我们先给窗体添加一个ResetCursor事件,以便于拖拉结束后,恢复鼠标指针:

<Window x:Class="WpfApplication1.MsgWindow"xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"Title="TestWindow" Height="391" Width="418" WindowStyle="None" AllowsTransparency="True" Background="Transparent" OpacityMask="White" ResizeMode="NoResize" PreviewMouseMove="ResetCursor" WindowStartupLocation="CenterScreen">

其次,我们给Border元素添加一个MouseMove事件,用来显示鼠标特定情况下的鼠标指针形状(如达到了窗体边缘,则变换为拖拉的鼠标形状),同时添加一个PreviewMouseDown事件,用来进行Resize操作(也就是鼠标左键按下,开始进行拖放):

<Border BorderThickness="5" BorderBrush="DarkGreen"  CornerRadius="10,10,10,10" MouseMove="DisplayResizeCursor" PreviewMouseDown="Resize" Name="top">

这样,当事件添加好以后,我们转换到后台代码:

由于窗体总共有八个地方可以进行拖拉,分别是Top,TopRight,Right,BottomRight,Bottom,BottomLeft,Left,TopLeft,那么我们先声明一个Enum:

public enum ResizeDirection{Left = ,Right = ,Top = ,TopLeft = ,TopRight = ,Bottom = ,BottomLeft = ,BottomRight = ,}

在Win32中,由于61440+1 代表左边,61440+2代表右边,一次类推,所以我们需要进行如下设计:

[DllImport("user32.dll", CharSet = CharSet.Auto)]
private static extern IntPtr SendMessage(IntPtr hWnd, uint Msg, IntPtr wParam, IntPtr lParam);private void ResizeWindow(ResizeDirection direction)
{SendMessage(hs.Handle, WM_SYSCOMMAND, (IntPtr)( + direction), IntPtr.Zero);
}

这样,通过上面的函数,我们就可以实现窗体的Resize,下面我们来响应鼠标事件:

首先是窗体的ResetCursor事件,这个主要是用来恢复鼠标形状:

private void ResetCursor(object sender, MouseEventArgs e)
{if (Mouse.LeftButton != MouseButtonState.Pressed){this.Cursor = Cursors.Arrow;}
}

然后我们来看看DisplayResizeCursor事件,它主要是用来改变鼠标形状,当鼠标达到一定区域,则显示拖拉的鼠标形状(<->):

其计算方式,如下:

private void DisplayResizeCursor(object sender, MouseEventArgs e){Border clickBorder = sender as Border;Point pos = Mouse.GetPosition(this);double x = pos.X;double y = pos.Y;double w= this.Width;double h= this.Height;this.label1.Content = x + "--" + y;if (x <= relativeClip & y <= relativeClip) // left top{this.Cursor = Cursors.SizeNWSE;}if (x >= w - relativeClip & y <= relativeClip) //right top{this.Cursor = Cursors.SizeNESW;}if (x >= w - relativeClip & y >= h - relativeClip) //bottom right{this.Cursor = Cursors.SizeNWSE;}if (x <= relativeClip & y >= h - relativeClip)  // bottom left{this.Cursor = Cursors.SizeNESW;}if ((x >= relativeClip & x <= w - relativeClip) & y <= relativeClip) //top{this.Cursor = Cursors.SizeNS;}if (x >= w - relativeClip & (y >= relativeClip & y <= h - relativeClip)) //right{this.Cursor = Cursors.SizeWE;}if ((x >= relativeClip & x <= w - relativeClip) & y > h - relativeClip) //bottom{this.Cursor = Cursors.SizeNS;}if (x <= relativeClip & (y <= h - relativeClip & y >= relativeClip)) //left{this.Cursor = Cursors.SizeWE;}}

最后就是Resize的函数,和上面的计算方式类似,只是拖拉的时候需要调用ResizeWindow函数来改变大小:

private void Resize(object sender, MouseButtonEventArgs e){Border clickedBorder = sender as Border;Point pos = Mouse.GetPosition(this);double x = pos.X;double y = pos.Y;double w = this.Width;double h = this.Height;if (x <= relativeClip & y <= relativeClip) // left top{this.Cursor = Cursors.SizeNWSE;ResizeWindow(ResizeDirection.TopLeft);}if (x >= w - relativeClip & y <= relativeClip) //right top{this.Cursor = Cursors.SizeNESW;ResizeWindow(ResizeDirection.TopRight);}if (x >= w - relativeClip & y >= h - relativeClip) //bottom right{this.Cursor = Cursors.SizeNWSE;ResizeWindow(ResizeDirection.BottomRight);}if (x <= relativeClip & y >= h - relativeClip)  // bottom left{this.Cursor = Cursors.SizeNESW;ResizeWindow(ResizeDirection.BottomLeft);}if ((x >= relativeClip & x <= w - relativeClip) & y <= relativeClip) //top{this.Cursor = Cursors.SizeNS;ResizeWindow(ResizeDirection.Top);}if (x >= w - relativeClip & (y >= relativeClip & y <= h - relativeClip)) //right{this.Cursor = Cursors.SizeWE;ResizeWindow(ResizeDirection.Right);}if ((x >= relativeClip & x <= w - relativeClip) & y > h - relativeClip) //bottom{this.Cursor = Cursors.SizeNS;ResizeWindow(ResizeDirection.Bottom);}if (x <= relativeClip & (y <= h - relativeClip & y >= relativeClip)) //left{this.Cursor = Cursors.SizeWE;ResizeWindow(ResizeDirection.Left);}}

Dome案例

案例下载:

使用一个统一的窗体样式风格相关推荐

  1. Dev 增加显示不同风格的窗体样式

    Dev  增加显示不同风格的窗体样式,以dev15为例子,增加ribbonControl1控件,然后增加ribbonPageGroup1 控件,然后增加skinRibbonGalleryBarItem ...

  2. android设置主题的方法,Android_修改Android App样式风格的方法,android中可以自定义主题和风格 - phpStudy...

    修改Android App样式风格的方法 android中可以自定义主题和风格.风格,也就是style,我们可以将一些统一的属性拿出来,比方说,长,宽,字体大小,字体颜色等等.可以在res/value ...

  3. MFC 窗体样式修改

    窗体创建之后,如何设置窗体的样式呢? 一般情况下使用GetWindowLongW与SetWindowLongW即可实现窗体样式的修改或者使用ModifyStyle. 关于MFC存在GetWindowL ...

  4. PHP编码规范 代码样式风格规范

    一.基本约定 1.源文件 (1).纯PHP代码源文件只使用 <?php 标签,省略关闭标签 ?> : (2).源文件中PHP代码的编码格式必须是无BOM的UTF-8格式: (3).使用 U ...

  5. php团队规范,PHP团队 编码规范 代码样式风格规范

    一.基本约定 1.源文件 2.缩进 3.行 4.关键字 和 True/False/Null 5.命名 6.代码注释标签 7.业务模块 二.代码样式风格 1.命名空间(Namespace) 和 导入(U ...

  6. sass学习笔记(二):sass的不同样式风格的输出方法

    sass的不同样式风格的输出方法 1.嵌套式nested Sass 提供了一种嵌套显示 CSS 文件的方式.例如 nav {ul {margin: 0;padding: 0;list-style: n ...

  7. arcgis api for js共享干货系列之二自定义Navigation控件样式风格

    arcgis api for js默认的Navigation控件样式风格如下图: 这样的风格不能说不好,各有各的爱好,审美观,这里也不是重点,这里的重点是如何自定义一套自己喜欢的样式风格呢:自己自定义 ...

  8. Wpf 简单制作自己的窗体样式

    最近一直在搞wpf相关的东东,由于还在门外徘徊,所以第一篇blog写了简单的制作扁平化的wpf button样式,这一篇也简单的制作属于自己wpf 窗体的样式. 废话少说,下面就开始制作自己的窗体样式 ...

  9. 百度地图 Api v3.0 自定义信息窗体样式

    一.效果图 二.代码 注意要先引入: <script src="http://api.map.baidu.com/api?v=3.0&ak=IN43cyju8PVLGfSNwl ...

最新文章

  1. 【分享】工作流支持邮件提醒相关配置
  2. 129. Leetcode 202. 快乐数 (哈希表)
  3. 计算机科学学什么语言,在计算机科学中,什么不是正式语言? [关闭]
  4. Python os.path() 模块 详解 附算例
  5. 语义分割和实例分割以及目标检测的区别(转)
  6. 直博清华!陕西女学霸:从农村走出,3次斩获国奖,还被央视采访
  7. 百度AI开发者实战营即将走进杭州,还带来了一大波福利!
  8. java中的getinstance_Java中的KeyPairGenerator getInstance()方法
  9. Gpower软件真不错
  10. echarts横向柱状图
  11. 移动中兴服务器地址,一中国移动宽带各地dns服务器地址.doc
  12. 【20保研】南开大学统计与数据科学学院2019年全国优秀大学生夏令营
  13. 十年前你绝对没有看懂的《大话西游》.
  14. 打字速度单位WPM、KPM定义与计算方法
  15. buuctf-pwn write-ups (6)
  16. redis:地理位置信息geo
  17. Bash Shell中16进制数字和ASCII字符相互转换
  18. Windows10必做的优化
  19. JAVA小项目潜艇大战
  20. jetbrains系列宝藏插件

热门文章

  1. 我凭这个引流套路做到月入10万+,你也可以(瞎编的)
  2. 用faker模拟数据
  3. qt opencv mingw转msvc
  4. jQuery自定义动画
  5. 简述包过滤防火墙的过滤原理是什么?
  6. 133、仿真-基于51单片机太阳能热水器水温水位智能监控仪报警设计(Proteus仿真+程序+配套资料等)
  7. 缓冲区(Buffer)与缓存(Cache)异同
  8. 实现自定义select标签
  9. 铁磁共振到底是什么情况?
  10. 商品价格监控API接口,详情介绍