|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.nakedobjects.plugins.dnd.viewer.AwtText
public class AwtText
| Constructor Summary | |
|---|---|
protected |
AwtText(java.lang.String propertyName,
java.lang.String defaultFont)
|
| Method Summary | |
|---|---|
int |
charWidth(char c)
Returns the width, in pixels, of the specified character. |
int |
getAscent()
Returns the height, in pixels, of the distance from the baseline to top of the tallest character (including accents that are not common in english. |
java.awt.Font |
getAwtFont()
Returns the Font from the AWT used for drawing within the AWT. |
int |
getDescent()
Returns the height, in pixels, of the distance from bottom of the lowest descending character to the baseline. |
int |
getLineHeight()
Returns the sum of the text height and line spacing. |
int |
getLineSpacing()
Returns the number of blank vertical pixels to add between adjacent lines to give them additional spacing. |
int |
getMidPoint()
Returns the mid point, in pixels, between the baseline and the top of the characters. |
java.lang.String |
getName()
Return the name of this text style. |
int |
getTextHeight()
Returns the height, in pixels, for a normal line of text - where there is some space between two lines of text. |
int |
stringHeight(java.lang.String text,
int maxWidth)
Returns the height in pixels when the specified text is wrapped at the specified width |
int |
stringWidth(java.lang.String text)
Returns the width of the specified in pixels. |
int |
stringWidth(java.lang.String text,
int maxWidth)
|
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected AwtText(java.lang.String propertyName,
java.lang.String defaultFont)
| Method Detail |
|---|
public int charWidth(char c)
Text
charWidth in interface Textpublic int getAscent()
Text
getAscent in interface Textpublic java.awt.Font getAwtFont()
Fontpublic int getDescent()
Text
getDescent in interface Textpublic int getLineHeight()
Text
getLineHeight in interface TextText.getLineHeight(),
Text.getLineSpacing()public int getLineSpacing()
Text
getLineSpacing in interface Textpublic java.lang.String getName()
Text
getName in interface Textpublic int getMidPoint()
Text
getMidPoint in interface Textpublic int getTextHeight()
Text
getTextHeight in interface Text
public int stringHeight(java.lang.String text,
int maxWidth)
Text
stringHeight in interface Text
public int stringWidth(java.lang.String text,
int maxWidth)
stringWidth in interface Textpublic int stringWidth(java.lang.String text)
Text
stringWidth in interface Textpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||