FAQ-Issues and Workarounds
- 1 Q: Sometime, in the text editor, space bar triggers Code Completion, how do I fix that?
- 2 Q: IDE is drawing the text from Right to Left?
- 3 Q: All the options in the debug menu are grayed out?
- 4 Q: My project works everywhere except one computer?
- 5 Q: Syntax highlighting is broken; how do I fix it?
- 6 Q: I posted on the forums that Code::Blocks was not working, but no one could help me?
- 7 Q: I cannot find any text in my Code::Blocks logs?
Return to FAQ.
Q: Sometime, in the text editor, space bar triggers Code Completion, how do I fix that?
A: Information found on the forum.
It's possible to fix this issue editing the keyboard entry in /etc/X1/xorg.conf file. However, some recent distribs use HAL, therefore xorg.conf is empty (since Ubuntu 8.10 for instance). It's also possible to use a setxkbmap tool.
Hal Solution (Ubuntu 8.10 and above):
For Ubuntu (and other gnome desktops), another simple solution for the current user is to change a preference.
- Menu System => Preferences => Keyboard
- Select Tab Layout
- Edit "Layout Options..."
- Expand last option "Using space key to input non-breakable space character"
- Select the last choice "Usual Space at any level"
This is not system wide.
A system wide solution would be to add an fdi file there (for instance)
put the right thing in it (I did not succeed), unplug your keyboard, plug it again.
Xorg Solution (prior Hal based distrib):
as root, edit /etc/X11/xorg.conf and find something like :
Section "InputDevice" Identifier "Generic Keyboard" Driver "kbd" ... Option "XkbVariant" "oss" EndSection
Try one of the following workarounds :
1. you comment the line
Option "XkbVariant" "oss"
# Option "XkbVariant" "oss"
2. you replace
This works for Ubuntu prior 8.10 (before hal)
It seems that KUbuntu requires the following line:
Option "XkbOptions" "nbsp:none"
run this command before running Code::Blocks (works fines for KUbuntu)
setxkbmap -option nbsp:none
if it's not enough you can try:
setxkbmap -option nbsp:none -model pc 105 -layout fr -variant latin 9
Q: IDE is drawing the text from Right to Left?
A: Uncheck "Settings -> Environment -> View -> Internationalization" and restart Code::Blocks
Note: Code::Blocks only supports the GNU GDB and MSVC CDB debuggers.
Q: My project works everywhere except one computer?
A: Some parts of Code::Blocks or the back-end compiler may not support non-ASCII characters (such as é) or possibly spaces. Try moving the project on the affected computer to a directory that contains neither of these in its path.
Q: Syntax highlighting is broken; how do I fix it?
A: Code::Blocks cannot know how to highlight your code unless it knows what lexer to use. This is normally automatically determined by the file extension, so it is important to save the file and name it correctly (*.c or *.cpp for C and C++ code). It is also possible to activate syntax highlighting on a temporary basis. Open Edit->Highlight mode and select the language the current file is using.
Q: I posted on the forums that Code::Blocks was not working, but no one could help me?
A: There is a distinct lack of crystal balls and divining mirrors here, so you may want to post some information. Using this template in your problem description would be a great help.
Q: I cannot find any text in my Code::Blocks logs?
A: On MS Windows, wxWidgets sometimes does not show the content of logs at first; scrolling in the log will bring the text to visibility.
Return to FAQ.