[英]JTextArea - autoformat like netbeans ide
i'm working in java, i'm developing a programming language and i'm building the ide for it. 我正在用Java工作,正在开发一种编程语言,并且正在为其构建思想。 the problem is that i'd like to have a textArea like netbeans ide's one, with formatted and colored text. 问题是我想拥有一个像netbeans ide一样的textArea,带有格式化和彩色的文本。 for example i'd like to have a textarea where reserved words are blue, numbers are purple and function names are bold, how is it possible without losing efficiency while typing? 例如,我想拥有一个文本区域,其中保留字为蓝色,数字为紫色,函数名称为粗体,怎么可能在键入时不损失效率?
Certain libraries allow you to create special text areas for this exact purpose. 某些库允许您为此目的创建特殊的文本区域。 The most popular textArea
is the RSyntaxTextArea 最受欢迎的textArea
是RSyntaxTextArea
Two other related questions which may help: 另外两个相关的问题可能会有所帮助:
What code highlighting libs are there for Java? Java有哪些突出显示库的代码?
Where can I find a syntax highlighting library for Java? 在哪里可以找到Java的语法突出显示库?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.