D
D
Dmitry2018-02-26 19:38:58
Arduino
Dmitry, 2018-02-26 19:38:58

Wrong comment highlighting in Sublime Text Arduino?

I have a question.
When using Sublime Text ( with the STINO plugin ) for Arduino programming, my comments are highlighted incorrectly.
5a9435ba79e9e941838734.png
More precisely, everything that the plugin adds is highlighted even when commented out.
Looked at the syntax file. Here is the content
5a9436a60bbfa654119328.png

spoiler
%YAML 1.2
---
# http://www.sublimetext.com/docs/3/syntax.html
name: Arduino
file_extensions: [ino, pde]
scope: source.arduino

contexts:
  main:
    - match: ''
      push: Packages/C++/C++.sublime-syntax
      with_prototype:
        - match: \b(HIGH|LOW|INPUT|OUTPUT|INPUT_PULLUP|LED_BUILTIN)\b
          scope: constant.language.arduino
        - match: \b(boolean|word|String|string|array)\b
          scope: storage.type.arduino
        - match: PROGRAM
          scope: storage.modifier.arduino
        - match: \b(Serial|Stream|Keyboard|Mouse)\b
          scope: entity.name.class.arduino
        - match: \b(pinMode|digitalWrite|digitalRead|analogReference|analogRead|analogWrite|analogReadResolution|analogWriteResolution|tone|noTone|shiftOut|shiftIn|pulseIn|millis|micros|delay|delayMicroseconds|min|max|constrain|map|pow|sqrt|sin|cos|tan|isAlphaNumeric|isAlpha|isAscii|isWhitespace|isControl|isDigit|isGraph|isLowerCase|isPrintable|isPunct|isSpace|isUpperCase|isHexadecimalDigit|randomSeed|random|lowByte|highByte|bitRead|bitWrite|bitSet|bitClear|bit|attachInterrupt|detachInterrupt|interrupts|noInterrupts)\b
          scope: entity.name.function.arduino

I understand that I need to add something to the beginning. But what? Or do I need to edit the plugin itself by adding something?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question