|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcdox.edit.Element
cdox.edit.TextElement
This class represents an element that is contained within a document. The GenericElement can contain a java.awt.Component as data.
| Field Summary | |
static java.awt.datatransfer.DataFlavor |
TEXTELEMENT_FLAVOR
The DataFlavor for cut/pasting text elements. |
| Fields inherited from class cdox.edit.Element |
cachedImage, cover, dashed, diagonalResizeRect, elementSize, flipHorizontal, flipVertical, horizontalResizeRect, position, quality, ratioX, ratioY, rotateBy, verticalResizeRect |
| Constructor Summary | |
TextElement(java.awt.Point pos,
TextPane c)
Creates new element at the specified position. |
|
| Method Summary | |
protected java.awt.image.BufferedImage |
getBufferedImage()
This method must return an untransformed image of the element. |
TextPane |
getTextPane()
Returns the TextPane for this text element. |
java.lang.Object |
getTransferData(java.awt.datatransfer.DataFlavor f)
|
java.awt.datatransfer.DataFlavor[] |
getTransferDataFlavors()
|
boolean |
isDataFlavorSupported(java.awt.datatransfer.DataFlavor f)
|
void |
resetFontSizes()
Resizes all the text-Elements to its original fontsize. |
protected void |
saveMyself(org.w3c.dom.Element root,
java.util.zip.ZipOutputStream out)
This method saves its data in the given parameters. |
void |
setSize(java.awt.Dimension dim)
This Method overrides the Element setSize method to enlarge the text.Elements in this textPane, for better rendering. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static java.awt.datatransfer.DataFlavor TEXTELEMENT_FLAVOR
| Constructor Detail |
public TextElement(java.awt.Point pos,
TextPane c)
pos - the position.c - the component aka the content.TextPane| Method Detail |
public void setSize(java.awt.Dimension dim)
setSize in class Elementdim - the new Dimension.TextPane.resizeRelativeAttributeSet(int),
Element.setSize(java.awt.Dimension)public void resetFontSizes()
public TextPane getTextPane()
public java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
public boolean isDataFlavorSupported(java.awt.datatransfer.DataFlavor f)
public java.lang.Object getTransferData(java.awt.datatransfer.DataFlavor f)
throws java.awt.datatransfer.UnsupportedFlavorException
java.awt.datatransfer.UnsupportedFlavorExceptionprotected java.awt.image.BufferedImage getBufferedImage()
Element
getBufferedImage in class Element
protected void saveMyself(org.w3c.dom.Element root,
java.util.zip.ZipOutputStream out)
throws java.io.IOException
Element
saveMyself in class Elementroot - the root element to append the child to.out - the ZipOutputStream to write any files to.
java.io.IOException - if writing into the ZipStream failed.Element.appendChild(org.w3c.dom.Element, java.lang.String)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||