Code::Blocks Forums
User forums => Help => Topic started by: Commaster on August 30, 2013, 08:13:37 pm
-
I recently tried to use #define in my wxFrame project and stumbled upon some strange highlighting.
(http://i.imgur.com/YKJXUj4.png)
After some investigation I found out, that the "#define" is highlighted with an extra space after it:
(http://i.imgur.com/iluDp6Y.png)
Although the "#ifndef" is highlighted properly.
I'm using Ubuntu 13.04 x64, Code::blocks svn 9271.
And I'm using double-click to select words for highlighting.
-
No such issues here (Fedora 19 x64 svn r9272).
What is your file-encoding and which language-settings dp ypu gave on your system ?
-
All project files are UTF-8 with CR+LF.
Language settings seems to be English(United States).
-
Similar settings here.
Can you send me a minimal file which leads to this issue ?
Either attach it here or send it to me via mail to my username at codeblocks dot org.
-
I created a fresh Frame based project with the name "jensproject", cleaned up the authorinfo and modified the Main.cpp:
line 6.
Update: Reproduced with Dialog based project too.
-
I'm still not able to reproduce this issue.
I tested it on Fedora with latest trunk and on Ubuntu 13.04 with 9266.
-
Do you use a self-build C::B ?
If yes, did you make sure your build-tree was absolutely clean ?
Are you sure no older C::B libs can interfere with your actual revision ?
-
I'm using the same build script (evolved, updated) as in my previous post: http://forums.codeblocks.org/index.php/topic,17724.0.html
-
Can you try to rebuild, but remove everything related to your old install(s) manually before the build ?
make uninstall does not always do what you expect, especially if Makefile's have changed, and make is forced to use the new ones to remove an older install.
-
Lucky me, cause I don't checkout before I uninstall as is seen in that script. But I'll try nevertheless.
(that'll take ~ 10 hours cause of the night time)
-
Turns out it has something to do with my .codeblocks folder (During investigation I tried to move it and that fixed the issue). Although it makes the EOF LF by default now. (But the project and all the files were created with existing profile and EOF CR+LF + consistent EOFs). Any help where to look in the profile for this issue? Or should I send over my profile in tar.gz?
I also tried cleaning up /usr/local/(lib, share, inlcude), but the appropriate folders were just empty folders.
-
All relevant settings should be in default.conf (if you do not explicitely start C::B with a different personality).
You can send the broken one to me, or try to find the diffs to the newly created conf-file.
-
The broken profile is so much bigger than the clean one. Looks like there are many redundant setting stored. Is there a button in Code::Blocks to optimize the config by chance?
(515 kB) http://paste.ubuntu.com/6047311/
-
Can you please also paste the conf-file itself for testing ?
-
default.conf I am using since ... I can't remember. http://pastebin.com/raw.php?i=3U3kEgjC
Thank you very much for helping with the investigation.
-
It seems scintilla or teh font is broken, if I change it in the editor settings it works correctly.
Your font ("Ubuntu" ?) is replaced by "Cantarell" (system default) and this does (reproducible) not work.
The cause seems to be a problem with the "fi" in define which is recognized as one letter and not as two, it might in fact be one special character in the editor.
I think there was similar issue before with some fonts (at least on Ubuntu), but I'm not absolutely sure about this.
In general it is better to use a monospaced font instead a proportional font for programming.
-
Yes, changing the font to, say, Monospace fixes the highlighting.
Thanks again.