diff --git a/README.md b/README.md index c7f5735d..b644e505 100644 --- a/README.md +++ b/README.md @@ -35,6 +35,8 @@ + + ## Backers @@ -48,6 +50,9 @@ + + + ## Special thanks to @@ -93,6 +98,18 @@ Step 4:enjoy coding ## Latest examples +### GlowWindow + +![GlowWindow](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/GlowWindow.png) + +### FlowDocumentScrollViewerStyle + +![FlowDocumentScrollViewerStyle](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/FlowDocumentScrollViewer.png) + +### PinBox + +![PinBox](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/PinBox.png) + ### Effects ![Effects](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/Effects.png) @@ -101,6 +118,8 @@ Step 4:enjoy coding ![RelativePanel](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/RelativePanel.png) +## History publication + ### Drawer ![Drawer](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/Drawer.gif) @@ -113,8 +132,6 @@ Step 4:enjoy coding ![Divider](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/Divider.png) -## History publication - ### GeometryAnimation ![GeometryAnimation](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Resources/GeometryAnimation.gif) diff --git a/doc/source/handycontrol/extend_controls/calendarWithClock/index.md b/doc/source/handycontrol/extend_controls/calendarWithClock/index.md index ca12ad62..1705ddf9 100644 --- a/doc/source/handycontrol/extend_controls/calendarWithClock/index.md +++ b/doc/source/handycontrol/extend_controls/calendarWithClock/index.md @@ -1,5 +1,66 @@ --- -title: 建设中 +title: CalendarWithClock --- -建设中 \ No newline at end of file + +CalendarWithClock 控件由日历和时钟组成,允许用户通过鼠标选择日期和时间。 + +``` CS +[TemplatePart(Name = ElementButtonConfirm, Type = typeof(Button))] +[TemplatePart(Name = ElementClockPresenter, Type = typeof(ContentPresenter))] +[TemplatePart(Name = ElementCalendarPresenter, Type = typeof(ContentPresenter))] +public class CalendarWithClock : Control +``` + +# 创建日期选取器 + +``` XML + +``` + +``` CS +var dateTimePicker = new CalendarWithClock(); +``` + +生成的CalendarWithClock如下图所示: + +![DateTimePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/CalendarWithClock_1.png) + + + +# 选择日期和时间 + +通过鼠标分别在日历和时钟上选择日期和时间,然后点击 **确定** 按钮即可更新CalendarWithClock控件的日期和时间。 + + +也可以在XAML钟或代码中这样设置日期。 + +``` XML + +``` + +``` CS +calendarWithClock.SelectedDateTime = DateTime.Now; +``` + + + +# 属性 + +| 属性 | 描述 | +| ---------------- | ------------------ | +| SelectedDateTime | 获取或设置当前选中的日期和时间 | +| DateTimeFormat | 获取或设置用于显示选定日期和时间的格式 | +| DisplayDateTime | 获取或设置要显示的日期 | +| ShowConfirmButton | 获取或设置一个值,该值指示是是否显示 **确定** 按钮 | +| VerifyFunc | 获取或设置数据验证委托 | +| IsError | 获取或设置数据是否错误 | +| ErrorStr | 获取或设置错误提示 | +| TextType | 获取或设置文本类型 | +| ShowClearButton | 获取或设置是否显示清除按钮 | + +# 方法 + +| 方法 | 描述 | +| ---------------- | ------------------ | +| VerifyData() | 验证数据 | \ No newline at end of file diff --git a/doc/source/handycontrol/extend_controls/datePicker/index.md b/doc/source/handycontrol/extend_controls/datePicker/index.md index ca12ad62..f61a8282 100644 --- a/doc/source/handycontrol/extend_controls/datePicker/index.md +++ b/doc/source/handycontrol/extend_controls/datePicker/index.md @@ -1,5 +1,74 @@ --- -title: 建设中 +title: DatePicker --- -建设中 \ No newline at end of file +DatePicker 控件允许用户通过在文本框中键入日期或使用下拉的日历控件来选择日期。 + +``` CS +[TemplatePart(Name = ElementTextBox, Type = typeof(DatePickerTextBox))] +public class DatePicker : System.Windows.Controls.DatePicker, IDataInput +``` + +# 创建DatePicker + +``` XML + +``` + +``` CS +var datePicker = new DatePicker(); +``` + +生成的DatePicker如下图所示: + +![DatePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/DatePicker_1.png) + + + +# 选择日期 + +可以通过文本框输入日期,或者点击文本框右边的按钮打开下拉的日历控件选择日期。 + +![DatePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/DatePicker_2.png) + +也可以在XAML钟或代码中这样设置日期。 + +``` XML + +``` + +``` CS +datePicker.SelectedDate = DateTime.Now; +``` + +# 设置标题和占位符文本 + +你可以将 Header(标题)和 Placeholder(占位符)添加到DatePicker,以向用户指示其用途。 + +``` XML + +``` + + + + +# 属性 + +| 属性 | 描述 | +| ---------------- | ------------------ | +| SelectedDate | 获取或设置当前选中的日期 | +| VerifyFunc | 获取或设置数据验证委托 | +| IsError | 获取或设置数据是否错误 | +| ErrorStr | 获取或设置错误提示 | +| TextType | 获取或设置文本类型 | +| ShowClearButton | 获取或设置是否显示清除按钮 | + +# 方法 + +| 方法 | 描述 | +| ---------------- | ------------------ | +| VerifyData() | 验证数据 | + diff --git a/doc/source/handycontrol/extend_controls/dateTimePicker/index.md b/doc/source/handycontrol/extend_controls/dateTimePicker/index.md index ca12ad62..8dbbe027 100644 --- a/doc/source/handycontrol/extend_controls/dateTimePicker/index.md +++ b/doc/source/handycontrol/extend_controls/dateTimePicker/index.md @@ -1,5 +1,82 @@ --- -title: 建设中 +title: DateTimePicker --- -建设中 \ No newline at end of file + +DatePicker 控件允许用户通过在文本框中键入日期和时间,或使用下拉的日历控件来选择日期和时间。 + +``` CS +[TemplatePart(Name = ElementRoot, Type = typeof(Grid))] +[TemplatePart(Name = ElementTextBox, Type = typeof(WatermarkTextBox))] +[TemplatePart(Name = ElementButton, Type = typeof(Button))] +[TemplatePart(Name = ElementPopup, Type = typeof(Popup))] +public class DateTimePicker : Control, IDataInput +``` + +# 创建DateTimePicker + +``` XML + +``` + +``` CS +var dateTimePicker = new DateTimePicker(); +``` + +生成的DateTimePicker如下图所示: + +![DateTimePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/DateTimePicker_1.png) + + + +# 选择日期和时间 + +可以通过文本框输入日期和时间,或者点击文本框右边的按钮打开下拉的日历和时钟控件选择日期和时间。 + +![DateTimePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/DateTimePicker_2.png) + +也可以在XAML中或代码中这样设置日期。 + +``` XML + +``` + +``` CS +dateTimePicker.SelectedDateTime = DateTime.Now; +``` + +# 设置标题和占位符文本 + +你可以将 Header(标题)和 Placeholder(占位符)添加到DatePicker,以向用户指示其用途。要使用这两个属性,首先需要应用 **DateTimePickerExtend** 或 **DateTimePickerPlus** 样式。 + +``` XML + +``` + + + + +# 属性 + +| 属性 | 描述 | +| ---------------- | ------------------ | +| SelectedDateTime | 获取或设置当前选中的日期和时间 | +| DateTimeFormat | 获取或设置用于显示选定日期和时间的格式 | +| CalendarStyle | 获取或设置在呈现日历时使用的样式 | +| DisplayDateTime | 获取或设置要显示的日期 | +| IsDropDownOpen | 获取或设置一个值,该值指示是打开还是关闭下拉 Calendar | +| Text | 获取由 **DateTimePicker** 显示的文本,或设置选定日期和时间 | +| VerifyFunc | 获取或设置数据验证委托 | +| IsError | 获取或设置数据是否错误 | +| ErrorStr | 获取或设置错误提示 | +| TextType | 获取或设置文本类型 | +| ShowClearButton | 获取或设置是否显示清除按钮 | + +# 方法 + +| 方法 | 描述 | +| ---------------- | ------------------ | +| VerifyData() | 验证数据 | \ No newline at end of file diff --git a/doc/source/handycontrol/extend_controls/timePicker/index.md b/doc/source/handycontrol/extend_controls/timePicker/index.md index ca12ad62..5c65e872 100644 --- a/doc/source/handycontrol/extend_controls/timePicker/index.md +++ b/doc/source/handycontrol/extend_controls/timePicker/index.md @@ -1,5 +1,95 @@ --- -title: 建设中 +title: TimePicker --- -建设中 \ No newline at end of file +TimePicker 控件允许用户通过在文本框中键入时间或使用下拉的日历控件来选择时间。 + +``` CS +[TemplatePart(Name = ElementRoot, Type = typeof(Grid))] +[TemplatePart(Name = ElementTextBox, Type = typeof(WatermarkTextBox))] +[TemplatePart(Name = ElementButton, Type = typeof(Button))] +[TemplatePart(Name = ElementPopup, Type = typeof(Popup))] +public class TimePicker : Control, IDataInput +``` + +# 创建TimePicker + +``` XML + +``` + +``` CS +var timePicker = new TimePicker(); +``` + +生成的TimePicker如下图所示: + +![TimePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/TimePicker_1.png) + + + +# 选择时间 + +可以通过文本框输入时间,或者点击文本框右边的按钮打开下拉的时钟控件选择时间。 + +![TimePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/TimePicker_2.png) + +也可以在XAML钟或代码中这样设置日期。 + +``` XML + +``` + +``` CS +timePicker.SelectedTime = DateTime.Now; +``` + +# 更改时钟样式 + +通过更改Clock属性,TimePicker可以更改时钟的样式。 + +``` XML + + + + + +``` + +![TimePicker](https://raw.githubusercontent.com/HandyOrg/HandyOrgResource/master/HandyControl/Doc/extend_controls/TimePicker_3.png) + +# 设置标题和占位符文本 + +你可以将 Header(标题)和 Placeholder(占位符)添加到DatePicker,以向用户指示其用途。要使用这两个属性,首先需要应用 **TimePickerExtend** 或 **TimePickerPlus** 样式。 + +``` XML + +``` + + + + +# 属性 + +| 属性 | 描述 | +| ---------------- | ------------------ | +| SelectedTime | 获取或设置当前选中的时间 | +| Clock | 获取或设置下拉时钟 | +| TimeFormat | 获取或设置用于显示选定的时间的格式 | +| DisplayTime | 获取或设置要显示的时间 | +| IsDropDownOpen | 获取或设置一个值,该值指示是打开还是关闭下拉时钟 | +| Text | 获取由 **TimePicker** 显示的文本,或设置选定的时间 | +| VerifyFunc | 获取或设置数据验证委托 | +| IsError | 获取或设置数据是否错误 | +| ErrorStr | 获取或设置错误提示 | +| TextType | 获取或设置文本类型 | +| ShowClearButton | 获取或设置是否显示清除按钮 | + +# 方法 + +| 方法 | 描述 | +| ---------------- | ------------------ | +| VerifyData() | 验证数据 | + diff --git a/doc/source/handycontrol/tnx/index.md b/doc/source/handycontrol/tnx/index.md index 8f738933..565cb3ca 100644 --- a/doc/source/handycontrol/tnx/index.md +++ b/doc/source/handycontrol/tnx/index.md @@ -4,7 +4,7 @@ title: 鸣谢 # 感谢以下Coder提供代码贡献 -

ghost1372Dingping ZhangM0n7y5guanguanchuangyuyanchao891012noctwolfxianyun666afunc233

+

ghost1372Dingping ZhangM0n7y5guanguanchuangyuyanchao891012noctwolfxianyun666afunc233DinoChan

# 感谢以下组织机构提供开源许可 @@ -12,4 +12,4 @@ title: 鸣谢 # 感谢以下捐赠者 -

bigorange190014632791IUpdatablemapleweisunshang-hlyangkang326zmrbakAFei19911012

\ No newline at end of file +

bigorange190014632791IUpdatablemapleweisunshang-hlyangkang326zmrbakAFei19911012wayne2006towerDLHBluceBosenMrZhangYuanYC946586

\ No newline at end of file diff --git a/src/Core_30/HandyControlDemo_Core_30/HandyControlDemo_Core30.csproj b/src/Core_30/HandyControlDemo_Core_30/HandyControlDemo_Core30.csproj index b343a399..80a476b3 100644 --- a/src/Core_30/HandyControlDemo_Core_30/HandyControlDemo_Core30.csproj +++ b/src/Core_30/HandyControlDemo_Core_30/HandyControlDemo_Core30.csproj @@ -8,7 +8,7 @@ 2.4.0 ..\..\Shared\HandyControlDemo_Shared\Resources\Img\icon.ico Debug;Release - Copyright © HandyOrg 2018-2019 + Copyright © HandyOrg 2018-2020 2.4.0.0 2.4.0.0 8.0 @@ -454,6 +454,15 @@ Resources\Img\LeftMainContent\Effects_16x.png + + Resources\Img\LeftMainContent\Ellipsis_16x.png + + + Resources\Img\LeftMainContent\WPFFlowDocument_16x.png + + + Resources\Img\LeftMainContent\OutlinedRectangleTool_16x.png + @@ -465,6 +474,9 @@ Properties\Langs\Lang.fr.resx + + Properties\Langs\Lang.ko-KR.resx + Properties\Langs\Lang.resx PublicResXFileCodeGenerator diff --git a/src/Core_30/HandyControl_Core_30/HandyControl_Core_30.csproj b/src/Core_30/HandyControl_Core_30/HandyControl_Core_30.csproj index 97e75628..4f61f64f 100644 --- a/src/Core_30/HandyControl_Core_30/HandyControl_Core_30.csproj +++ b/src/Core_30/HandyControl_Core_30/HandyControl_Core_30.csproj @@ -8,7 +8,7 @@ 2.4.0.0 false false - Copyright © HandyOrg 2018-2019 + Copyright © HandyOrg 2018-2020 Contains some commonly used simple WPF controls Debug;Release 8.0 @@ -39,6 +39,9 @@ Properties\Langs\Lang.fr.resx + + Properties\Langs\Lang.ko-KR.resx + Properties\Langs\Lang.resx PublicResXFileCodeGenerator @@ -65,4 +68,54 @@ Resources\Effects\GrayScaleEffect.ps + + + Resources\Images\GlowWindow\bottom.png + + + Resources\Images\GlowWindow\bottomleft.png + + + Resources\Images\GlowWindow\bottomright.png + + + Resources\Images\GlowWindow\cornerbottomleft.png + + + Resources\Images\GlowWindow\cornerbottomright.png + + + Resources\Images\GlowWindow\cornertopleft.png + + + Resources\Images\GlowWindow\cornertopright.png + + + Resources\Images\GlowWindow\left.png + + + Resources\Images\GlowWindow\leftbottom.png + + + Resources\Images\GlowWindow\lefttop.png + + + Resources\Images\GlowWindow\right.png + + + Resources\Images\GlowWindow\rightbottom.png + + + Resources\Images\GlowWindow\righttop.png + + + Resources\Images\GlowWindow\top.png + + + Resources\Images\GlowWindow\topleft.png + + + Resources\Images\GlowWindow\topright.png + + \ No newline at end of file diff --git a/src/Core_30/HandyControl_Core_30/Themes/Styles/Window.xaml b/src/Core_30/HandyControl_Core_30/Themes/Styles/Window.xaml index f0c9acdb..15e08920 100644 --- a/src/Core_30/HandyControl_Core_30/Themes/Styles/Window.xaml +++ b/src/Core_30/HandyControl_Core_30/Themes/Styles/Window.xaml @@ -48,18 +48,15 @@ - - + + - - + + - - + + + + \ No newline at end of file diff --git a/src/Shared/HandyControl_Shared/Themes/Styles/Base/SeparatorBaseStyle.xaml b/src/Shared/HandyControl_Shared/Themes/Styles/Base/SeparatorBaseStyle.xaml new file mode 100644 index 00000000..2b9f91b0 --- /dev/null +++ b/src/Shared/HandyControl_Shared/Themes/Styles/Base/SeparatorBaseStyle.xaml @@ -0,0 +1,8 @@ + + + + + \ No newline at end of file diff --git a/src/Shared/HandyControl_Shared/Themes/Styles/Base/SliderBaseStyle.xaml b/src/Shared/HandyControl_Shared/Themes/Styles/Base/SliderBaseStyle.xaml index 9d71bc2a..d371ad3a 100644 --- a/src/Shared/HandyControl_Shared/Themes/Styles/Base/SliderBaseStyle.xaml +++ b/src/Shared/HandyControl_Shared/Themes/Styles/Base/SliderBaseStyle.xaml @@ -72,7 +72,7 @@ - @@ -103,7 +103,7 @@ - @@ -134,7 +134,7 @@ - @@ -165,7 +165,7 @@ - @@ -223,14 +223,14 @@ - + - + @@ -280,14 +280,14 @@ - + - + @@ -709,7 +709,7 @@ - @@ -740,7 +740,7 @@ - @@ -771,7 +771,7 @@ - @@ -802,7 +802,7 @@ - @@ -862,7 +862,7 @@ - + @@ -870,7 +870,7 @@ - + @@ -920,7 +920,7 @@ - + @@ -928,7 +928,7 @@ - + diff --git a/src/Shared/HandyControl_Shared/Themes/Styles/Base/StatusBarBaseStyle.xaml b/src/Shared/HandyControl_Shared/Themes/Styles/Base/StatusBarBaseStyle.xaml new file mode 100644 index 00000000..1da267ba --- /dev/null +++ b/src/Shared/HandyControl_Shared/Themes/Styles/Base/StatusBarBaseStyle.xaml @@ -0,0 +1,16 @@ + + + + + + + + + \ No newline at end of file diff --git a/src/Shared/HandyControl_Shared/Themes/Styles/Base/TextBoxBaseStyle.xaml b/src/Shared/HandyControl_Shared/Themes/Styles/Base/TextBoxBaseStyle.xaml index b2179bd3..97beb5d6 100644 --- a/src/Shared/HandyControl_Shared/Themes/Styles/Base/TextBoxBaseStyle.xaml +++ b/src/Shared/HandyControl_Shared/Themes/Styles/Base/TextBoxBaseStyle.xaml @@ -24,7 +24,7 @@ - + @@ -51,7 +51,7 @@ - + @@ -81,7 +81,7 @@ - + @@ -110,7 +110,7 @@ - + @@ -167,7 +167,7 @@ - +