shape.java

来自「采用基础Java语言实现的一个类似于Windows中的画图程序。」· Java 代码 · 共 49 行

JAVA
49
字号
/*
 * shape.java
 *
 * Created on 2007年6月16日, 下午1:26
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package huaban;

import java.awt.Color;
import java.io.Serializable;
public class shape implements Serializable{
    point dot;
    Color  color;
    int size;
    int state;
    public shape() {
        dot = new point(0,0);
        size = 0;
        state = 0;
        color = Color.BLACK; 
    }
    public void setcolor(Color color){
       this.color = color;
    }
    public void setsize(int i){
        size = i;
    }
    public void setstate(int i){
        state = i;
    }
    
    
    public point getdot(){
        return dot;
    }
    public Color getcolor(){
        return color;
    }
    public int getsize(){
        return size;
    }
    public int getstate(){
        return state;
    }
}

⌨️ 快捷键说明

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