Home Download Buy Blog Forum Support

Syntax highlighting customizations

Syntax highlighting customizations

Postby biatche on Sat Dec 26, 2009 6:26 pm

I write a lot of notes in .txt files and files without any extensions

as an example

ill have

[format pc]
driver download ; need latest version

so i'd wanna highlight [abc] //backup and ; need latest version

how exactly do i create highlighting of such? and how can i have my customized syntax highlighting by default for not "known" extensions..

offtopic.. im switching from notepad++, theres a feature that i like in notepad++ and that's when i make changes to a document, theres a color mark that shows which lines been edited

Anyway, sublime is a really awesome program I must say :)
Posts: 3
Joined: Sat Dec 26, 2009 6:18 pm

Re: Syntax highlighting customizations

Postby kveldulv on Mon Dec 28, 2009 2:57 am

Check out markdown, which is basically structured text used for converting into HTML etc. If nothing else, it's a good start for what you're trying to do. 'Sunburst' and 'Cobalt' are nice themes for markdown.

If you edit the syntax highlight files you'll be able to set your own custom formats, codes etc.

> how exactly do i create highlighting of such?

Editing the ".tmtheme files", and the ".tmlanguage" files which are what determines/controls syntax highlighting.
I'm pretty crap at it myself, but there's a few tutes around on the forum, and lots more info out there.


Here's some example markdown to get started and see if that's what you're after. Either save it as a *.md file, or just set the syntax to markdown.

Code: Select all
# Header 1 #

* * *
- - - -
*italic*   **bold**
_italic_   __bold__

This is text with a footnote.[^1]

An [example](http://url.com/ "Title")


Inline styles


_italic one_ not italic _italic two_

Posts: 4
Joined: Mon Dec 21, 2009 6:36 pm

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 36 guests