Overwrite autocompleted braces, quotes, ...

Let us know what you would like to see in the next version of this software

Moderator: kfury77

Forum rules
Please follow these guidelines when posting feature requests. This will help to increase the value of your contribution.
  • Do not create new topics for already requested features. Add your comments to the existing feature request topics instead;
  • Create separate topic for each feature suggestion. Do NOT post a number of non-related feature suggestions in a single topic;
  • Give your topic a meaningful title. Do NOT create topics with meaningless titles, such as "My Suggestion" or "My Problem".
Please note that we DO READ all suggestions, even if a reply is not posted. Thanks!
Post Reply
Samhayne
Posts: 4
Joined: Mon Oct 26, 2009 1:28 pm

Overwrite autocompleted braces, quotes, ...

Post by Samhayne »

I just downloaded PHP Editor and... I really love it.
For me it's much more usable than the overblasted, Eclipse (*blearch*) based Zend Studio.


A feature I'd really love to see is an overwriting of autocompleted )'s and "'s etc.

Like you have it in Whole Tomato's Visual Assist Plugin for Visual Studio.

You open a brace,

...foo(...

VS adds the closing brace with the cursor in the middle...

...foo(|) ...

you enter the parameter...

...foo(7|) ...

and by closing the brace manually you don't end up with

...foo(7)|) ...

but with

... foo(7)|...

as the closing brace is overwritten.


I think, the logic behind is simple: "You can't add a closing ')' while inside and at the end of two braces. => (bla bla bla bla |)


autocompleted braces and quotation marks are a great thing when entering long expressions...
but when entering short parameters it's (for my brain) much more intuitive to be able to type quickly (-7-) than (-7-END.



---------------------------------------------------------

Another point on my wishlist would be:

I'm an excessive user of autocomplete. :D
Reduced autocomplete delay to 0ms and... it's wonderful.


It would be just nice to see the cursor landing between the braces of a function after autocomplete when the function needs arguments.

massive_foo_function(|) instead of massive_foo_function()|



---------------------------------------------------------

Oh... and one more came in my mind:

No autocomplete while editing inside code.
Most of the time the popping second " is not what I want when editing a line...
User avatar
EvilBMP
Posts: 120
Joined: Thu Jan 04, 2007 1:57 am
Location: Germany

Re: Overwrite autocompleted braces, quotes, ...

Post by EvilBMP »

Samhayne wrote:and by closing the brace manually you don't end up with

...foo(7)|) ...

but with

... foo(7)|...

as the closing brace is overwritten.
+1 for that

Imho, the auto-closing feature really could be pimped, so that a manually inserted closing ' or " or ) or ] or } just overwrites this closing char right next to the cursor. So even if you got used to type the closing char, you wouldn't end up with two closing chars.

I think the overblasted Eclipse ;) does this by the default, if you want to have a look...
Samhayne wrote:It would be just nice to see the cursor landing between the braces of a function after autocomplete when the function needs arguments.

massive_foo_function(|) instead of massive_foo_function()|
+1 from me

Nice idea 8)
Samhayne wrote:No autocomplete while editing inside code.
Most of the time the popping second " is not what I want when editing a line...
Sorry, I don't understand what you are meaning here :|

Greets Evil
x3po
Posts: 139
Joined: Fri May 16, 2008 10:48 am

Re: Overwrite autocompleted braces, quotes, ...

Post by x3po »

+1
Samhayne
Posts: 4
Joined: Mon Oct 26, 2009 1:28 pm

Re: Overwrite autocompleted braces, quotes, ...

Post by Samhayne »

EvilBMP wrote:
Samhayne wrote:No autocomplete while editing inside code.
Most of the time the popping second " is not what I want when editing a line...
Sorry, I don't understand what you are meaning here :|

Greets Evil
Again... I stumble often over autocompleted ""s and ()s when editing a line.

WholeTomato's Visual Assist acts the following way:

When editing a line no closing braces are added when there's a character right of it.

Let's say we have:

foo| x

typing an opening bracer would result in:

foo()| x


with

foo |x

i get:

foo (|x



This comes in handy when you decide so make braces around an expression. Or quotation marks.

Most of the time when editing you wouldn't want
""|Text to put quotation marks around
having to delete the the autocompleted second "

But:
"|Text to put quotation marks around
User avatar
EvilBMP
Posts: 120
Joined: Thu Jan 04, 2007 1:57 am
Location: Germany

Re: Overwrite autocompleted braces, quotes, ...

Post by EvilBMP »

Samhayne wrote:This comes in handy when you decide so make braces around an expression. Or quotation marks.
Nice suggestion - but this should only apply to normal text characters and not to control characters.

Because if I want to send a string to a function or want to get a specific value of an associative array, I really like the auto-complete.
In detail:

Code: Select all

$this->setLog|    // type (
$this->setLog(|)    // type '
$this->setLog('|')

$myArray|    // type [
$myArray[|]    // type '
$myArray['|']
And - as already mentioned - when I type the control character right next to the cursor (because I am used to, and my brain finger coordination has not deleted this behaviour right now), the cursor should jump over it.
in detail:

Code: Select all

$myArray['myKey|']    // type '
$myArray['myKey'|]    // type ]
$myArray['myKey']|
If there is not the same control character to the right, then it should be written - and then also only ones if I want to wrap some string (your suggested expression) or in short, the control structure is still open. But this is working already most of the time if I remember right.
In detail:

Code: Select all

'my tiny string or expression|    // type '
'my tiny string or expression'|
User avatar
Capricorn
Posts: 63
Joined: Fri Aug 06, 2010 11:37 am
Location: Germany!
Contact:

Re: Overwrite autocompleted braces, quotes, ...

Post by Capricorn »

EvilBMP wrote:And - as already mentioned - when I type the control character right next to the cursor (because I am used to, and my brain finger coordination has not deleted this behaviour right now), the cursor should jump over it.
in detail:

Code: Select all

$myArray['myKey|']    // type '
$myArray['myKey'|]    // type ]
$myArray['myKey']|
If there is not the same control character to the right, then it should be written - and then also only ones if I want to wrap some string (your suggested expression) or in short, the control structure is still open. But this is working already most of the time if I remember right.
In detail:

Code: Select all

'my tiny string or expression|    // type '
'my tiny string or expression'|
I know it's a little bit old, but +1 for that because it's not included right now.

I often get things like

Code: Select all

foofunction("sdsasaddad")");
because I'm used to write the end of a function sometimes.

Please add, thanks.

Capricorn
Post Reply