- When is the parser called (only after a document has been changed)?
Yes, it's called after any edit, after a short delay.
- Is there a possibility to call the parser programmatically?
Yes, but you have to either keep a reference to the Parser you want to re-run, or be able to identify it somehow. See the RSyntaxTextArea methods:
- Code: Select all
Parser getParser(int index);
void forceReparsing(int parserIndex);
boolean forceReparsing(Parser parser);
The last two methods result in an immediate reparsing (no delay). That last method won't do anything if the Parser specified isn't actually installed on the text area.
- How can the ErrorStrip be cleared?
I don't think so, short of removing all Parsers (textArea.clearParsers()) and re-adding them. Would having a method to remove all notices in the ErrorStrip be useful? Would the next edit to the document re-add all of them, or are you looking for some sort of "don't show anything for now" flag?