(Sixty-six) c # Winform custom control - Icon font

premise

The bank has 7, 8 years, and always wanted to do a nice custom control points, so there is this series of articles.

GitHub:https://github.com/kwwwvagaa/NetWinformControl

Cloud code: https://gitee.com/kwwwvagaa/net_winform_custom_control.git

If you feel that writing was okay, please support the point of a star about it

Come and explore the exchange: Penguins 568 015 492 Penguins 568 015 492

Trouble blog below the point of a [Recommended], thank you

nuGet

Install-Package HZH_Controls

table of Contents

https://www.cnblogs.com/bfyx/p/11364884.html

Usefulness and effectiveness

Get a image

 HZH_Controls.FontImages.GetImage (enumeration style, size, foreground color, background color);

Get a icon

 HZH_Controls.FontImages.GetIcon (enumeration style, size, foreground color, background color);

UCBtnImg settings icon, you can use the property ImageFontIcons

Ready to work

Download the font file

http://www.fontawesome.com.cn/faicons/  

https://www.elegantthemes.com/blog/resources/elegant-icon-font

If you want to direct to the font file, I can go to the source to see inside

Start

Adding an enumeration, the font used to define a value corresponding to

View Code

Add a secondary class

View Code

That's it

Last words

If you like it, please  https://gitee.com/kwwwvagaa/net_winform_custom_control  point stars right

Guess you like

Origin www.cnblogs.com/bfyx/p/11511814.html