📄 fcheck.java
字号:
package core.ui.control;
import javax.microedition.lcdui.Graphics;
import javax.microedition.lcdui.Item;
public class FCheck { //extends Item{
public FCheck(String label){
//super(label);
}
protected void paint(Graphics g){
//清除屏幕
/*int color = g.getColor();
g.setColor(0xFFCCFF);
g.fillRect(0, 0, getWidth(), getHeight());
g.setColor(color);
//计算整个菜单的高度,宽度和(x,y)
int rectWidth = preferWidth;
int rectHeight = preferHeight * LABELS.length;
int x = (getWidth() - rectWidth) / 2;
int y = (getHeight() - rectHeight) / 2;
//画矩形
g.drawRect(x, y, rectWidth, rectHeight);
for(int i = 1; i < LABELS.length; i++){
g.drawLine(x, y + preferHeight * i, x + rectWidth, y + preferHeight * i);
}
//画菜单选项,并根据selected的值判断焦点
for(int j = 0; j < LABELS.length; j++){
if(selected == j){
g.setColor(0x6699cc);
g.fillRect(x + 1, y + j * preferHeight + 1, rectWidth - 1, preferHeight - 1);
g.setColor(color);
}
g.drawString(LABELS[j], x + 8, y + j * preferHeight + 4, Graphics.LEFT | Graphics.TOP);
}*/
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -