Skip to content

STTextBox is a pure GDI-drawn WinForm control, which can support transparent colors and Emoji, etc., and can customize the display style of text through the text style monitor.

License

Notifications You must be signed in to change notification settings

DebugST/STTextBox

Repository files navigation

.Net35 LICENSE

简体中文

STTextBox

STTextBox is a pure GDI-drawn WinForm control, which can support transparent colors and Emoji, etc., and can customize the display style of text through the text style monitor.

STTextBox is a WinForm control drawn by me and my friend tpbeldie using GDI.

We adopt the MIT open source license, and the code is built with .Net3.5 + vs2010, so it is compatible with almost all VS versions. Two open source projects were also generated during the design process:

emoji-svg-render, STGraphemeSplitter

Because of our limited capabilities, many functions are not well implemented, so we modified the core functions into independent interfaces, So that other developers can implement it independently without having to find and modify the code in the entire control.

Emoji

You can use Emoji in STTextBox in the demos_bin we used twemoji. And for more info, you can see: emoji-svg-render

Alpha

In STTextBox all the color you can use alpha, Of course his efficiency is also very slow. We can't solve it well for now.

Style

You can also customize text styles, by implementing the ITextStyleMonitor interface, we have four realities built in. KeyWorldStyleMonitor CSharpStyleMonitor LinkStyleMonitor SelectionStyleMonitor.

Note: The rendering speed of STTextBox has nothing to do with the content, but is related to the number of characters that need to be drawn in the current UI. For some reasons, we use character-by-character drawing. In order for the colors to use the Alpha channel, we don't cache what's being drawn, since the background may change. And doing caching is also a hassle. So we have not considered the rendering speed of extreme cases for the time being.

About Author

About

STTextBox is a pure GDI-drawn WinForm control, which can support transparent colors and Emoji, etc., and can customize the display style of text through the text style monitor.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages