Merge branch 'master' into update-doc
This commit is contained in:
162 files changed
+4860
-1329
No files matched your search
@@ -1,5 +1,115 @@
|
||||
---
|
||||
title: 建设中
|
||||
title: RadioButton 单选按钮
|
||||
---
|
||||
|
||||
建设中
|
||||
# RadioButtonBaseStyle
|
||||
|
||||
单选按钮默认样式,不推荐直接使用,应该始终被其它样式以BasedOn的方式使用。
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<StackPanel>
|
||||
<RadioButton Content="默认样式"/>
|
||||
<RadioButton Margin="0,16,0,0" Content="不可编辑" IsChecked="True" IsEnabled="False"/>
|
||||
<RadioButton Margin="0,16,0,0" Content="默认样式"/>
|
||||
<RadioButton Margin="0,16,0,0" Content="不可编辑" IsEnabled="False"/>
|
||||
</StackPanel>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# RadioButtonIcon:RadioButtonBaseStyle
|
||||
|
||||
带图标样式,可只显示图标也可图文显示
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<UniformGrid Margin="22,0,0,0" Rows="2" Columns="2">
|
||||
<RadioButton Margin="10,0,0,0" Background="{DynamicResource SecondaryRegionBrush}" hc:IconElement.Geometry="{StaticResource CalendarGeometry}" Style="{StaticResource RadioButtonIcon}" Content="RadioButtonIcon"/>
|
||||
<RadioButton Margin="10,0,0,0" Background="{DynamicResource SecondaryRegionBrush}" Style="{StaticResource RadioButtonIcon}" Content="RadioButtonIcon" IsChecked="True"/>
|
||||
<RadioButton Margin="10,0,0,0" BorderThickness="1" hc:IconElement.Geometry="{StaticResource CalendarGeometry}" Style="{StaticResource RadioButtonIcon}" Content="RadioButtonIcon"/>
|
||||
<RadioButton Margin="10,0,0,0" BorderThickness="1" Style="{StaticResource RadioButtonIcon}" Content="RadioButtonIcon"/>
|
||||
</UniformGrid>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# RadioGroupItemBaseStyle
|
||||
|
||||
`ButtonGroup`控件中的子集`RadioButton`样式基类,不建议直接使用,常作为`ButtonGroup`中`Item`样式基类,同时与`ButtonGroup`控件配套使用
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<!--内部Item样式为ButtonGroup控件自动附加-默认为水平方向item样式-->
|
||||
<hc:ButtonGroup Margin="0,32,0,0">
|
||||
<RadioButton Content="RadioButton" IsChecked="True"/>
|
||||
<RadioButton Content="RadioButton"/>
|
||||
<RadioButton IsEnabled="False" Content="RadioButton"/>
|
||||
<RadioButton Content="RadioButton"/>
|
||||
</hc:ButtonGroup>
|
||||
<hc:ButtonGroup Margin="0,16,0,0" Style="{StaticResource ButtonGroupSolid}">
|
||||
<RadioButton Content="RadioButton"/>
|
||||
<RadioButton Content="RadioButton"/>
|
||||
<RadioButton IsEnabled="False" Content="RadioButton"/>
|
||||
<RadioButton Content="RadioButton" IsChecked="True"/>
|
||||
</hc:ButtonGroup>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# RadioGroup关联样式
|
||||
|
||||
| 样式Key | 用途 | 基类样式 |
|
||||
| ----------------------------- | ------------------------------------ | ----------------------- |
|
||||
| RadioGroupItemDefault | RadioGroupItem默认样式 | RadioGroupItemBaseStyle |
|
||||
| RadioGroupItemHorizontalFirst | RadioGroupItem水平头样式(从左至右) | RadioGroupItemBaseStyle |
|
||||
| RadioGroupItemHorizontalLast | RadioGroupItem水平尾样式(从左至右) | RadioGroupItemBaseStyle |
|
||||
| RadioGroupItemSingle | RadioGroupItem单项样式 | RadioGroupItemBaseStyle |
|
||||
| RadioGroupItemVerticalFirst | RadioGroupItem垂直头样式(从上至下) | RadioGroupItemBaseStyle |
|
||||
| RadioGroupItemVerticalLast | RadioGroupItem垂直尾样式(从上至下) | RadioGroupItemBaseStyle |
|
||||
|
||||
案例:
|
||||
|
||||
单个`RadioButton`样式:
|
||||
|
||||
```xml
|
||||
<RadioButton Style="{DynamicResource RadioGroupItemSingle}"
|
||||
Margin="0,16,8,0"
|
||||
Content="RadioGroupItemSingle"></RadioButton>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
多个`RadioButton`垂直样式:
|
||||
|
||||
```xml
|
||||
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
|
||||
<hc:ButtonGroup Margin="0,16,8,0" Orientation="Vertical">
|
||||
<RadioButton Content="RadioButton" IsChecked="True"/>
|
||||
<RadioButton Content="RadioButton"/>
|
||||
<RadioButton IsEnabled="False" Content="RadioButton"/>
|
||||
<RadioButton Content="RadioButton"/>
|
||||
</hc:ButtonGroup>
|
||||
<hc:ButtonGroup Margin="8,16,0,0" Orientation="Vertical" Style="{StaticResource ButtonGroupSolid}">
|
||||
<RadioButton Content="RadioButton"/>
|
||||
<RadioButton Content="RadioButton"/>
|
||||
<RadioButton IsEnabled="False" Content="RadioButton"/>
|
||||
<RadioButton Content="RadioButton" IsChecked="True"/>
|
||||
</hc:ButtonGroup>
|
||||
</StackPanel>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
@@ -1,5 +1,21 @@
|
||||
---
|
||||
title: 建设中
|
||||
title: RichTextBox 富文本框
|
||||
---
|
||||
|
||||
建设中
|
||||
# TextBoxBaseBaseStyle
|
||||
|
||||
基础文本控件默认样式,不推荐直接使用,应该始终被其它样式以BasedOn的方式使用。
|
||||
|
||||
# RichTextBoxBaseStyle : TextBoxBaseBaseStyle
|
||||
|
||||
富文本框默认样式,不推荐直接使用,应该始终被其它样式以BasedOn的方式使用。
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<RichTextBox Margin="10,10" VerticalAlignment="Center" HorizontalAlignment="Center"></RichTextBox>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
@@ -1,5 +1,42 @@
|
||||
---
|
||||
title: 建设中
|
||||
title: ScrollViewer 滚动视图
|
||||
---
|
||||
|
||||
建设中
|
||||
# ScrollViewerNativeBaseStyle
|
||||
|
||||
原生滚动视图默认样式,不推荐直接使用,应该始终被其它样式以BasedOn的方式使用。
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<ScrollViewer>
|
||||
<Grid Height="500">
|
||||
<TextBlock Text="内容区域"></TextBlock>
|
||||
</Grid>
|
||||
</ScrollViewer>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# ScrollViewerUpDown
|
||||
|
||||
显示上下按钮的滚动视图样式
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<ScrollViewer Style="{StaticResource ScrollViewerUpDown}">
|
||||
<StackPanel Height="500">
|
||||
<TextBlock Text="内容区域" Height="250"></TextBlock>
|
||||
<TextBlock Text="内容区域" Height="250"></TextBlock>
|
||||
<TextBlock Text="内容区域"></TextBlock>
|
||||
<TextBlock Text="内容区域"></TextBlock>
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
@@ -1,5 +1,17 @@
|
||||
---
|
||||
title: 建设中
|
||||
title: Slider 滑块
|
||||
---
|
||||
|
||||
建设中
|
||||
# SliderBaseStyle
|
||||
|
||||
滑块默认样式,不推荐直接使用,应该始终被其它样式以BasedOn的方式使用。
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<Slider VerticalAlignment="Center" Width="400" Value="40" Maximum="100"/>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
@@ -1,5 +1,93 @@
|
||||
---
|
||||
title: 建设中
|
||||
title: TabControl 选项卡控件
|
||||
---
|
||||
|
||||
建设中
|
||||
# TabControlBaseStyle
|
||||
|
||||
选项卡控件默认样式,不推荐直接使用,应该始终被其它样式以BasedOn的方式使用。
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<TabControl Margin="10">
|
||||
<TabItem Header="选项卡1">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡2">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡3">
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# TabControlInLine : TabControlBaseStyle
|
||||
|
||||
单行填充选项卡样式
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<TabControl Margin="10" Style="{StaticResource TabControlInLine}">
|
||||
<TabItem Header="选项卡1">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡2">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡3">
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# TabControlCapsule
|
||||
|
||||
胶囊状选项卡样式
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<TabControl Margin="10" Style="{StaticResource TabControlCapsule}">
|
||||
<TabItem Header="选项卡1">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡2">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡3">
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# TabControlCapsuleSolid : TabControlCapsule
|
||||
|
||||
胶囊状(实心)选项卡样式
|
||||
|
||||
案例:
|
||||
|
||||
```xml
|
||||
<TabControl Margin="10" Style="{StaticResource TabControlCapsuleSolid}">
|
||||
<TabItem Header="选项卡1">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡2">
|
||||
</TabItem>
|
||||
<TabItem Header="选项卡3">
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
```
|
||||
|
||||
效果:
|
||||
|
||||

|
||||
|
||||
# 温馨提示
|
||||
|
||||
可以使用属性`TabStripPlacement`设定头部标题的位置,效果如下:
|
||||
|
||||

|
||||
Reference in new issue
Block a user