本文整理汇总了Java中org.jdesktop.swingx.JXTextArea类的典型用法代码示例。如果您正苦于以下问题:Java JXTextArea类的具体用法?Java JXTextArea怎么用?Java JXTextArea使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
JXTextArea类属于org.jdesktop.swingx包,在下文中一共展示了JXTextArea类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: createToolWindowContent
import org.jdesktop.swingx.JXTextArea; //导入依赖的package包/类
@Override
public void createToolWindowContent(Project project, ToolWindow toolWindow) {
final Document document = new PlainDocument();
final NetConsoleClient netConsole = new NetConsoleClient(document);
final JXTextArea textArea = new JXTextArea();
textArea.setDocument(document);
textArea.setEditable(false);
final DefaultActionGroup actionGroup = new DefaultActionGroup();
actionGroup.addAction(new AutoScrollAction(netConsole, textArea));
actionGroup.addAction(new ClearAction(netConsole));
actionGroup.addAction(new DisableAction(netConsole, textArea));
final SimpleToolWindowPanel netConsolePanel = new SimpleToolWindowPanel(false, false);
final ActionToolbar toolbar = ActionManager.getInstance().createActionToolbar(ActionPlaces.UNKNOWN,
actionGroup, false);
netConsolePanel.setToolbar(toolbar.getComponent());
netConsolePanel.setContent(new JBScrollPane(textArea));
final ContentFactory contentFactory = ContentFactory.SERVICE.getInstance();
final Content content = contentFactory.createContent(netConsolePanel, "", true);
toolWindow.getContentManager().addContent(content);
}
开发者ID:ThomasJClark,项目名称:netconsole-idea-plugin,代码行数:25,代码来源:NetConsoleToolWindowFactory.java
示例2: createTextArea
import org.jdesktop.swingx.JXTextArea; //导入依赖的package包/类
public static JXTextArea createTextArea(final String promptText) {
final JXTextArea ta = new JXTextArea(promptText);
ta.setColumns(17);
ta.setRows(6);
ta.setBorder(new CompoundBorder(WidgetUtils.BORDER_THIN, new EmptyBorder(2, 2, 2, 2)));
return ta;
}
开发者ID:datacleaner,项目名称:DataCleaner,代码行数:8,代码来源:WidgetFactory.java
示例3: setup
import org.jdesktop.swingx.JXTextArea; //导入依赖的package包/类
@Override
public void setup() {
textComponent = textArea = new JXTextArea();
}
开发者ID:RockManJoe64,项目名称:swingx,代码行数:5,代码来源:PromptTextAreaUITest.java
示例4: AutoScrollAction
import org.jdesktop.swingx.JXTextArea; //导入依赖的package包/类
public AutoScrollAction(NetConsoleClient netConsole, JXTextArea console) {
super("AutoScroll", "Automatically scroll on input", AllIcons.RunConfigurations.Scroll_down);
this.netConsole = netConsole;
this.consoleComponent = console;
}
开发者ID:ThomasJClark,项目名称:netconsole-idea-plugin,代码行数:7,代码来源:AutoScrollAction.java
注:本文中的org.jdesktop.swingx.JXTextArea类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论