Author Topic: Codeblocks Code completion working partially  (Read 9143 times)

Offline popashtefan10

  • Single posting newcomer
  • *
  • Posts: 3
Codeblocks Code completion working partially
« on: February 10, 2021, 08:33:51 am »
My issue is that the code completion does not show me suggestions for C functions, for example when I type "sca", or "scan" it does not show any function suggestions at all (I wanted it to show scanf). I run codeblocks.exe from C:\Program Files\CodeBlocks. Also, if I run the CbLauncher.exe file from the same folder it shows me scanf, printf and other C functions. Before this issue I have used Codeblocks on the same PC, so I might have changed by mistake some settings which caused this issue.
I reinstalled Codeblocks from the official site, binary releases for Windows, codeblocks-20.03mingw-setup.exe.

Later Edit: the C functions work properly even though they don't show up in the code completion suggestions.
« Last Edit: February 10, 2021, 08:35:40 am by popashtefan10 »

Offline Miguel Gimenez

  • Developer
  • Lives here!
  • *****
  • Posts: 1553
Re: Codeblocks Code completion working partially
« Reply #1 on: February 10, 2021, 12:36:11 pm »
Go to Settings -> Editor -> Code completion -> C/C++ parser and verify if at least the first two options are checked

Offline popashtefan10

  • Single posting newcomer
  • *
  • Posts: 3
Re: Codeblocks Code completion working partially
« Reply #2 on: February 10, 2021, 06:04:52 pm »
All 5 options are checked. Also I have the "Use one parser per project" option checked, even though it doesn't work with the other one as well.

Offline popashtefan10

  • Single posting newcomer
  • *
  • Posts: 3
Re: Codeblocks Code completion working partially
« Reply #3 on: February 10, 2021, 06:49:32 pm »
I managed to solve the problem by deleting the "Codeblocks" folder inside %APPDATA% after I uninstalled it. I reinstalled CB and code complete works fine.

Offline alexmk

  • Single posting newcomer
  • *
  • Posts: 4
Re: Codeblocks Code completion working partially
« Reply #4 on: December 17, 2022, 05:17:47 pm »
I found that "Code completion" doesn't work for WxWidgets but only if I chose new project as console application, not wxWidgets. 
wxWidgets compile successfully.
Operationg system - Linux Mint. Code blocks installed from repository.
What setting need to add to fix this?

Offline alexmk

  • Single posting newcomer
  • *
  • Posts: 4
Re: Codeblocks Code completion working partially
« Reply #5 on: December 17, 2022, 05:23:39 pm »
I found solution:
Open 2 projects, where one is configured for wxWidgets project.
In the settings->editor-> Code completion -> C/C++ parser-> check "Use one parser for hole workspace".
Now it works fine.

Offline mariusm

  • Multiple posting newcomer
  • *
  • Posts: 46
Re: Codeblocks Code completion working partially
« Reply #6 on: May 15, 2023, 10:09:42 am »
Have the same problem  :(

If I switch to "Use one parser for hole workspace" or "One parser per project" the code completion restart and works for a while but stop again after a few minutes.

How to solve this error from source or how can I add a button on toolbars for easy restart ?