qscilexercoffeescript.sip 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. // This is the SIP interface definition for QsciLexerCoffeeScript.
  2. //
  3. // Copyright (c) 2017 Riverbank Computing Limited <info@riverbankcomputing.com>
  4. //
  5. // This file is part of QScintilla.
  6. //
  7. // This file may be used under the terms of the GNU General Public License
  8. // version 3.0 as published by the Free Software Foundation and appearing in
  9. // the file LICENSE included in the packaging of this file. Please review the
  10. // following information to ensure the GNU General Public License version 3.0
  11. // requirements will be met: http://www.gnu.org/copyleft/gpl.html.
  12. //
  13. // If you do not wish to use this file under the terms of the GPL version 3.0
  14. // then you may purchase a commercial license. For more information contact
  15. // info@riverbankcomputing.com.
  16. //
  17. // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
  18. // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  19. class QsciLexerCoffeeScript : QsciLexer
  20. {
  21. %TypeHeaderCode
  22. #include <Qsci/qscilexercoffeescript.h>
  23. %End
  24. public:
  25. enum {
  26. Default,
  27. Comment,
  28. CommentLine,
  29. CommentDoc,
  30. Number,
  31. Keyword,
  32. DoubleQuotedString,
  33. SingleQuotedString,
  34. UUID,
  35. PreProcessor,
  36. Operator,
  37. Identifier,
  38. UnclosedString,
  39. VerbatimString,
  40. Regex,
  41. CommentLineDoc,
  42. KeywordSet2,
  43. CommentDocKeyword,
  44. CommentDocKeywordError,
  45. GlobalClass,
  46. CommentBlock,
  47. BlockRegex,
  48. BlockRegexComment,
  49. InstanceProperty,
  50. };
  51. QsciLexerCoffeeScript(QObject *parent /TransferThis/ = 0);
  52. virtual ~QsciLexerCoffeeScript();
  53. const char *language() const;
  54. const char *lexer() const;
  55. QColor defaultColor(int style) const;
  56. bool defaultEolFill(int style) const;
  57. QFont defaultFont(int style) const;
  58. QColor defaultPaper(int style) const;
  59. const char *keywords(int set) const;
  60. QString description(int style) const;
  61. const char *wordCharacters() const;
  62. QStringList autoCompletionWordSeparators() const;
  63. const char *blockEnd(int *style = 0) const /Encoding="None"/;
  64. const char *blockStart(int *style = 0) const /Encoding="None"/;
  65. const char *blockStartKeyword(int *style = 0) const /Encoding="None"/;
  66. int braceStyle() const;
  67. void refreshProperties();
  68. bool dollarsAllowed() const;
  69. void setDollarsAllowed(bool allowed);
  70. bool foldComments() const;
  71. void setFoldComments(bool fold);
  72. bool foldCompact() const;
  73. void setFoldCompact(bool fold);
  74. bool stylePreprocessor() const;
  75. void setStylePreprocessor(bool style);
  76. protected:
  77. bool readProperties(QSettings &qs, const QString &prefix);
  78. bool writeProperties(QSettings &qs, const QString &prefix) const;
  79. private:
  80. QsciLexerCoffeeScript(const QsciLexerCoffeeScript &);
  81. };