开发者

Using styledText in SWT application

I have a simple question really: SWT documentation says that if you're using styledText, you either implements its API or you implement LineStyleListener.

So, If I do use LineStyleListener, how can I still control the representation of specific characters in the editor widget? It seems t开发者_如何学编程hat implementing LineStyleListener only provides coloring of the whole line at a time.

Thanks


With the LineStyleListener you can still add styles for single characters by modifying the provided StyleRange array. It is called LineStyleListener only because you get the text by lines.

For explanations how to use this, see here or here.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜