public static class DefaultHighlighter.DefaultHighlightPainter extends LayeredHighlighter.LayerPainter
| Constructor and Description |
|---|
DefaultHighlightPainter(Color c)
构建一个新的亮点画家。
|
| Modifier and Type | Method and Description |
|---|---|
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)
描绘突出的一部分。
|
public DefaultHighlightPainter(Color c)
c是空的,这jtextcomponent将查询其选择颜色。
c为亮点的颜色
public Color getColor()
public void paint(Graphics g, int offs0, int offs1, Shape bounds, JTextComponent c)
g -图形上下文
offs0 -初始模型偏移> = 0
offs1 -结局模型偏移> = offs1
bounds的包围盒的亮点
c -编辑
public Shape paintLayer(Graphics g, int offs0, int offs1, Shape bounds, JTextComponent c, View view)
paintLayer 方法重写,继承类
LayeredHighlighter.LayerPainter
g -图形上下文
offs0 -初始模型偏移> = 0
offs1 -结局模型偏移> = offs1
bounds -视图的包围盒,这是不一定的区域画。
c -编辑
view风景画
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.