No code completition with using type definition and other

General questions regarding the usage of CodeLite
Akronym
CodeLite Enthusiast
Posts: 15
Joined: Fri Sep 05, 2014 9:02 pm
Genuine User: Yes
IDE Question: c++
Location: Germany
Contact:

No code completition with using type definition and other

Post by Akronym »

Hey,

working with CodeLite again and found some "bugs/issues"

Version 9.0.7
Windows 10 64bit

1.) Using

Code: Select all

#include <vector>

using MyContainer = std::vector<int>;

int main(int argc, char **argv)
{
	MyContainer container;
       container.push_back(1);
    
	return 0;
}
CodeLite will give me no code completion for the variable container. I think the problem is the using type def?!

2.) New Class Dialog
Is it possible to make CodeLite remember my last choice to use #pragma once?!

3.) Open Folder in explorer
Is there a possibility to add an option to open a folder in the OS file explorer like in Visual Studio C#? Right click => Open Folder in File Explorer?

Questions:
a) Does CodeLite offer a mechanism for program resources?! E.G. I have a project containing images, mp3s etc. in a CodeLite folder (virtual or not) and to copy it to the working directory (debug) without writing a post build batch script?!
b) What is the Explorer for?! To manually drag folders and see the files inside this folder?! i am missing the use case here?!
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: No code completition with using type definition and othe

Post by eranif »

Akronym wrote:CodeLite will give me no code completion for the variable container. I think the problem is the using type def?!
The builtin Code completion is limited and has its limits. To get a full code completion, please enable clang code completion:
http://codelite.org/LiteEditor/ClangIntegration41
Akronym wrote:2.) New Class Dialog
Is it possible to make CodeLite remember my last choice to use #pragma once?!
Please open a bug
Akronym wrote:3.) Open Folder in explorer
Is there a possibility to add an option to open a folder in the OS file explorer like in Visual Studio C#? Right click => Open Folder in File Explorer?
Right click on the file in the explorer and select 'Open containing folder' - this will open Windows Explorer/OSX Finder/Linux file manager and will select the file
Akronym wrote:a) Does CodeLite offer a mechanism for program resources?! E.G. I have a project containing images, mp3s etc
I am not sure I understand what you looking for, can you give an example for such integration in other IDEs?
Akronym wrote:b) What is the Explorer for?! To manually drag folders and see the files inside this folder?! i am missing the use case here?!
Some times you want to open a file which is not part of the workspace (imagine a PHP workspace, but you still want to quickly open Apache's configuration file, or Nginx or... )
The Explorer allows you 'dock' multiple root folders (File->Open->Open Folder) and it also allows you search different root folders (they don't have to have the same parent) quickly and more...

Eran
Make sure you have read the HOW TO POST thread
Akronym
CodeLite Enthusiast
Posts: 15
Joined: Fri Sep 05, 2014 9:02 pm
Genuine User: Yes
IDE Question: c++
Location: Germany
Contact:

Re: No code completition with using type definition and othe

Post by Akronym »

Hi Eran,

thanks for your answer!

1.) Just curious: Why does the clang code completion work this way?! Do I have to assume any drawbacks now, using it with gcc/mingw?!
2.) Okay, I will open a bug/issue
3.) I can't find the menu entry for "Open containing folder", see this screenshot:
Image
"Open with default application" opens Visual Studio 2013.
Edit: if you mean the Explorer tab in CodeLite => This tab is always empty to me. I have to drag the project folder manually into the tab to see something, seems rather awkward to get this feature this way...
Akronym wrote:
a) Does CodeLite offer a mechanism for program resources?! E.G. I have a project containing images, mp3s etc

I am not sure I understand what you looking for, can you give an example for such integration in other IDEs?
I mean to add some resources to the project, that will be copied to the working directory. Similar to Visual Studio C# resources, where you can mark files as Resources and "copy" so these files will be in the same directory as your executable.
In case of a game => Images and soundfiles should be copied to the output directory upon deployment/testing/debugging and I want to manage these resources with CodeLite instead with the OS explorer (for each build config Debug/Release).

And thanks for the explaination for the CodeLite Explorer, makes sense! :)
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: No code completition with using type definition and othe

Post by eranif »

Just curious: Why does the clang code completion work this way?!
Works how? You just need to enable clang code completion and: Workspace->Parse Workspace - Incremental'
Clang is disabled by default, because it consume much more resources (memory) and its slower (but not _that_ slow)
Akronym wrote:.) I can't find the menu entry for "Open containing folder",
You mentioned the "Explorer" not the "Workspace" tab...
Instead, you can right click on an open file's tab and select 'Open Containing Folder'
ocf.png
Eran
You do not have the required permissions to view the files attached to this post.
Make sure you have read the HOW TO POST thread
Akronym
CodeLite Enthusiast
Posts: 15
Joined: Fri Sep 05, 2014 9:02 pm
Genuine User: Yes
IDE Question: c++
Location: Germany
Contact:

Re: No code completition with using type definition and othe

Post by Akronym »

eranif wrote:
Just curious: Why does the clang code completion work this way?!
Works how? You just need to enable clang code completion and: Workspace->Parse Workspace - Incremental'
Clang is disabled by default, because it consume much more resources (memory) and its slower (but not _that_ slow)
I wanted to know what's the difference between normal CC and Clang CC. As you stated it uses much more resources :) If it gets to slow for me, I know what's wrong.
But the Clang CC seems to fire up only after I type a character, but that's okay.
eranif wrote:
Akronym wrote:.) I can't find the menu entry for "Open containing folder",
You mentioned the "Explorer" not the "Workspace" tab...
Instead, you can right click on an open file's tab and select 'Open Containing Folder'
Sorry, I meant the Windows Explorer in this case :/
But okay, thanks, this will do it for me :)

And I guess for project resource files I have to stick with managing them via a Post-Build script and the Windows File Explorer.
Post Reply