"Software Tricks" Sublime text defines different highlighting for different grammars

Source: Internet
Author: User
Tags sublime text

Sublime text default syntax highlighting is very beautiful, but for the individual language is still a bit uncomfortable.

The default highlighting rule, called Monokai, can be seen from the Preferences->settings-default:


But the highlight of this rule is a bit monotonous for the JSON syntax.

The configuration is in JSON format.

Here's how it's changed.

First, download your favorite theme control + Shift + p to open the console. Enter IP, select the first

Open and then enter the subject name to download (same as installing other plugins), I choose Cobalt2. At the end of the article comes a preview of some good-looking themes.

Restart Sublime Text after loading.


Ii. Copy of documents

Select Preferences->browse Packages


After you open the folder. Locate the folder for the topic you just downloaded. Copy the Xxxx.tmtheme file and paste it into the user folder of the previous folder. (here to say a word, I tried not to copy over, directly placed in the original folder below, just do not know if it is because there are spaces in the folder.) The configuration failed, so I copied it over.

Again, this is also convenient to do their own custom, will not affect the original theme.


Third, change the configuration information

Open a file that you want to customize highlighting, for example I just open the previous profile and choose Preferences->settings-more->syntax Specific-user

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvemh5bdgxntcxmje=/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">

Sublime text will itself open a json.sublime-settings empty file. Copy the following code into the file. From this path you should be able to know what is going on, is to specify a proprietary highlight rule file.

{  "color_scheme": "Packages/user/cobalt2.tmtheme"}
Take a look at the new effect


Feel a little "kill Matt" Ha, just this is just a demo. Don't mind the details.

That's the way it is. The following stickers out a few good-looking themes of the preview map, convenient for everyone to choose.

Four, the theme recommended Nexus Theme

Pseudo OSX Theme

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvemh5bdgxntcxmje=/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">

Flatland Theme

watermark/2/text/ahr0cdovl2jsb2cuy3nkbi5uzxqvemh5bdgxntcxmje=/font/5a6l5l2t/fontsize/400/fill/i0jbqkfcma==/ Dissolve/70/gravity/southeast ">
Reeder Theme

First, there are too many subjects. Didn't try to come over. We can try it on their own, what good-looking theme do not forget through the landlord yo ~


"Software Tricks" Sublime text defines different highlighting for different grammars

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.