# Updating Edit Modes

## From jEdit 4.0 to 4.1

In jEdit 4.1, the mode file grammar has been cleaned up somewhat. As a result, some edit modes written for jEdit 4.0 and earlier need to be updated:

- Defining `<WHITESPACE>` rules is no longer necessary and doing so will print warnings to the activity logs.

- The `<KEYWORDS>` tag no longer accepts an `IGNORE_CASE` attribute. Set the `IGNORE_CASE` attribute of the `<RULES>` tag instead.

- The `<END>` tag of the `<SPAN>` rule used to be optional, in which case any occurrence of the start string would cause the remainder of the buffer to be highlighted with the span. In jEdit 4.1, the `<END>` tag can no longer be omitted, however a `<SEQ>` tag with a `DELEGATE` attribute can be used to achieve the same effect as endless span.

- Defining `<SEQ TYPE="NULL">` rules for word separators is no longer necessary. Now, any non-alphanumeric character not appearing in a keyword definition or the ruleset's `NO_WORD_SEP` attribute is considered a word separator.

## From jEdit 4.2 to 4.3

1. All regular expressions in mode files were rewritten to use java.util.regex instead of gnu.regexp.

2. `HASH_CHAR` handling of `xxx_REGEXP` elements has been updated, as explained in .

3. The `EXCLUDE_MATCH` attribute got superseded by `MATCH_TYPE`. The attribute values translate from `TRUE` to `CONTEXT` and from `FALSE` to `RULE`, respectively. For more information see .

4. `NO_ESCAPE` is now deprecated and ignored by the parsing engine. `ESCAPE` is now a valid attribute for `SPAN` and `SPAN_REGEXP` rules.