Sublime Text 2 JSP Syntax Features

I have some problems with the built-in syntax highlighting for JSP pages in Sublime Text 2.

See the code after the white line on line 11/12: The HTML tag <strong>displays correctly here.

The code before this line is not colored correctly: the second closing JSP ( %>) tag is in red, but should be orange like the first, and the HTML tags inside are recognized as Java code, I think, although the areas (visible with CTRL+SHIFT+ALT+Phow text.html.jsp) do not change .

JSP Syntax Highlighting in Sublime Text 2 (Theme: "Monokai Soda", edited colors of JSP start / end tags

If I do the same with <?phpor <?start and ?>closing tags, the problem does not exist, all colors look right.

Has anyone had the same problem? I made sure the syntax is set to JavaServerPages (JSP).

, HTML.tmLanguage ( JSP HTML):

<dict>
    <key>embedded-code</key>
    <dict>
        <key>patterns</key>
        <array>
            <dict>
                <key>include</key>
                <string>#ruby</string>
            </dict>
            <dict>
                <key>include</key>
                <string>#php</string>
            </dict>
            <!--
            <dict>
                <key>include</key>
                <string>#smarty</string>
            </dict>
            -->
            <dict>
                <key>include</key>
                <string>#python</string>
            </dict>
        </array>
    </dict>

JSP . ... ?

+5
1

HTML.tmLanguage Java Server Pages (JSP).tmLanguage... ruby ​​ jsp HTML <script>, , , , text.html.jsp .


.tmTheme User User.tmTheme. :

    <dict>
        <key>name</key>
        <string>Embedded Code Punctuation</string>
        <key>scope</key>
        <string>punctuation.section.embedded</string>
        <key>settings</key>
        <dict>
            <key>fontStyle</key>
            <string>bold</string>
            <key>foreground</key>
            <string>#FD971F</string>
        </dict>
    </dict>
    <dict>
        <key>name</key>
        <string>Embedded Java Code Directive</string>
        <key>scope</key>
        <string>punctuation.section.directive</string>
        <key>settings</key>
        <dict>
            <key>foreground</key>
            <string>#FD971F</string>
        </dict>
    </dict>
    <dict>
        <key>name</key>
        <string>Embedded Java Code</string>
        <key>scope</key>
        <string>source.java.embedded.html</string>
        <key>settings</key>
        <dict>
            <key>foreground</key>
            <string>#F8F8F2</string>
        </dict>
    </dict>
    <dict>
        <key>name</key>
        <string>Embedded Java Code String</string>
        <key>scope</key>
        <string>string.quoted.double.java</string>
        <key>settings</key>
        <dict>
            <key>foreground</key>
            <string>#E6DB74</string>
        </dict>
    </dict>

HTML Java .

:

HTML.tmLanguage
Java (JSP).tmLanguage
JavaScript.tmLanguage

+2

All Articles