Autocomplete/Parameter Choices provider

Questions on using RSyntaxTextArea should go here.

Moderator: robert

Autocomplete/Parameter Choices provider

Postby Bryan » Mon Jul 08, 2013 6:10 pm

Hi I am working with setting the parameter choices provider and I'm not sure whether I've encountered a bug or intended behavior. I invoke code completion for a function with multiple parameters and for each parameter I see the parameter choices appearing as expected. I use the up/down arrow key to navigate the parameter choices. When I select a parameter choice with the ENTER key the 1st parameter is correctly filled in with my choice and the highlight advances to the next parameter however the parameter choices disappear for the second parameter. Is this intended?

Also is code completion smart enough to detect the typing of an open parenthesis (specified in my parameterized completion params),read the token to the left and show the code completion prompts for that function, or is that behavior custom code I would have to write (and is there any examples?). I don't want to unfairly expect out of the box behavior identical to eclipse but I just want to understand where I would need to implement custom code for eclipse-like autocomplete functionality and not reinvent the wheel. Thanks!
Posts: 3
Joined: Mon Mar 25, 2013 8:25 pm

Re: Autocomplete/Parameter Choices provider

Postby robert » Fri Jul 12, 2013 1:16 pm

Hi Bryan,

For the first issue, I'm guessing you want the parameter choices popup displayed for the second parameter right as it's focused after completing the first parameter? That's a reasonable request, I'll take a look. I'm assuming you can still Ctrl+Space to manually make it appear though, right?

For your second question, currently it should enter parameter completion mode (don't know if there are "real" names for these things, so bear with me!) when you type an open paren, if you had the completion choices popup window already open. e.g. if in C, you typed "p", hit Ctrl+Space, then typed "rintf(". In this mode, you can cycle through the parameters to the function or method with tab/shift+tab, like Eclipse, and the dropdown for function parameter choices completion is made visible for any parameters for which there are choices to choose from. At least, that's how it appears to work with the stuff built into the RSTALanguageSupport library. Is this the behavior you're seeing? If not, I can try to see if there is some magic going on there in RSTALanguageSupport to make it work.
User avatar
Posts: 760
Joined: Sat May 10, 2008 5:16 pm

Return to Help

Who is online

Users browsing this forum: No registered users and 2 guests