User forums > General (but related to Code::Blocks)
How to add additional search paths to code completion parser with wizard
riban:
I am writing a new project wizard to create a C++ project for the Sming (ESP8266) framework. I would like to add search paths to the project properties C/C++ parser options so that auto complete works for the Sming library functions. I see that this is stored in the <Project><Extensions><code_completion> section of the project file but I cannot figure out how to add paths using wizard scripting.
I have this working using the simple template method but that is not as user friendly, hence my desire to use a wizard.
oBFusCATed:
You could probably use the void cbProject::AddToExtensions(const wxString& stringDesc) method.
riban:
I cannot find any description of what syntax the argument should be for AddToExtensions(wxString). I would need to pass the extension (code_completion) and the data which in the project file is an XML tag with attribute, e.g. <search_path add="my_include_path" />).
riban:
I have found this in the source code of cbproject.cpp:
--- Code: ---// sample stringDesc:
// node/+subnode/subsubnode:attr=val
--- End code ---
So I have tried adding this to my wizard:
--- Code: ---project.AddToExtensions(_T("code_completion/+search_path:add=include_path"));
--- End code ---
But this does not work. Any clues?
BlueHazzard:
Look here, maybe you hit the limitations described here:
https://sourceforge.net/p/codeblocks/tickets/513/
I will look into this later....
Navigation
[0] Message Index
[#] Next page
Go to full version