diff --git a/HowItWorks.md b/HowItWorks.md new file mode 100644 index 0000000..e983eb1 --- /dev/null +++ b/HowItWorks.md @@ -0,0 +1,142 @@ +# How JOE syntax highlighting works +*from [c.jsf](http://joe-editor.hg.sourceforge.net/hgweb/joe-editor/joe-editor/file/tip/syntax/c.jsf.in)* + +A (deterministic) state machine which performs lexical analysis of C. +(This is the "assembly language" of syntax highlighting. A separate +program could be used to convert a regular expression NFA syntax into this +format). + +Each state begins with ': ' + is the color used for characters eaten by the state +(really a symbol for a user definable color). + +The first state defined is the initial state. + +Within a state, define transitions (jumps) to other states. Each +jump has the form: [