Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: Folco on November 14, 2010, 12:28:02 am

Title: How to save syntax highlighting ?
Post by: Folco on November 14, 2010, 12:28:02 am
Hi,


I use .h files in an assembly project. Headers files are automatically colourized as C++ header files. I can colourize them as asm files by using Edit->Highlight mode->Assembly 68000 (I binded that to do it more quickly).

But is there a way to have these files of this project colourized permanently ?

If not, could the coloration be added in the .cbp file to remember that ?
Title: Re: How to save syntax highlighting ?
Post by: xunxun on November 14, 2010, 09:30:23 am
Could you try change the ".h" to ".inc"?
Title: Re: How to save syntax highlighting ?
Post by: Folco on November 14, 2010, 10:24:58 am
Of course, it would work, but I can't rename the files of all guys of the TI-68k communauty beacause I use C::B ^^
Title: Re: How to save syntax highlighting ?
Post by: xunxun on November 14, 2010, 11:31:36 am
Hi,


I use .h files in an assembly project. Headers files are automatically colourized as C++ header files. I can colourize them as asm files by using Edit->Highlight mode->Assembly 68000 (I binded that to do it more quickly).

But is there a way to have these files of this project colourized permanently ?

If not, could the coloration be added in the .cbp file to remember that ?

Yea, but I don't understand your meaning. Is it that you want to delete the ".h" highlight in the C/C++ highlight, or you want to take ".h" highlight in C/C++ and asm highlight all effective?
Title: Re: How to save syntax highlighting ?
Post by: Folco on November 14, 2010, 01:17:28 pm
I would want that CB remember that it must apply asm highlight to the .h files of this project (and keep C/C++ highlight for files outside this project).
Title: Re: How to save syntax highlighting ?
Post by: xunxun on November 14, 2010, 03:13:23 pm
I have no idea to solve it, and Scintilla can autodetect highlight when opening some files. I don't know how to disable its autodetect.
Title: Re: How to save syntax highlighting ?
Post by: Folco on November 14, 2010, 03:38:24 pm
Saving an info in the .cbp file could probably do that. But I don't know anything in XML format ^^
Title: Re: How to save syntax highlighting ?
Post by: cdavalillo on August 26, 2023, 06:41:47 am
It would be nice if Code::Blocks developers team could add some functionality to save syntax highlight to XML files that the user can load later if there is another installation (for example at work) where the user needs to work with.
Title: Re: How to save syntax highlighting ?
Post by: Miguel Gimenez on August 26, 2023, 11:29:33 pm
A ticket marked as Feature request will be more durable than this post.