EiffelStudio Completion Tip (2)

by Manu (modified: 2007 Aug 14)

Paul suggested a very nice tip with the wild card completion (new feature of 5.7). I'd like to show that there is an even older feature that is pretty much unknown to many users. It is the routine argument filling facility.

When you complete a routine via the completion dialog, the name of the routine as well as its full signature is inserted in the code. Some complained to us that it was annoying because you ended up having to remove the extra information. But actually there is a very nice thing to do, simply press the Tab key and it automatically selects the first argument, type whatever you want and then press the Tab key to go to the next argument and so on. When you reach the last argument, pressing Tab again will go after the closing parenthesis, pressing it one more will select the whole line and one more time will go back to the first argument.

Comments
  • Peter Gummer (10 years ago 14/8/2007)

    Nice Tip!

    Yes, I really like this feature. I didn't realise it was an old feature because I only happened to discover it in 6.0!

    I had an experience with it the other day. Another developer had dozens of calls, one after the other, to extend a HASH_TABLE. The developer had used tabs to line up the second argument, so that they all lined up nicely underneath each other. Now this is something I used to do a long time ago, because it looks nice; but experience has taught me that it's more trouble than it's worth because, as the code changes over time, the nice columns become a mess and tidying them up is more trouble than it's worth. Well I was trying to tidy it up after I had made a change, but I couldn't insert a tab because it kept highlighting the second argument!

    I deleted the tabs, and just left one space before the argument. I like EiffelStudio's tab-to-argument feature just as it is.