Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8613533
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T04:54:04+00:00 2026-06-12T04:54:04+00:00

I have some issues with the built in syntax highlighting for JSP pages in

  • 0

I have some issues 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> is displayed correctly here.

The code before this line is not correctly colored: The second JSP closing tag (%>) is in red, but should be in orange like the first one and the HTML tags inside are recognized as Java code I think, although the scopes (visible with CTRL+SHIFT+ALT+P as 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 <?php or <? starting and ?> closing tags the problem does not exist, all colors seem to be right then.

Did anyone have the same problem? I made sure that the syntax is set to JavaServerPages (JSP).

I think the problem relates to these lines in HTML.tmLanguage file (JSP scope is inside HTML scope):

<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>

There is no include for JSP. But I’m only guessing… Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T04:54:06+00:00Added an answer on June 12, 2026 at 4:54 am

    I managed to edit the HTML.tmLanguage and Java Server Pages (JSP).tmLanguage files now… some matches for ruby overwrote the jsp scopes inside HTML <script> tags and I removed the match for curly brackets, and additionally I added some text.html.jsp includes to a few scope definitions.


    I copied my .tmTheme file and put it into the User package folder as User.tmTheme. I then added these lines to this file at the bottom:

        <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>
    

    I then edited these two files in the folders HTML and Java and commented out some ruby includes and stuff.

    See the files here:

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

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have built an app using jQuery mobile. Apart of some compatibility issues across
I have an application built with Struts 2. It has some issues with Cross-site
I'm having some issues with a Wordpress website I recently built. I have implemented
I have a weird issue. I have some icons that are being built based
I have some issues in setting the classpath for the a project for which
I have some issues with a PHP file that is not working properly. The
I have some issues with my EJB 3 timer where it is launched more
I'm have some issues adding a class to 2 navigation links on a theme.
I seems to have some issues in order to compile gproc from uwiger. I
Im starting with CoCos2d development and I think I have some issues with nodespace,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.