|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.inet.html.views.ContentPainter
com.inet.html.views.RotationPainter
public class RotationPainter
This class is similar to the JRE GlyphView.GlyphPainter
. But since HTML does not support tabs and has
no predefined Break length, these parts of the functions are removed.
This painter has the ability to rotate the glyphs.
NOTE: This will not work for arabic text!
Field Summary | |
---|---|
static int |
GLYPH_DOWN
|
static int |
GLYPH_LEFT
|
static int |
GLYPH_RIGHT
|
static int |
GLYPH_UP
|
Constructor Summary | |
---|---|
RotationPainter(int glyphOrientation,
ContentView view)
Creates the painter |
Method Summary | |
---|---|
ContentPainter |
copy(ContentView target)
Returns a copy of this painter |
int |
getGlyphOrientation()
Returns the glyph orientation of this painter |
void |
paint(java.awt.Graphics g,
java.awt.Shape a,
int start,
int length,
int baseline)
Paints the glyphs representing the given range. |
void |
setView(ContentView view)
Sets the view this painter is bound to |
Methods inherited from class com.inet.html.views.ContentPainter |
---|
getAscent, getCharOffsets, getDescent, getHeight, getSpan, isCharOffsetsSet, isReversed, modelToView, reset, setCharOffsets, setReversed, sync, viewToModel |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int GLYPH_RIGHT
public static final int GLYPH_LEFT
public static final int GLYPH_DOWN
public static final int GLYPH_UP
Constructor Detail |
---|
public RotationPainter(int glyphOrientation, ContentView view)
glyphOrientation
- the rotation constantview
- the view, whose content will be painted by this painterMethod Detail |
---|
public void setView(ContentView view)
setView
in class ContentPainter
view
- the view, whose content will be painted by this painterpublic void paint(java.awt.Graphics g, java.awt.Shape a, int start, int length, int baseline)
paint
in class ContentPainter
g
- the graphics to paint toa
- the allocation to paint tostart
- the start index within the text of the viewlength
- the end index within the text of the viewbaseline
- the offset from the top of the shape to the baseline of the current linepublic int getGlyphOrientation()
public ContentPainter copy(ContentView target)
copy
in class ContentPainter
target
- the view to bind to
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |