javax.swing.text
public class PlainDocument extends AbstractDocument
Field Summary | |
---|---|
static String | lineLimitAttribute |
static String | tabSizeAttribute |
Constructor Summary | |
---|---|
PlainDocument() | |
PlainDocument(AbstractDocument.Content content) |
Method Summary | |
---|---|
protected AbstractDocument.AbstractElement | createDefaultRoot() |
Element | getDefaultRootElement() |
Element | getParagraphElement(int pos) |
void | insertString(int offs, String str, AttributeSet atts)
Inserts a string into the document. |
protected void | insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) |
protected void | removeUpdate(DefaultDocumentEvent event) |
filterNewLines
' is set to Boolean.TRUE
, then
all newlines in the inserted string are replaced by space characters,
otherwise the superclasses behaviour is executed.
Inserting content causes a write lock to be acquired during this method
call.
Parameters: offs the offset at which to insert the string str the string to be inserted atts the text attributes of the string to be inserted
Throws: BadLocationException