Fw: TypeScript Syntax in Kate

rhkramer at gmail.com rhkramer at gmail.com
Fri Feb 2 14:30:53 UTC 2018


On Friday, February 02, 2018 01:30:18 AM My Email wrote:
> Hi Dominik...
> 
> 
> I am too much of a noob to create a definition file.
> 
> Dont have the know-how to create such an xml file...
> 
> 
> I did the .xml file located at;
> 
> 
> https://github.com/PrettyFlower/KateTypeScriptSyntaxHighlighting
> 
> 
> 
> but i could not get it picked up by Kate. I have tried to get it to work
> with Kate v16 and Kate v17 but to no avail.
> 
> 
> U have any ideas ?

Did you find and follow the instructions for making such a file active?

I can't recite them off the top of my head, but I did create a .xml 
highlighting file.  I think the prime requirement is to put it in a specific 
directory.

On my Debian Wheezy, kde 4.8.4, kate 3.8.4 system, the .xml files are in 

/usr/share/kde4/apps/katepart/syntax/

If you put the file there, and then restart kate, you should be able to go to  
Tools --> Hightlighting (or Tools --> Mode--I'm not clear on the difference 
between the two, and my .xml files show up on both, and I can select it either 
place) and find your highlighting file--there are a lot of categories there, and 
you may have to look through all of them to find your highlighting file.

Then, with a file loaded into kate which you want to highlight, go to the Tools 
--> Hightlighting (or Mode) menu and select your .xml file.

There is a way to have kate pick the proper highlighting file automatically 
based (at least) on the file extension (maybe also without a file extension 
based on the "magic number" recognition of the type of file.

I set mine up to be automatically recognized, but I don't recall how I did it.

Hmm, kate version 16 and 17--hmm, I don't recognize those numbers--are those 
very old or very new?

I guess your question would have saved me typing if you had been more explicit 
about how you tried to get the file to work--where did you install it and what 
did you do after installing it.



More information about the KWrite-Devel mailing list