space after switch label
Hi all,
I am feeling a bit spoiled asking this question, as Resharper is such a
great program that really takes a lot of work off my hands.
The auto-generating facility of generating switch labels is very handy, but
unfortunately there is no option to insert a space between the label and the
colon.
Is it possible to include this in a next build?
Regards,
Patrick
Please sign in to leave a comment.
This will be implemented in version 2.0
--
Eugene Pasynkov
Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
"Patrick" <patrick@nospam.com> wrote in message
news:d45dm0$qkm$1@is.intellij.net...
>
>
but
the
>
>
>
>
>
Great!
Looking forward to it.
Patrick
"Eugene Pasynkov (JetBrains)" <Eugene.Pasynkov@jetbrains.com> wrote in
message news:d45h0h$bkn$1@is.intellij.net...
>
>> Hi all,
>>
>> I am feeling a bit spoiled asking this question, as Resharper is such a
>> great program that really takes a lot of work off my hands.
>>
>> The auto-generating facility of generating switch labels is very handy,
>> unfortunately there is no option to insert a space between the label and
>> colon.
>>
>> Is it possible to include this in a next build?
>>
>> Regards,
>>
>> Patrick
>>
>>
>
"Patrick" <patrick@nospam.com> wrote in message
news:d45dm0$qkm$1@is.intellij.net...
>
Hi Patrick & all...
I'm a ReSharper newbie and agree that automatically generating switch cases
would be extremely handy, but I can't get ReSharper to co-operate!
Can you tell me where to find it / how to use it? (I'm using build 163).
Thanks!
btw: I'm loving this product more every day. Can't wait for 2.0...
cheers,
Rohan.
>> The auto-generating facility of generating switch labels is very
>> handy, but unfortunately there is no option to insert a space between
>> the label and the colon.
>>
Hello Rohan,
If you create switch on a variable of a enum type:
enum SomeEnum { VAL1, VAL2, VAL3, VAL4, .. }
..
SomeEnum e = 0;
..
switch (e)
{
}
ReSharper can help you to create switch labels in two ways:
1. You can use smart competion (CtrlShiftSpace) after typing each "case
". The completion will suggest labels SomeEnum.VAL1, SomeEnum.VAL2, etc.
2. If enum has not too many items, and nothing is typed inside switch, you
can use a quick fix (click on the lightbulb, or press Alt+Enter) "Generate
case labels" while caret is standing on "Empty switch block" error highlighting
(that is, on the closing brace of the switch block). ReSharper will generate
labels with breaks for all enum members.
Thanks,
Andrey Simanovsky
Beautiful! Thanks for that, Andrey.
cheers,
Rohan.
"Andrey Simanovsky (JetBrains)" <ands@intellij.com> wrote in message
news:33937632497000906751716@news.intellij.net...
>> "Patrick" <patrick@nospam.com> wrote in message
>> news:d45dm0$qkm$1@is.intellij.net...
>>
>>> The auto-generating facility of generating switch labels is very
>>> handy, but unfortunately there is no option to insert a space between
>>> the label and the colon.
>>>
>> Hi Patrick & all...
>>
>> I'm a ReSharper newbie and agree that automatically generating switch
>> cases
>> would be extremely handy, but I can't get ReSharper to co-operate!
>> Can you tell me where to find it / how to use it? (I'm using build
>> 163).
>> Thanks!
>> btw: I'm loving this product more every day. Can't wait for 2.0...
>>
>> cheers,
>> Rohan.
>
>
>
>
>
>