|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
java.lang.Objectjavax.swing.text.LayeredHighlighter.LayerPainter
javax.swing.text.DefaultHighlighter.DefaultHighlightPainter
public static class DefaultHighlighter.DefaultHighlightPainter
只高亮显示用纯色填充高亮显示区域的 painter。
| 构造方法摘要 | |
|---|---|
DefaultHighlighter.DefaultHighlightPainter(Color c)
构造新的高亮显示 painter。 |
|
| 方法摘要 | |
|---|---|
Color |
getColor()
返回高亮显示的颜色。 |
void |
paint(Graphics g,
int offs0,
int offs1,
Shape bounds,
JTextComponent c)
绘制高亮显示区域。 |
Shape |
paintLayer(Graphics g,
int offs0,
int offs1,
Shape bounds,
JTextComponent c,
View view)
绘制高亮显示的某一部分。 |
| 从类 java.lang.Object 继承的方法 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| 构造方法详细信息 |
|---|
public DefaultHighlighter.DefaultHighlightPainter(Color c)
c 为 null,则会对 JTextComponent 查询其选定颜色。
c - 高亮显示所用的颜色| 方法详细信息 |
|---|
public Color getColor()
public void paint(Graphics g,
int offs0,
int offs1,
Shape bounds,
JTextComponent c)
g - 图形上下文offs0 - 起始模型偏移量,该值 >= 0offs1 - 结束模型偏移量,该值 >= offs1bounds - 高亮显示所用的边界框c - 编辑器
public Shape paintLayer(Graphics g,
int offs0,
int offs1,
Shape bounds,
JTextComponent c,
View view)
LayeredHighlighter.LayerPainter 中的 paintLayerg - 图形上下文offs0 - 起始模型偏移量,该值 >= 0offs1 - 结束模型偏移量,该值 >= offs1bounds - 视图的边界框,它不一定是要绘制的区域。c - 编辑器view - 要绘制的视图
|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
版权所有 2007 Sun Microsystems, Inc. 保留所有权利。 请遵守许可证条款。另请参阅文档重新分发政策。