You are not logged in.

Dear visitor, welcome to KDE-Forum.org. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

EvilGuru

Beginner

  • "EvilGuru" started this thread

Posts: 5

Location: Uk

Occupation: Student

  • Send private message

1

Saturday, January 14th 2006, 4:24pm

KDevelop -- Code Completion

Does KDevelop support intelligent code completion like that of Visual Studio or Xcode. Currently I have only found a option to turn on a code completion like thing (just looks though the open document for possible matches to what I am typing). I Visual Studio and Xcode the code completion looks at my current file and and all of its include files, parses them and then builds up a completion tree. So, if my 'struct' has two elements:

Source code

1
2
3
4
5
struct test
{
int a;
float b;
};

And in a function I create a new test struct variable called cheese and then type 'cheese.' it will come up with a drop down menu saying 'a' and 'b' with icons to indicate what the variable type is (e.g. float/int/char). When I type part of a function and let it complete the rest for me I will do something like:
function_name(<# char a #>, <# int c #>) and then by pressing 'Ctrl+/' it will go between each '<# ... #>' block, highlighting it for me. These features really do save time and I want to know if they are available in KDevelop either by default or though a plugin of some sort.
Thanks for all of your help.

2

Sunday, February 5th 2006, 3:48am

project > project options
c++ specific
code completion (it's a tab tab)

I'ts not quite as good as Visual Studio's, but still quite helpful.

EvilGuru

Beginner

  • "EvilGuru" started this thread

Posts: 5

Location: Uk

Occupation: Student

  • Send private message

3

Sunday, February 5th 2006, 7:12pm

I have enabled it on my C project, but it seems to be more annoying than useful. The code completion only seems to work for variables and not functions, and even then it is rather well 'dumb' as in it does not know anything about what it is completing. Also when typing comments whenever I type a letter I get an army of code completion options come up, which is not only totally useless (this is a comment people) but also annoying. Not what I have come to expect from a 'K' branded application.

The developers really need to try out Visual Studio, Eclipse or Xcode and play around with the code completion. As the current KDevelop one is like the text-autocomplete plugin for Kate, except it only pops up with variables to auto-complete and not random words from the document.

Or, it is quite possible that I am not doing something correctly (I did follow the FAQ entry to the letter) and if so I take back what I have said, however as far as I can tell that does not appear to be the case. If advanced and intelligent code completion is not already a planned feature for a new version, or in a wish-list somewhere then it definitely should be.

Olex

Beginner

Posts: 2

Location: Ukrainian in Kentucky, US

Occupation: College Student

  • Send private message

4

Sunday, March 5th 2006, 9:43pm

It is true that KDevelop uses source navigation tool that has some problems. I've been using KDevelop with its source navigation for a couple of years. From my experience, source nav. does work. It seems it need time to pick stuff up (usually after compilation of a new file, Ctags rerun, etc.)

Overall, however, i've found it to be useful nonetheless. 8) (I would even argue that it is better than VC8 default source navigator)