How To Install Dark Themes In Code::Blocks

Code::Blocks is mostly used opensource IDE due its great features. Code::Blocks is lightweight and easy to use. Becoming opensource it is also available for Linux and is free to download and use. It is best IDE for beginners, who wants to learn C, C++ and FORTRAN and for creating small projects. However for large projects Code::Blocks may not be good.

Code::Blocks comes with light theme by default and not all users like it. There is no option to change the editor theme is Code::Blocks however we can change it manually. Here is how to install Code::Blocks themes.

Theme download link is given at the end of this post.

Available Code::Blocks Themes

  • Son of Obsidian (my favorite)
  • Sublime
  • Oblivion
  • Vim
  • Dark gray
  • KFT2
  • Bright yellow
  • Espresso Libre
  • Modnokai Coffee
  • Modnokai Night Shift
  • Modnokai night Shift v2
  • Slush and Poppies
  • Solarized Dark
  • Solarized Light

How to install CodeBlocks theme?

First you need to download the themes, download it from here: Code::Blocks Theme. Then extract it on the desktop. Close the CodeBlocks application before opening CB Share Config. CB Share Config is a tool that installs along with CodeBlocks. It can be found in Program list.

  • Exit CodeBlocks if already opened.
  • Open CodeBlock Share Config
  • Browser Destination Configuration file which is in right side.
  • Select default.conf
  • Browse Source Configuration file which is in left side.
  • Select the downloaded theme.conf
  • Tick all the checkbox that appeared in source configuration file, which is in right side. (You can use space to tick)
  • Click on Transfer and then Save, and then Close.
  • Now open CodeBlocks, goto Settings>>Editor>>Syntax Highlighting and then Color Themes.

For Linux/Ubuntu

Open CB Share Config using: $ cb_share_config. Then follow the above steps for windows.

For Mac

default.conf is located at ~/Library/Application Support/codeblocks/default.conf and cb_share_config is under CodeBlocks.app/Contents/MacOS/cb_share_config. The <strong>Library</strong> folder is by default hidden by the most recent version of Mac OX. You could use COMMAND+SHIFT+G to navigate to hidden folders.

Watch this video to learn how to install dark themes in CodeBlocks

https://www.youtube.com/watch?v=H-7uVSrnrnU
Installing Code::Blocks themes
  • If you don’t have default.conf file inside CodeBlocks directory try creating a project, it will be generated.
  • If background of line number did not change go to settings > environment settings > colors. Then edit the following; editor-caret,line number background color, line number foreground number, margin chrome color, margin chrome highlight color.

Downloads

Google Drive – https://drive.google.com/open?id=1qj6UpKXokr_QHLrRalMrTcMjsed8vKcI

Also see – How can you Activate Windows 10 for Free

ZippyShare – https://www54.zippyshare.com/v/FZCpqIEx/file.html

Important Links

Code::Blocks Forum: http://forums.codeblocks.org/

Source : http://wiki.codeblocks.org/index.php/Syntax_highlighting_custom_colour_themes

Problem finding default.conf file?
You may want to read FAQ – http://wiki.codeblocks.org/index.php/FAQ-Settings

This Post Has 71 Comments

  1. 메이저사이트

    Really when someone doesn’t be aware of then its up to other viewers
    that they will assist, so here it takes place.

  2. ONESMUS

    what next after selecting color theme

  3. Soreen

    Works Perfectly >>> I’ve discovered hot to access the black theme finally my eyes are not burnt out!

    installed VSCode! :))))))

  4. Alex

    I checked all the boxes, but is says that at least one configuration is empty or invalid

  5. Ravi Joshi

    Hello, The procedure works for C/C++, for for Fotran it doesn’t work. I’ve CB 17.
    Can you please help? Thx

  6. Bolo

    Works perfectly. Linux AntiX 19.3 and CodeBlocks 16.01. Thank you very much, Sangam!

  7. themanlie

    very well. thank you

  8. tibike

    “Tick all the checkbox that appeared in source configuration file, which is in right side. (You can use space to tick)”
    Correction: Which is at the left side…
    “Browser Destination Configuration file which is in right side.”
    Correction: Browse… (without the +r)
    default.conf is at c:\Users\\AppData\Roaming\CodeBlocks\
    But you have to set ‘show hidden folders/files’ (or something like that) in whatever file manager you use.

    1. Sangam Shrestha

      Thank you for the correction. This post has been for three years, no one noticed that, even I didn’t noticed that. Lol. I will update my post shortly..

  9. Sheikh Ariful Islam Rayhan

    MY code block are not setting up the theme, how do I setup now ???

  10. Nu am

    Thank you a lot sir!

  11. KK

    how to turn whole UI into dark?

  12. Hernán Vega

    ¡It works!. Thanks.

  13. Marco

    ¡It works! Thanks.

  14. ali

    i did it thanks a lot. but just editor text changed. how can i change color of upper bar and management arena to dark mode?

  15. Fateme

    thanks… its really nice

  16. David

    can you please help me find default.conf?

    1. Sangam

      There is a .bat file inside the downloaded archive that will help you to find default.conf.

    2. Punith

      Cool♥️

  17. Hugo

    Hi, Sangam!
    Dark themes only work for C/C++ code, aren’t they?
    I tell you because I work Fortran code and any dark theme don’t work, just on my C/C++ code.

    1. Sangam

      Thanks for informing Hugo 😊.

  18. RASOUL

    Thanks a lot Dear Sangam….

  19. DM

    after installing this my CB takes 20-30 seconds to startup!!! What happend?
    i tried reinstalling it for 3 times and still startup is slow.

    1. Sangam

      I don’t know may be it is loading theme and configurations.

  20. samy

    hey…Thanks a lot for the post. Editor turned to dark mode but the number line
    I cant find colors under environment setting.

    1. samy

      Editor turned dark but not the number line.*

    2. Sangam

      If background of line number did not change go to settings > environment settings > colors. Then edit the following; editor-caret,line number background color, line number foreground number, margin chrome color, margin chrome highlight color.

  21. Raffy

    Thanks for this Mr. Sangam. Its a great modification in the theme of code::blocks editor. It’s very useful for me when I code for a longer period of time.

  22. Alex Bodnaru

    thank you very much sangam

  23. lostted

    24.03.2020 Works perfectly, thanks!

  24. Try

    Now it’s not working, don’t recomend.

  25. Mokhsedul Haque

    Thanks…………………………………………………………………..

  26. Thành TC

    Thanks. I’ve done it. I don’t know why it so hard to find a true Obsidian theme.

  27. Lemalex

    Hello!
    I use Code::Blocks installed from ports at FreeBSD 12.1. There is cb_share_config tool, but I have no idea where default.conf is located.
    Maybe somebody knows?

  28. Nathan

    Thanks for the post.
    I have tried it, but after following the instruction, the “colour theme” setting in Editor settings -> syntax highlighting can only be set to Default, as if I have done nothing.
    Do you know what happened?
    I did clicked transfer, save and close… 🙁

    1. Nathan

      Solved : i had two default.conf files ._.
      thanks 🙂

      1. Sangam

        😉

  29. fsda

    I did what was in the article and it worked but the left bar of the editor which has the line numbers stays white regardless of theme, how can i change that?

    1. Sangam

      That should be set manually from appearance settings. Go to settings > environment settings > colors. Then edit the following; editor-caret,line number background color, line number foreground number, margin chrome color, margin chrome highlight color. Shout me if u need further help.

  30. Izmox

    Thanks!

  31. 5n1p3r_4rt3m1s

    I think in newer versions of CodeBlocks utility “CB Share Config” renamed to “CodeBlocks Share Config”, this might lead to confusion.

    1. Sangam Shrestha

      Thanks for your kind response. I will update the post shortly.

  32. ruby

    i dont have the defualt..conf on my code blocks folder

    1. Sangam Shrestha

      Sorry, create a project in CodeBlocks. That file will be generated..

      1. vikram

        i created new project but cant find default.conf file

        1. NotPhysicist

          Me too

          1. Sangam

            I don’t use CodeBlocks now but when creating new project default configuration were generated. You could also try reinstalling it.

  33. Hammad-Ur-Rehman

    How to Make it fully Dark. I mean the whole interface not only editor.

    1. emtias

      use high contrast theme for desktop background.
      personalize>>high contrast theme

      1. Jean

        Hi. Where could you find this option ?

        1. Sangam

          He is talking about high contrast theme in Windows 10.

  34. ved

    how to revert back to original theme?
    I have not saved the original file.

    1. Sangam Shrestha

      Delete the configuration file or restore default settings.

  35. Parin

    thnx a lot man!!

  36. Samuel

    Great man.. Really Helpful…But themes was found under customized themes which was extracted to the desktop…
    *To those who may not find it..

  37. Michael

    So I have done this successfully however I was wondering if there is an easy way to modify the colors of the CodeBlocks IDE that are not associated with the text editor. I would like to make the “windows” dark themed. Thanks.

    1. Sangam Shrestha

      Thanks for your valuable comment. Only the color of editor can be changed.

  38. Shadman

    Hi
    I used your instructions to change my theme to dark in windows but is there a way to change my Code::Blocks theme in Linux Ubuntu?

    1. Sangam Shrestha

      Open CB Share Config using: $ cb_share_config. Then follow the above steps for windows.

    2. tito

      $ cb_share_config
      exactly the same steps
      Now I’ve Color themes on Fedora 29

      1. Sangam Shrestha

        Thanks for trying with Linux. I never tried that. I have updated the post.

  39. Chris

    Ok, I did everything according to instructions, downloaded the colorschemes.conf, merged it with default.conf
    using the share tool, enabled the theme in the editor settings, and I get the right theme in the code preview window, but when I go to the real window and open a new project or file, it is still just black on white! It just doesn’t work … I cant use an editor with white background.

    1. Sangam Shrestha

      It is because you have not saved your file yet. Save your new file (CTRL+S) and give an extension (if you are doing C++, newfile.cpp), now it should work.

  40. Chrs

    There is no cb_share_config.exe file with the Code::blocks install I have …

    1. Sangam Shrestha

      You can find CB Share in the installation directory. If it is not there reinstall Code::Blocks and select CB Share also while installing.

  41. Josh

    Thank you so much.

  42. Alilion

    Thanks
    You are good

Leave a Reply to vikram Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.