1 posts
How to fix function recognition in header files

Hey all.

I've been using 4Coder with the provided fleury customizations (as well as a few of my own tweaks) for a while, but have noticed that functions don't get syntax highlighting* if written in a header file. In order for 4Coder to highlight them properly I'm forced to write an accompanying .cpp file, which is often unnecessary overkill.

*Functions defined in header files also don't show the popup signature when using the "pos_context_tooltips" addon.

  • Function declared and defined in the header file:


  • Function declared in the header file and defined in a .cpp file:


(Ignore the erroneous highlighting of 'Clear', which is probably a function in one of the libraries my project's using)

Can this be fixed? If so, which files are responsible? The 4coder_[fleury/casey]_index.cpp files look promising but I can't find anything that might be discriminating by file type, and token parsers are really not my thing!

Simon Anciaux
1341 posts
How to fix function recognition in header files
Edited by Simon Anciaux on

Late reply, but you will probably get more answers if you ask on either the 4coder discord or the handmade.network discord.