Can someone give me some hints on how a clean implementation (designwise) of a richtext editor could look like that allows for things like setting fonts, setting character colors and so on? And when and how are characters rendered? are characters rendered only once and the bitmap representation is cached?
Is there any article or book covering what software desi开发者_如何学编程gn would be appropriate for that?
background is that we're working on a text editing software for a language that cannot be displayed with unicode
any hint is appreciated!
thanks!
I'd have a look at the Java Swing source code (e.g. Java source code), the Qt source code and the Gtk source code. All those frameworks have rich text editors, and the implementations are there to be admired :)
Definitely check out the GoF Design Patterns book, which is a catalog of design patterns, but those are shown on example of a rich text editor. The design is language agnostic, but the examples are in C++. This will teach you some good design, you would have read a classic pattern book and you will get your richtext editor example.
精彩评论