小编Sim*_*mon的帖子

Java - 在setBorder中设置字体/颜色

有没有办法可以在setBorder方法中为Text1和Text2文本定义自己的字体和颜色方案.新的java并没有在SUN教程中找到它.

我的代码

//Create Positions Table
 JPanel SpreadPanel = new JPanel();
 SpreadPanel.setBorder(BorderFactory.createTitledBorder(" Text 1    Text 2"));
Run Code Online (Sandbox Code Playgroud)

关心西蒙

java fonts swing colors jpanel

8
推荐指数
2
解决办法
3万
查看次数

标签 统计

colors ×1

fonts ×1

java ×1

jpanel ×1

swing ×1