notepad_complex.java

来自「java 编写的代码」· Java 代码 · 共 63 行

JAVA
63
字号
/**
 * 行编辑
 * 设置字体颜色
 */
package com.edu.sccp.snail.notepad.beans;

/**
 * @author 小豆包
 * @return 字体属性
 * @velue  字体属性   
 * @time 2008-1-7
 */
import java.awt.*;
import java.io.Serializable;

import javax.print.attribute.AttributeSet;
public class Notepad_Complex implements Serializable{
	private static final long serialVersionUID = 4892408810837789601L;
	private String Me_Str = null;  //字符集
	private Font Me_font = null;     //字体
	private Color Me_color  = null; //颜色
	private AttributeSet attributeSet = null;//惟一属性的集合
	/**
	 * @value 默认的构造函数
	 * @author 小豆包
	 */
	public Notepad_Complex(){		
	}
	/**
	 * 共有接口设置字体属性
	 * @param str
	 */
	public void setStr(String str){
		this.Me_Str = str;
	}
	public String getStr(){
		return Me_Str;
	}
	public void setFont(Font font){
		this.Me_font = font;
	}
	public Font getMe_font(){
		return Me_font;
	}
	public void set_Me_color(Color color){
		this.Me_color = color;
	}
	public Color getMe_color(){
		return Me_color;
	}
	/**
	 * 重写了Object 类的toString()
	 * 方法
	 */
	public String toString(){
		StringBuffer sb = new StringBuffer();
		sb.append(Me_Str);
		sb.append(Me_font);
		sb.append(Me_color);
		return sb.toString();
	}
}

⌨️ 快捷键说明

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