?? text.java
字號:
/*
* Text.java
*
* Created on 2007年4月3日, 上午12:30
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/
package dyno.swing.beans;
public class Text {
private int x;
private int y;
private int width;
private int height;
private String text;
private boolean visible;
public boolean isVisible() {
return visible;
}
public void setVisible(boolean visible) {
this.visible = visible;
}
public Text(String text) {
this.text = text;
}
public void setBounds(int x, int y, int width, int height) {
this.x = x;
this.y = y;
this.width = width;
this.height = height;
}
public int getX() {
return x;
}
public int getY() {
return y;
}
public int getWidth() {
return width;
}
public int getHeight() {
return height;
}
public String getText() {
return text;
}
public String getTranslation() {
if (text != null) {
String translation = Dictionary.getInstance().get(text.toLowerCase());
if (translation != null) {
return "<html><body><p>" + text + "<p> " + translation + "</body></html>";
} else {
return "<html><body><p>" + text + "<p> 查找不到該單詞</body></html>";
}
} else {
return null;
}
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -