AS6: Extending default syntax highlight.

Go To Last Post
11 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello.

The new C++11 standard adds a few of new keywords, like "constexpr", "decltype", "override" and others. But latest version of the Atmel Studio (even 6.2 beta) does not highlight these keywords at all. Nor Atmel Studio itself, nor VAssistX. It's not a big deal of course, however, it would be nice to see new keywords highlighted too.

Microsoft Visual Studio allows this by creating usertype.dat file in the "Common7/IDE" folder (see http://msdn.microsoft.com/en-us/... for example).

But with Atmel Studio such trick doesn't work.

Is there some possibility (except adding #defines to the VAssistX's stdafx.h file) to add custom keywords so that they be highlighted like standard C++ operators (e.g. "while", "for", "switch" etc.)?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The file Cpp.va in extensions/Whole Tomato Software/Visual Assist X for Atmel Studio/10.xxxxx/Misc looks promising.

Regards,
Steve A.

The Board helps those that help themselves.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Koshchi wrote:
The file Cpp.va in extensions/Whole Tomato Software/Visual Assist X for Atmel Studio/10.xxxxx/Misc looks promising.

Yes, it is. But only on the first look. Lets see closer.
Part of the Cpp.va file:

As we can see, here two identical records for mutable and naked keywords. If we try to type mutable in the AS6 Text Editor, it will be highlighted. Okay. However, if we try to type naked keyword, it will not :(

The question still actual :)

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Dear AS6 dev team,
even you have nothing to say? :(

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello, I need default syntax highlighting for .txt files... How to do this?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

Dear AS6 dev team,
even you have nothing to say?

Much to say, little input :P

We do primarily use VAX for syntax highlight, so the .dat tricks is not going to work. I don't know anything about extensibility for VAX. IF you want us to look into this, please contact Atmel Support.

Quote:

Hello, I need default syntax highlighting for .txt files... How to do this?

Create a highlighter. I and Dean wrote this, which is now deprecated as it is merged into the Atmel Studio core. It shows however how to extend the editor to recognize any syntax. If you want to be really full featured, you can write a [url=http://msdn.microsoft.com/en-us/...(v=vs.100).aspx]language service[/url] for all projects that use the Visual Studio editor framework (MEF and or MPF).

:: Morten

 

(yes, I work for Atmel, yes, I do this in my spare time, now stop sending PMs)

 

The postings on this site are my own and do not represent Microchip’s positions, strategies, or opinions.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Using .txt Files for Assembler-Code (can be better displayed on mobile apps to take a look) I only want to use AS6 built-in Asm-File Highlighting... There is a way to use it?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Under tools/options inside studio there should be options to assign file extensions to types. Google for how this can be done in visual studio, and you should find the procedure identical.

:: Morten

 

(yes, I work for Atmel, yes, I do this in my spare time, now stop sending PMs)

 

The postings on this site are my own and do not represent Microchip’s positions, strategies, or opinions.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

This time there is no option available to do this for assembler- .txt files in AS6.2beta.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

meolsen wrote:

Much to say, little input :P

We do primarily use VAX for syntax highlight, so the .dat tricks is not going to work. I don't know anything about extensibility for VAX. IF you want us to look into this, please contact Atmel Support.

Too bad... I hoped that there is a simple solution.

Thank you :)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I have the solution to highlight the custom words.

Please mail me, if anyone need vsix extension.

haiganeshkumar@gmail.com

It will be part of XFeatures version 1.6. But will take time to load it into atmel gallery.

Attachment(s):