User forums > Using Code::Blocks
Change colors for UI (not editor) to make work with OS theme
BossLetsPlays:
For whatever reason I only enjoy coding c++ with a dark color theme, so since I'm on Windows 7 I have installed a skin using WindowBlinds by StarDock. I did this because I know codeblocks tries to use the OS theme to determine how it looks, and for the most part it worked, minus some things I had to change in settings > environment. However if you look at the screenshot at the spots where I rectangled in red, I am wondering if it is possible to change the settings for those colors in codeblocks? I have seen people use dark themes with both windows and linux and things worked correctly for them, however on both my windows and linux systems it seems not to work for me, so can someone either help me figure out how to change the settings for those parts of the UI and or find a good dark theme that works with codeblocks? The skins would need to come from http://www.wincustomize.com/explore/windowblinds
http://prntscr.com/864v8p
scarphin:
I'm having the same problem since I switched to a darker theme. The problem with the tab texts is the foreground color is taken from system colors while the background color/image is hardcoded. I don't know if a configurable solution exists but what I did was to find the piece of code that is responsible for the text color and change it inside the CB source. What I did was switch to 'Visual Studio 7.1' style in 'settings->environment->notebooks appearance->tabs style' and change line 187 & 381 in 'src/src/notebookstyles.cpp'
from:
--- Code: ---dc.SetTextForeground(wxSystemSettings::GetColour(wxSYS_COLOUR_BTNTEXT));
--- End code ---
to:
--- Code: ---dc.SetTextForeground((page.active) ? wxSystemSettings::GetColour(wxSYS_COLOUR_BTNTEXT) : *wxBLACK);
--- End code ---
and rebuild.
I don't have a solution for the icons.
BossLetsPlays:
--- Quote from: scarphin on August 18, 2015, 10:38:05 pm ---I'm having the same problem since I switched to a darker theme. The problem with the tab texts is the foreground color is taken from system colors while the background color/image is hardcoded. I don't know if a configurable solution exists but what I did was to find the piece of code that is responsible for the text color and change it inside the CB source. What I did was switch to 'Visual Studio 7.1' style in 'settings->environment->notebooks appearance->tabs style' and change line 187 & 381 in 'src/src/notebookstyles.cpp'
from:
--- Code: ---dc.SetTextForeground(wxSystemSettings::GetColour(wxSYS_COLOUR_BTNTEXT));
--- End code ---
to:
--- Code: ---dc.SetTextForeground((page.active) ? wxSystemSettings::GetColour(wxSYS_COLOUR_BTNTEXT) : *wxBLACK);
--- End code ---
and rebuild.
I don't have a solution for the icons.
--- End quote ---
Thanks! What exactly is it that the code does, because I don't really feel like rebuilding codeblocks (plus I'm just using the mingw windows pre-built version so not even sure I can)... I ask because other than the icons, just switching to use visual studio tabs seems to work just fine http://prntscr.com/868x3s
oBFusCATed:
@scarphin: If you change works correctly with the default theme you can post a patch and we can integrate it in svn.
scarphin:
@BossLetsPlays: The code changes the foreground color of tab text to a more readable black as seen here:
http://forums.codeblocks.org/index.php/topic,20155.msg137415.html#msg137415
@oBFusCATed: No, it won't work with the default theme but only with VS theme. I couldn't find the default theme's color configuration when I modified the code. It won't also work with bright themes as it will probably display a black on black text. In brief, it's VS style and dark themes only solution.
Navigation
[0] Message Index
[#] Next page
Go to full version