Class HtmlFoldParser
java.lang.Object
org.fife.ui.rsyntaxtextarea.folding.HtmlFoldParser
- All Implemented Interfaces:
FoldParser
Fold parser for HTML 5, PHP and JSP. For HTML, we currently don't fold
everything possible, just the "big" stuff. For PHP, we only fold
the "big" HTML stuff and PHP regions, not code blocks in the actual PHP.
For JSP we only fold the "big" HTML stuff and JSP blocks, not anything in
the actual Java code.
- Version:
- 1.0
- Author:
- Robert Futrell
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intConstant denoting we're folding HTML.static final intConstant denoting we're folding JSP.static final intConstant denoting we're folding PHP. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetFolds(RSyntaxTextArea textArea) Returns a list of all folds in the text area.
-
Field Details
-
LANGUAGE_HTML
public static final int LANGUAGE_HTMLConstant denoting we're folding HTML.- See Also:
-
LANGUAGE_PHP
public static final int LANGUAGE_PHPConstant denoting we're folding PHP.- See Also:
-
LANGUAGE_JSP
public static final int LANGUAGE_JSPConstant denoting we're folding JSP.- See Also:
-
-
Constructor Details
-
HtmlFoldParser
public HtmlFoldParser(int language) Constructor.- Parameters:
language- The language to fold, such asLANGUAGE_PHP.
-
-
Method Details
-
getFolds
Description copied from interface:FoldParserReturns a list of all folds in the text area.- Specified by:
getFoldsin interfaceFoldParser- Parameters:
textArea- The text area whose contents should be analyzed.- Returns:
- The list of folds. If this method returns
null, it is treated as if no folds were found.
-