You are not logged in.
Pages: 1
I'm not sure if this is more suited for another section such as programming, but I decided to post here. I'm pretty new to VIM and have been trying to get my highlighting theme to match as closely as possible to an already existent one.
http://www.monokai.nl/blog/wp-content/a … iTheme.gif
http://blog.cosmix.org/wp-content/uploa … onokai.png
http://www.neurosoftware.ro/programming … onokai.png
I know that some themes already exist for VIM that are based on Monokai such as Molokai etc., but nothing seems to highlight as it shows in the TextMate versions I've seen online e.g. function is not highlighted blue, the name of the function is never highlighted green etc. What I wanted to do was try and make VIM look exactly like the original Monokai theme. If anyone could help me to get certain parts to highlight properly I would greatly appreciate it.
Listed is the original code for the theme
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>name</key>
<string>Monokai</string>
<key>settings</key>
<array>
<dict>
<key>settings</key>
<dict>
<key>background</key>
<string>#272822</string>
<key>caret</key>
<string>#F8F8F0</string>
<key>foreground</key>
<string>#F8F8F2</string>
<key>invisibles</key>
<string>#49483E</string>
<key>lineHighlight</key>
<string>#49483E</string>
<key>selection</key>
<string>#49483E</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Comment</string>
<key>scope</key>
<string>comment</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#75715E</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>String</string>
<key>scope</key>
<string>string</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#E6DB74</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Number</string>
<key>scope</key>
<string>constant.numeric</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#AE81FF</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Built-in constant</string>
<key>scope</key>
<string>constant.language</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#AE81FF</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>User-defined constant</string>
<key>scope</key>
<string>constant.character, constant.other</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#AE81FF</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Variable</string>
<key>scope</key>
<string>variable</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Keyword</string>
<key>scope</key>
<string>keyword</string>
<key>settings</key>
<dict>
<key>foreground</key>
<string>#F92672</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Storage</string>
<key>scope</key>
<string>storage</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
<key>foreground</key>
<string>#F92672</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Storage type</string>
<key>scope</key>
<string>storage.type</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>italic</string>
<key>foreground</key>
<string>#66D9EF</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Class name</string>
<key>scope</key>
<string>entity.name.class</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>underline</string>
<key>foreground</key>
<string>#A6E22E</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Inherited class</string>
<key>scope</key>
<string>entity.other.inherited-class</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>italic underline</string>
<key>foreground</key>
<string>#A6E22E</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Function name</string>
<key>scope</key>
<string>entity.name.function</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
<key>foreground</key>
<string>#A6E22E</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Function argument</string>
<key>scope</key>
<string>variable.parameter</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>italic</string>
<key>foreground</key>
<string>#FD971F</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Tag name</string>
<key>scope</key>
<string>entity.name.tag</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
<key>foreground</key>
<string>#F92672</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Tag attribute</string>
<key>scope</key>
<string>entity.other.attribute-name</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
<key>foreground</key>
<string>#A6E22E</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Library function</string>
<key>scope</key>
<string>support.function</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
<key>foreground</key>
<string>#66D9EF</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Library constant</string>
<key>scope</key>
<string>support.constant</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
<key>foreground</key>
<string>#66D9EF</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Library class/type</string>
<key>scope</key>
<string>support.type, support.class</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string>italic</string>
<key>foreground</key>
<string>#66D9EF</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Library variable</string>
<key>scope</key>
<string>support.other.variable</string>
<key>settings</key>
<dict>
<key>fontStyle</key>
<string></string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Invalid</string>
<key>scope</key>
<string>invalid</string>
<key>settings</key>
<dict>
<key>background</key>
<string>#F92672</string>
<key>fontStyle</key>
<string></string>
<key>foreground</key>
<string>#F8F8F0</string>
</dict>
</dict>
<dict>
<key>name</key>
<string>Invalid deprecated</string>
<key>scope</key>
<string>invalid.deprecated</string>
<key>settings</key>
<dict>
<key>background</key>
<string>#AE81FF</string>
<key>foreground</key>
<string>#F8F8F0</string>
</dict>
</dict>
</array>
<key>uuid</key>
<string>D8D5E82E-3D5B-46B5-B38E-8C841C21347D</string>
</dict>
</plist>-- mod edit: read the Forum Etiquette and only post thumbnails http://wiki.archlinux.org/index.php/For … s_and_Code [jwr] --
^ Sorry about that should have read this stuff.
Last edited by brandon88tube (2011-01-15 20:57:27)
Offline
http://coloration.sickill.net/ could help? You can upload a Textmate theme and convert it to jEdit/Vim/Kate/Kwrite.
Offline
Unfortunately, it didn't convert that well. Some of the colors were off and it was highlight the brackets among other things, but some parts were close. Thanks for the suggestion though.
Offline
Thanks, but I've already tried Molokai and even another one that was even called Monokai... So far all seem to fail in some aspect. Its kind of disappointing so I've been trying to make my own to make it as close as VIM will allow and that is why I decided to ask here for some help.
Offline
Well, a perfect match with TextMate will be very difficult to achieve, if possible. You can get the colours (as in shades) right or almost right fairly easily. However, what words are highlighted and in what colour, is still going to be quite different. You'd probably need to rewrite all the relevant highlighting files, and that's a lot of work.
What is your exact problem?
Last edited by caminoix (2011-01-15 21:30:04)
Offline
Not sure if I'm asking for too much, but I just don't like that I can't have my code look like the original Monokai theme. I'll probably have to settle for something close, but I was hoping that I could just write a better theme file that was closer to the original than the ones I've used so far.
Offline
But what is the exact problem? Is it that the shades of colours are different, or that different words are highlighted in different colours. If it's the former, perhaps you're using two different monitors and hence the perceived difference? If it's the latter, you'll need to rewrite or adjust the highlighting definitions for the language(s) in question.
Offline
It would be the second part where the wrong syntax is being highlighted etc.
Offline
It would be the second part where the wrong syntax is being highlighted etc.
In that case messing with the colour scheme is in vain. Like I said, you have to adjust the highlighting files to your taste. Actually, sorry, syntax files is the usual term. Take a look here for a good start.
The syntax definition decides what function a certain word has. The colour scheme assigns colours to functions. In order to mimic TextMate you have to change both. Note, that the behaviour will still remain Vimish. This is configured yet somewhere else.
Offline
Not sure what you mean by still being Vimish, but I'll see what I can do.
Offline
Pages: 1