"Fossies" - the Fresh Open Source Software Archive

Member "highlight-3.57-x64/src/include/enums.h" (12 May 2020, 1941 Bytes) of package /windows/www/highlight-3.57-x64.zip:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. See also the last Fossies "Diffs" side-by-side code changes report for "enums.h": 3.53_vs_3.54.

    1 
    2 /*
    3 This file is part of Highlight.
    4 
    5 Highlight is free software: you can redistribute it and/or modify
    6 it under the terms of the GNU General Public License as published by
    7 the Free Software Foundation, either version 3 of the License, or
    8 (at your option) any later version.
    9 
   10 Highlight is distributed in the hope that it will be useful,
   11 but WITHOUT ANY WARRANTY; without even the implied warranty of
   12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
   13 GNU General Public License for more details.
   14 
   15 You should have received a copy of the GNU General Public License
   16 along with Highlight.  If not, see <http://www.gnu.org/licenses/>.
   17 */
   18 
   19 
   20 #ifndef ENUMS_H
   21 #define ENUMS_H
   22 
   23 namespace highlight
   24 {
   25 /** states which may occur during input file parsing */
   26 enum State {
   27     STANDARD=0,
   28     STRING,
   29     NUMBER,
   30     SL_COMMENT,
   31     ML_COMMENT,
   32     ESC_CHAR,
   33     DIRECTIVE,
   34     DIRECTIVE_STRING,
   35     LINENUMBER,
   36     SYMBOL,
   37     STRING_INTERPOLATION,
   38 
   39     // don't use constants > KEYWORD as array indices!
   40     KEYWORD,
   41     STRING_END,
   42     NUMBER_END,
   43     SL_COMMENT_END,
   44     ML_COMMENT_END,
   45     ESC_CHAR_END,
   46     DIRECTIVE_END,
   47     SYMBOL_END,
   48     STRING_INTERPOLATION_END,
   49     KEYWORD_END,
   50     IDENTIFIER_BEGIN,
   51     IDENTIFIER_END,
   52     EMBEDDED_CODE_BEGIN,
   53     EMBEDDED_CODE_END,
   54 
   55     _UNKNOWN=100,
   56     _REJECT,
   57     _EOL,
   58     _EOF,
   59     _WS,
   60     _TESTPOS
   61 } ;
   62 
   63 /** Parser return values*/
   64 enum ParseError {
   65     PARSE_OK,
   66     BAD_INPUT=1,
   67     BAD_OUTPUT=2,
   68     BAD_STYLE=4,
   69     BAD_BINARY=8
   70 };
   71 
   72 /** line wrapping modes*/
   73 enum WrapMode {
   74     WRAP_DISABLED,
   75     WRAP_SIMPLE,
   76     WRAP_DEFAULT
   77 };
   78 
   79 /** language definition loading results*/
   80 enum LoadResult {
   81     LOAD_OK,
   82     LOAD_FAILED,
   83     LOAD_FAILED_REGEX,
   84     LOAD_FAILED_LUA
   85 };
   86 
   87 /** output formats */
   88 enum OutputType {
   89     HTML,
   90     XHTML,
   91     TEX,
   92     LATEX,
   93     RTF,
   94     ESC_ANSI,
   95     ESC_XTERM256,
   96     HTML32_UNUSED,
   97     SVG,
   98     BBCODE,
   99     PANGO,
  100     ODTFLAT,
  101     ESC_TRUECOLOR
  102 };
  103 
  104 }
  105 
  106 #endif