Add syntax highlights for modern languages

Open discussion about WinMerge.

Add syntax highlights for modern languages

Postby hfmm99 » Wed Jul 24, 2019 9:05 pm

I love WinMerge, it's a great tool, and it's free, I am very grateful with the developers who did it.

But, it's very obsolete on the Syntax Highlights it supports. It doesn't even support Javascript, JSON, YAML. Or is there any way to add custom languages? I'd love to add one for GraphQL for example.

Can you please at least add support for Javascript/JSON?

Thanks.
hfmm99
 
Posts: 1
Joined: Wed Jul 24, 2019 8:56 pm

Re: Add syntax highlights for modern languages

Postby dbague » Wed Dec 04, 2019 4:45 pm

hfmm99 wrote:"Or is there any way to add custom languages? ...
Can you please at least add support for Javascript/JSON?
...


I concur with all of op request. but emphasize that while the first request is considered or rejected, that the ones I quoted be considered anyway and the custom way in priority as likely most easy... i may be wrong about that.

Alternative questions, where are the syntax highlights language definitions available in the software file structure or registry? is is encrypted, or text? thanks you for your help.
dbague
 
Posts: 1
Joined: Wed Dec 04, 2019 1:23 pm

Re: Add syntax highlights for modern languages

Postby jtuc » Fri Dec 27, 2019 12:18 pm

The only things about syntax highlighting which WinMerge allows users to configure is colors to use for various syntactic elements, and which of them to emphasize with a bold font. Everything else is hard-coded in C++.
The .js filename extension is associated with the Java highlighter. This works to some extent.
A more fundamental issue is scripts embedded in HTML pages. If this is your use case, you may want to try https://bitbucket.org/jtuc/winmerge2011.
WinMerge 2011 is also aware of JavaScript regular expression literals and template strings.
I plan to contribute the improvements to WinMerge 2.x, but I cannot tell if and when this will actually happen.
jtuc
Developer
 
Posts: 183
Joined: Sat Dec 20, 2008 11:05 am


Return to Open Discussion

Who is online

Users browsing this forum: Chloehat, MSN [Bot] and 8 guests