Class LabelComponent
package org.kwis.msp.lwc
java.lang.Object | +--org.kwis.msp.lwc.Component | +--org.kwis.msp.lwc.LabelComponentDirect Known Subclasses:
CheckboxComponent,ListItemComponent
extends Component:
문자열을 보여주는 컴포넌트 입니다.
사용자에게 보여줄때 문자열과 이미지를 포맷팅해서 출력해 줍니다.
LabelComponent는 setLayout(int)를 사용하여 정렬형태를 지정
할 수 있습니다.
LabelComponent에서 사용되는 정렬형태는 Component에서 제공하는
정렬 조합 규칙을 참조하고 있습니다.
LabelComponent생성시 기본 정렬 형태는 LAYOUT_LEFT입니다.
문자열이나 이미지는 null이 될 수도 있습니다.
필드 요약
섹션 제목: “필드 요약”protected int layout— LabelComoponent 의 정렬형태.protected Font m_ft— 문자 데이타에서 사용하는 폰트protected Image m_image— 이미지 데이타protected String m_str— 문자 데이타
생성자 요약
섹션 제목: “생성자 요약”- LabelComponent () 레이블 컴포넌트를 생성합니다.
- LabelComponent ( String str) 주어진 문자열로 레이블 컴포넌트를 생성합니다.
- LabelComponent ( String str, Image img) 주어진 문자열과 이미지 데이타로 레이블 컴포넌트를 생성합니다.
- LabelComponent ( String str, String imgString) 주어진 문자열과 지정한 자원에서 읽어들이는 이미지 데이타로 레이블 컴포넌트를 생성합니다.
메서드 요약
섹션 제목: “메서드 요약”protected void calcPreferredSize (int cw)— 컴포넌트의 적절한 크기를 계산합니다.Font getFont ()— 폰트를 얻어옵니다.Image getImage ()— 내부 이미지를 가져옵니다.String getLabel ()— 내부 문자열을 가져옵니다.void paintContent ( Graphics g)— 내부를 칠합니다.void setFont ( Font ft)— 폰트를 지정합니다.void setImage ( Image img)— 내부 이미지을 주어진 이미지로 지정합니다.void setLabel ( String str)— 내부 문자열을 주어진 문자열값으로 지정합니다.void setLayout (int layout)— 레이블의 정렬 형태를 지정합니다.
필드 상세
섹션 제목: “필드 상세”layout
섹션 제목: “layout”protected int layoutLabelComoponent의 정렬형태. 기본 정렬형태는Component.LAYOUT_LEFT입니다.
m_ft
섹션 제목: “m_ft”protected Font m_ft- 문자 데이타에서 사용하는 폰트
m_str
섹션 제목: “m_str”protected String m_str- 문자 데이타
m_image
섹션 제목: “m_image”protected Image m_image- 이미지 데이타
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent()- 레이블 컴포넌트를 생성합니다.
문자열과 이미지는 모두
null로 지정되며, 기본 정렬형태는LAYOUT_LEFT입니다.
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent(String str)Parameters:
str- 레이블 컴포넌트가 보여줄 문자열 혹은null
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent(String str, Image img)Parameters:
img- 이미지 혹은null
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent(String str, String imgString)Parameters:
imgString- 이미지 자원의 경로명을 나타내는 문자열 혹은null
setLabel
섹션 제목: “setLabel”public void setLabel(String str)Parameters:
str- 변경할 문자열 혹은null
setImage
섹션 제목: “setImage”public void setImage(Image img)Parameters:
img- 변경할 이미지 혹은null
getLabel
섹션 제목: “getLabel”public String getLabel()Returns:
- 내부 출력 문자열
getImage
섹션 제목: “getImage”public Image getImage()Returns:
- 내부 출력 이미지
setFont
섹션 제목: “setFont”public void setFont(Font ft)Parameters:
ft- 사용자 폰트
getFont
섹션 제목: “getFont”public Font getFont()Returns:
- 설정된 폰트
calcPreferredSize
섹션 제목: “calcPreferredSize”protected void calcPreferredSize(int cw)- Description copied from class:
Component
Overrides:
calcPreferredSizein classComponent
paintContent
섹션 제목: “paintContent”public void paintContent(Graphics g)- Description copied from class:
Component
Overrides:
paintContentin classComponent- Following copied from class:
org.kwis.msp.lwc.Component
Parameters:
g- 칠할 Graphics.
See Also:
Graphics
setLayout
섹션 제목: “setLayout”public void setLayout(int layout)Parameters:
type- 정렬 형태
Throws:
IllegalArgumentException- 컴포넌트에 정의된 정렬 형태 외의 값을 지정한 경우 발생
See Also:
Component.LAYOUT_LEFT,Component.LAYOUT_RIGHT,Component.LAYOUT_HCENTER,Component.LAYOUT_TOP,Component#LYAOUT_VCENTER,Component.LAYOUT_BOTTOM## 생성자 상세
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent()- 레이블 컴포넌트를 생성합니다.
문자열과 이미지는 모두
null로 지정되며, 기본 정렬형태는LAYOUT_LEFT입니다.
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent(String str)Parameters:
str- 레이블 컴포넌트가 보여줄 문자열 혹은null
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent(String str, Image img)Parameters:
img- 이미지 혹은null
LabelComponent
섹션 제목: “LabelComponent”public LabelComponent(String str, String imgString)Parameters:
imgString- 이미지 자원의 경로명을 나타내는 문자열 혹은null
setLabel
섹션 제목: “setLabel”public void setLabel(String str)Parameters:
str- 변경할 문자열 혹은null
setImage
섹션 제목: “setImage”public void setImage(Image img)Parameters:
img- 변경할 이미지 혹은null
getLabel
섹션 제목: “getLabel”public String getLabel()Returns:
- 내부 출력 문자열
getImage
섹션 제목: “getImage”public Image getImage()Returns:
- 내부 출력 이미지
setFont
섹션 제목: “setFont”public void setFont(Font ft)Parameters:
ft- 사용자 폰트
getFont
섹션 제목: “getFont”public Font getFont()Returns:
- 설정된 폰트
calcPreferredSize
섹션 제목: “calcPreferredSize”protected void calcPreferredSize(int cw)- Description copied from class:
Component
Overrides:
calcPreferredSizein classComponent
paintContent
섹션 제목: “paintContent”public void paintContent(Graphics g)- Description copied from class:
Component
Overrides:
paintContentin classComponent- Following copied from class:
org.kwis.msp.lwc.Component
Parameters:
g- 칠할 Graphics.
See Also:
Graphics
setLayout
섹션 제목: “setLayout”public void setLayout(int layout)Parameters:
type- 정렬 형태
Throws:
IllegalArgumentException- 컴포넌트에 정의된 정렬 형태 외의 값을 지정한 경우 발생
See Also:
Component.LAYOUT_LEFT,Component.LAYOUT_RIGHT,Component.LAYOUT_HCENTER,Component.LAYOUT_TOP,Component#LYAOUT_VCENTER,Component.LAYOUT_BOTTOM## 메서드 상세
setLabel
섹션 제목: “setLabel”public void setLabel(String str)Parameters:
str- 변경할 문자열 혹은null
setImage
섹션 제목: “setImage”public void setImage(Image img)Parameters:
img- 변경할 이미지 혹은null
getLabel
섹션 제목: “getLabel”public String getLabel()Returns:
- 내부 출력 문자열
getImage
섹션 제목: “getImage”public Image getImage()Returns:
- 내부 출력 이미지
setFont
섹션 제목: “setFont”public void setFont(Font ft)Parameters:
ft- 사용자 폰트
getFont
섹션 제목: “getFont”public Font getFont()Returns:
- 설정된 폰트
calcPreferredSize
섹션 제목: “calcPreferredSize”protected void calcPreferredSize(int cw)- Description copied from class:
Component
Overrides:
calcPreferredSizein classComponent
paintContent
섹션 제목: “paintContent”public void paintContent(Graphics g)- Description copied from class:
Component
Overrides:
paintContentin classComponent- Following copied from class:
org.kwis.msp.lwc.Component
Parameters:
g- 칠할 Graphics.
See Also:
Graphics
setLayout
섹션 제목: “setLayout”public void setLayout(int layout)Parameters:
type- 정렬 형태
Throws:
IllegalArgumentException- 컴포넌트에 정의된 정렬 형태 외의 값을 지정한 경우 발생
See Also:
Component.LAYOUT_LEFT,Component.LAYOUT_RIGHT,Component.LAYOUT_HCENTER,Component.LAYOUT_TOP,Component#LYAOUT_VCENTER,Component.LAYOUT_BOTTOM
AromaSoft Corp. Proprietary and Confidential
(C)opyright 2003 AromaSoft Corp. All right reserved. Contact : contact@aromasoft.com