Provide names of arguments with functions

Issue #59 duplicate
Former user created an issue

Originally reported on Google Code with ID 59

I made a small patch to allow adding names to the arguments of a function.
What it does: if you add e.g. abs as a function, it used to write:

abs(

but now it writes:

abs(value) 

and selects the word 'value'. 

Of course it would be necessary to add clear names to the functions, but I
don't understand all of the functions :) so now it just states
'value1;value2;value3'.

I've done some work to allow the TAB key to jump to the different arguments
and select them when you are in a function. But it only works for one
function, as long as you use functions in functions it kinda doesn't work
any more :)
So I'll work on that later maybe, or if someone has an idea how I should do
it proper, let me hear!

The diff is attached of the 'src' directory. I've made it with tortoisesvn.

Reported by deblauwetom on 2007-06-29 07:56:21

<hr> * Attachment: functions.diff

Comments (7)

  1. Former user Account Deleted

    ``` forgot to mention, if you select some text, and then add a function, that text will be used as the first argument in the function. the next argument will then be selected. if your text contains already multiple arguments, no problem, they will be filled in already. ```

    Reported by `deblauwetom` on 2007-06-29 07:59:00

  2. Former user Account Deleted

    ``` oooowké, seems i was a bit too eager, i will try to get it working with all methods of method insertion, now it only works with the functiondock! ```

    Reported by `deblauwetom` on 2007-06-29 16:05:56

  3. Former user Account Deleted

    ``` Thank you, it seems we've got anice idea to explore here. We'll take a look at this for release 0.9. Marking as enhancement. ```

    Reported by `helder.pereira.correia` on 2007-07-01 13:06:50 - Labels added: Type-Enhancement - Labels removed: Type-Defect

  4. Former user Account Deleted

    ``` What I'm working is along this line, but a bit different. This is designed to work nicely even with functions with multiple parameters.

    Instead of inserting the parameter name, I prefer to show a tooltip/popup like in most IDE. For example, when typing "abs(", the pop-up will show "abs(value)" where value is printed in bold.

    For multiple parameters, it's quite useful to highlight (in this case, with bold), the one is about to enter now.

    ```

    Reported by `ariya.hidayat` on 2007-07-02 08:52:09

  5. Former user Account Deleted

    ``` yes, that would be better of course, so it seems you can maybe copy some code from kdevelop or so :)

    So I'll leave it up to you.

    I will maybe now focus on trying to get it working that you press TAB and then you go to the next parameter of a function, and file another issue if I get it working OK. ```

    Reported by `deblauwetom` on 2007-07-02 09:16:13

  6. Former user Account Deleted

    ``` Issue 287 has been merged into this issue. ```

    Reported by `helder.pereira.correia` on 2009-05-07 22:36:20

  7. Former user Account Deleted

    Reported by helder.pereira.correia on 2013-03-14 04:25:01 - Status changed: Duplicate - Merged into: #187

  8. Log in to comment