customtitledborder.java

来自「Typing fingers Typing programme」· Java 代码 · 共 18 行

JAVA
18
字号
import javax.swing.border.*;
import java.awt.*;

/**	This class extends TitledBorder to change the settings according
	to requirements.
*/

class CustomTitledBorder extends TitledBorder{
	CustomTitledBorder(String title){
		super(new EtchedBorder(),title,CENTER,DEFAULT_POSITION);
		setTitleColor(Utilities.getTextColor());
	}
	CustomTitledBorder(String title,Color c1,Color c2){
		super(new EtchedBorder(c1,c2),title,CENTER,DEFAULT_POSITION);
		setTitleColor(Utilities.getTextColor());
	}
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?