|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.text.DocumentFilter
groovy.ui.text.StructuredSyntaxDocumentFilter
public class StructuredSyntaxDocumentFilter
Nested Class Summary | |
---|---|
class |
StructuredSyntaxDocumentFilter.LexerNode
|
protected class |
StructuredSyntaxDocumentFilter.MultiLineRun
|
Nested classes/interfaces inherited from class javax.swing.text.DocumentFilter |
---|
DocumentFilter.FilterBypass |
Field Summary | |
---|---|
protected StructuredSyntaxDocumentFilter.LexerNode |
lexer
The root of the lexical parsing tree. |
protected SortedSet |
mlTextRunSet
The position tree of multi-line comments. |
protected DefaultStyledDocument |
styledDocument
|
static String |
TAB_REPLACEMENT
|
Constructor Summary | |
---|---|
StructuredSyntaxDocumentFilter(DefaultStyledDocument document)
Creates a new instance of StructuredSyntaxDocumentFilter |
Method Summary | |
---|---|
StructuredSyntaxDocumentFilter.LexerNode |
createLexerNode()
Create a new LexerNode for adding to root. |
StructuredSyntaxDocumentFilter.LexerNode |
getRootNode()
Get the root node for lexing the document. |
void |
insertString(DocumentFilter.FilterBypass fb,
int offset,
String text,
AttributeSet attrs)
Insert a string into the document, and then parse it if the parser has been set. |
protected void |
parseDocument(int offset,
int length)
Parse the Document to update the character styles given an initial start position. |
void |
remove(DocumentFilter.FilterBypass fb,
int offset,
int length)
Remove a string from the document, and then parse it if the parser has been set. |
void |
replace(DocumentFilter.FilterBypass fb,
int offset,
int length,
String text,
AttributeSet attrs)
Replace a string in the document, and then parse it if the parser has been set. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String TAB_REPLACEMENT
protected StructuredSyntaxDocumentFilter.LexerNode lexer
protected DefaultStyledDocument styledDocument
protected SortedSet mlTextRunSet
Constructor Detail |
---|
public StructuredSyntaxDocumentFilter(DefaultStyledDocument document)
document
- the styled document to parseMethod Detail |
---|
public StructuredSyntaxDocumentFilter.LexerNode createLexerNode()
public StructuredSyntaxDocumentFilter.LexerNode getRootNode()
public void insertString(DocumentFilter.FilterBypass fb, int offset, String text, AttributeSet attrs) throws BadLocationException
insertString
in class DocumentFilter
fb
- offset
- text
- attrs
-
BadLocationException
protected void parseDocument(int offset, int length) throws BadLocationException
offset
- length
-
BadLocationException
public void remove(DocumentFilter.FilterBypass fb, int offset, int length) throws BadLocationException
remove
in class DocumentFilter
fb
- offset
- length
-
BadLocationException
public void replace(DocumentFilter.FilterBypass fb, int offset, int length, String text, AttributeSet attrs) throws BadLocationException
replace
in class DocumentFilter
fb
- offset
- length
- text
- attrs
-
BadLocationException
|
Copyright © 2003-2009 The Codehaus. All rights reserved. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |