JAVA

프로그래밍 2009. 3. 23. 19:47


import org.kwis.msp.lcdui.Jlet;
import org.kwis.msp.lcdui.Display;
import org.kwis.msp.lcdui.Font;
import org.kwis.msp.lwc.Component;
import org.kwis.msp.lwc.ShellComponent;
import org.kwis.msp.lwc.LabelComponent;

public class LabelComponentEx1 extends Jlet{
 Display displayLCD;
 ShellComponent shell;

 public LabelComponentEx1(){
  displayLCD = Display.getDefaultDisplay();
  shell = new ShellComponent();
 }

protected void startApp(String[] arg0){
  displayLCD = Display.getDefaultDisplay();
  LabelComponent label1 = new LabelComponent();
  label1.setLabel("Title");
  label1.setLayout(Component.LAYOUT_VCENTER);
  LabelComponent label2 = new LabelComponent("Work");
 label2.setLayout(Component.LAYOUT_HCENTER|Component.LAYOUT_VCENTER);
  label2.setFont(Font.getFont(Font.FACE_MONOSPACE,
   Font.STYLE_ITALIC|Font.STYLE_BOLD,Font.SIZE_LARGE));
   
  LabelComponent label3 = new LabelComponent("Command");
  label3.setLayout(Component.LAYOUT_RIGHT);

  shell.setTitle(label1);
  shell.setWorkComponent(label2);
  shell.setCommand(label3,false);

  displayLCD.pushCard(shell.getCard());

 }
 protected void destroyApp(boolean arg0) {}
}


'프로그래밍' 카테고리의 다른 글

JAVA  (0) 2009.04.04
JAVA  (0) 2009.04.03
JAVA  (0) 2009.03.31
JAVA  (2) 2009.03.27
JAVA  (0) 2009.03.26
JAVA  (0) 2009.03.22
JAVA  (0) 2009.03.20
JAVA  (0) 2009.03.19
JAVA  (1) 2009.03.17
JAVA  (0) 2009.03.16

설정

트랙백

댓글