Missing context actions on longer lines of code (v3 & 3.1)

There has been an annoying problem that I have encountered ever since version 3.0 came out with respect to context actions. Is seems that for lines of code that are longer, context actions that should be showing up do not. A have attached a sample solution to illustrate the problem. In my sample solution, you will see I have a class defined like so:

namespace MissingContextActions
{
public class MyClassWithAReallyReallyLongName : IDisposable
{

}
}

If I place my cursor over the IDisposable, I should get a context action to impliment the interface, but I do not. If I move the cursor to the left (over the class name), then it will show up. One interesting thing that I realized is that if I decrease my font size, then it will show up over the interface name.

The other example of this in the solution is this:

namespace MissingContextActions
{
public class MyHttpModule : IHttpModule
{
public virtual void Dispose()
{

}

public virtual void Init(HttpApplication application)
{
application.PostResolveRequestCache += new EventHandler(this.OnApplicationPostResolveRequestCache);
}

private void OnApplicationPostResolveRequestCache(object sender, EventArgs e)
{
//do something
}
}
}

Note the "new EventHandler" is greyed out, and if I decrease my font size, I can put my cursor over it and it will give me a context action to remove the redundent code. Also, I found that instead of decreasing my font size, if I rename the application variable to app, then the context action will show up if my cursor is over the first 4 or 5 charcters of the greyed out code, but not if it is further to the right. Its like the context actions will only work if the cursor is a certain number of pixels from the left of the typing canvas.

My current font settings are Inconsolata 13pt. However, I can reproduce this by setting it to Courier New 12pt as well.

This was not a problem with version 2.5 and is something that was introduced with 3.0 (including the most recent nightly build). A fix would be most appreciated as I find context actions as one of the most useful features of ReSharper and not having them in some instances severely cripples a great product.

~Andy Alm



Attachment(s):
MissingContextActions.zip
7 comments
Comment actions Permalink

Is there any word on this? Surely there are other people who have encountered
this? Should I file a bug in the issue tracker?

~Andy

There has been an annoying problem that I have encountered ever since
version 3.0 came out with respect to context actions. Is seems that
for lines of code that are longer, context actions that should be
showing up do not. A have attached a sample solution to illustrate
the problem. In my sample solution, you will see I have a class
defined like so:

namespace MissingContextActions
{
public class MyClassWithAReallyReallyLongName : IDisposable
{
}
}
If I place my cursor over the IDisposable, I should get a context
action to impliment the interface, but I do not. If I move the cursor
to the left (over the class name), then it will show up. One
interesting thing that I realized is that if I decrease my font size,
then it will show up over the interface name.

The other example of this in the solution is this:

namespace MissingContextActions
{
public class MyHttpModule : IHttpModule
{
public virtual void Dispose()
{
}

public virtual void Init(HttpApplication application)
{
application.PostResolveRequestCache += new
EventHandler(this.OnApplicationPostResolveRequestCache);
}
private void OnApplicationPostResolveRequestCache(object sender,
EventArgs e)
{
//do something
}
}
}
Note the "new EventHandler" is greyed out, and if I decrease my font
size, I can put my cursor over it and it will give me a context action
to remove the redundent code. Also, I found that instead of
decreasing my font size, if I rename the application variable to app,
then the context action will show up if my cursor is over the first 4
or 5 charcters of the greyed out code, but not if it is further to the
right. Its like the context actions will only work if the cursor is a
certain number of pixels from the left of the typing canvas.

My current font settings are Inconsolata 13pt. However, I can
reproduce this by setting it to Courier New 12pt as well.

This was not a problem with version 2.5 and is something that was
introduced with 3.0 (including the most recent nightly build). A fix
would be most appreciated as I find context actions as one of the most
useful features of ReSharper and not having them in some instances
severely cripples a great product.

~Andy Alm



0
Comment actions Permalink

Do you use TrueType font in editor or not?

Such problems occurs when non-TTF font is used

--
Eugene Pasynkov
Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
"Andy Alm" <andyalm@hotmail.com> wrote in message
news:e91e0d4d0a748ca41cc4178965a@news.jetbrains.com...
There has been an annoying problem that I have encountered ever since
version 3.0 came out with respect to context actions. Is seems that for
lines of code that are longer, context actions that should be showing up do
not. A have attached a sample solution to illustrate the problem. In my
sample solution, you will see I have a class defined like so:

namespace MissingContextActions
{
public class MyClassWithAReallyReallyLongName : IDisposable
{

}
}

If I place my cursor over the IDisposable, I should get a context action to
impliment the interface, but I do not. If I move the cursor to the left
(over the class name), then it will show up. One interesting thing that I
realized is that if I decrease my font size, then it will show up over the
interface name.

The other example of this in the solution is this:

namespace MissingContextActions
{
public class MyHttpModule : IHttpModule
{
public virtual void Dispose()
{

}

public virtual void Init(HttpApplication application)
{
application.PostResolveRequestCache += new
EventHandler(this.OnApplicationPostResolveRequestCache);
}

private void OnApplicationPostResolveRequestCache(object sender, EventArgs
e)
{
//do something
}
}
}

Note the "new EventHandler" is greyed out, and if I decrease my font size, I
can put my cursor over it and it will give me a context action to remove the
redundent code. Also, I found that instead of decreasing my font size, if I
rename the application variable to app, then the context action will show up
if my cursor is over the first 4 or 5 charcters of the greyed out code, but
not if it is further to the right. Its like the context actions will only
work if the cursor is a certain number of pixels from the left of the typing
canvas.

My current font settings are Inconsolata 13pt. However, I can reproduce
this by setting it to Courier New 12pt as well.

This was not a problem with version 2.5 and is something that was introduced
with 3.0 (including the most recent nightly build). A fix would be most
appreciated as I find context actions as one of the most useful features of
ReSharper and not having them in some instances severely cripples a great
product.

~Andy Alm


0
Comment actions Permalink

Hello Eugene,

My default font is an OpenType font (Inconsolata), however, as I mentioned
in my original email, I am also able to reproduce this using the Courier
New font, which is a TrueType font. ReSharper 2.5 does not have this problem.

~Andy

Do you use TrueType font in editor or not?

Such problems occurs when non-TTF font is used

namespace MissingContextActions
{
public class MyClassWithAReallyReallyLongName : IDisposable
{
}
}
If I place my cursor over the IDisposable, I should get a context
action to impliment the interface, but I do not. If I move the cursor
to the left (over the class name), then it will show up. One
interesting thing that I realized is that if I decrease my font size,
then it will show up over the interface name.

The other example of this in the solution is this:

namespace MissingContextActions
{
public class MyHttpModule : IHttpModule
{
public virtual void Dispose()
{
}

public virtual void Init(HttpApplication application)
{
application.PostResolveRequestCache += new
EventHandler(this.OnApplicationPostResolveRequestCache);
}
private void OnApplicationPostResolveRequestCache(object sender,
EventArgs
e)
{
//do something
}
}
}
Note the "new EventHandler" is greyed out, and if I decrease my font
size, I can put my cursor over it and it will give me a context action
to remove the redundent code. Also, I found that instead of
decreasing my font size, if I rename the application variable to app,
then the context action will show up if my cursor is over the first 4
or 5 charcters of the greyed out code, but not if it is further to the
right. Its like the context actions will only work if the cursor is a
certain number of pixels from the left of the typing canvas.

My current font settings are Inconsolata 13pt. However, I can
reproduce this by setting it to Courier New 12pt as well.

This was not a problem with version 2.5 and is something that was
introduced with 3.0 (including the most recent nightly build). A fix
would be most appreciated as I find context actions as one of the most
useful features of ReSharper and not having them in some instances
severely cripples a great product.

~Andy Alm



0
Comment actions Permalink

What is the status of this? Do I need to enter an issue in the JIRA tracker?
Surely other people are having this problem too? Is there someone else
who has encountered this?

I don't buy the TrueType vs non-TrueType font thing because I reproduce it
with both types of fonts.

Hello Eugene,

My default font is an OpenType font (Inconsolata), however, as I
mentioned in my original email, I am also able to reproduce this using
the Courier New font, which is a TrueType font. ReSharper 2.5 does
not have this problem.

~Andy

>> Do you use TrueType font in editor or not?
>>
>> Such problems occurs when non-TTF font is used
>>
>> namespace MissingContextActions
>> {
>> public class MyClassWithAReallyReallyLongName : IDisposable
>> {
>> }
>> }
>> If I place my cursor over the IDisposable, I should get a context
>> action to impliment the interface, but I do not. If I move the
>> cursor
>> to the left (over the class name), then it will show up. One
>> interesting thing that I realized is that if I decrease my font size,
>> then it will show up over the interface name.
>> The other example of this in the solution is this:
>>
>> namespace MissingContextActions
>> {
>> public class MyHttpModule : IHttpModule
>> {
>> public virtual void Dispose()
>> {
>> }
>> public virtual void Init(HttpApplication application)
>> {
>> application.PostResolveRequestCache += new
>> EventHandler(this.OnApplicationPostResolveRequestCache);
>> }
>> private void OnApplicationPostResolveRequestCache(object sender,
>> EventArgs
>> e)
>> {
>> //do something
>> }
>> }
>> }
>> Note the "new EventHandler" is greyed out, and if I decrease my font
>> size, I can put my cursor over it and it will give me a context
>> action
>> to remove the redundent code. Also, I found that instead of
>> decreasing my font size, if I rename the application variable to app,
>> then the context action will show up if my cursor is over the first 4
>> or 5 charcters of the greyed out code, but not if it is further to
>> the
>> right. Its like the context actions will only work if the cursor is
>> a
>> certain number of pixels from the left of the typing canvas.
>> My current font settings are Inconsolata 13pt. However, I can
>> reproduce this by setting it to Courier New 12pt as well.
>>
>> This was not a problem with version 2.5 and is something that was
>> introduced with 3.0 (including the most recent nightly build). A fix
>> would be most appreciated as I find context actions as one of the
>> most useful features of ReSharper and not having them in some
>> instances severely cripples a great product.
>>
>> ~Andy Alm
>>


0
Comment actions Permalink

You definitely should create corresponding request in JIRA tracker.

Personally, I've seen this effect only with non-TTF fonts

--
Eugene Pasynkov
Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
"Andy Alm" <andyalm@hotmail.com> wrote in message
news:e91e0d4d0cf38ca4cdeee7e8b86@news.jetbrains.com...

What is the status of this? Do I need to enter an issue in the JIRA
tracker? Surely other people are having this problem too? Is there
someone else who has encountered this?

>

I don't buy the TrueType vs non-TrueType font thing because I reproduce it
with both types of fonts.

>
>> Hello Eugene,
>>
>> My default font is an OpenType font (Inconsolata), however, as I
>> mentioned in my original email, I am also able to reproduce this using
>> the Courier New font, which is a TrueType font. ReSharper 2.5 does
>> not have this problem.
>>
>> ~Andy
>>
>>> Do you use TrueType font in editor or not?
>>>
>>> Such problems occurs when non-TTF font is used
>>>
>>> namespace MissingContextActions
>>> {
>>> public class MyClassWithAReallyReallyLongName : IDisposable
>>> {
>>> }
>>> }
>>> If I place my cursor over the IDisposable, I should get a context
>>> action to impliment the interface, but I do not. If I move the
>>> cursor
>>> to the left (over the class name), then it will show up. One
>>> interesting thing that I realized is that if I decrease my font size,
>>> then it will show up over the interface name.
>>> The other example of this in the solution is this:
>>>
>>> namespace MissingContextActions
>>> {
>>> public class MyHttpModule : IHttpModule
>>> {
>>> public virtual void Dispose()
>>> {
>>> }
>>> public virtual void Init(HttpApplication application)
>>> {
>>> application.PostResolveRequestCache += new
>>> EventHandler(this.OnApplicationPostResolveRequestCache);
>>> }
>>> private void OnApplicationPostResolveRequestCache(object sender,
>>> EventArgs
>>> e)
>>> {
>>> //do something
>>> }
>>> }
>>> }
>>> Note the "new EventHandler" is greyed out, and if I decrease my font
>>> size, I can put my cursor over it and it will give me a context
>>> action
>>> to remove the redundent code. Also, I found that instead of
>>> decreasing my font size, if I rename the application variable to app,
>>> then the context action will show up if my cursor is over the first 4
>>> or 5 charcters of the greyed out code, but not if it is further to
>>> the
>>> right. Its like the context actions will only work if the cursor is
>>> a
>>> certain number of pixels from the left of the typing canvas.
>>> My current font settings are Inconsolata 13pt. However, I can
>>> reproduce this by setting it to Courier New 12pt as well.
>>>
>>> This was not a problem with version 2.5 and is something that was
>>> introduced with 3.0 (including the most recent nightly build). A fix
>>> would be most appreciated as I find context actions as one of the
>>> most useful features of ReSharper and not having them in some
>>> instances severely cripples a great product.
>>>
>>> ~Andy Alm
>>>
>



0
Comment actions Permalink

Hello,

We appreciate your feedback. The corresponding JIRA request has been created,
and you are welcome to monitor its status at http://www.jetbrains.net/jira/browse/RSRP-60492.

You may want to check our request tracking policy here: http://www.jetbrains.net/confluence/display/ReSharper/ReSharperIssueTracker

Best regards,
- Development Team.


0
Comment actions Permalink

Andy

I've noticed this too. At first I thought it was just me...
It seems to be related to the width of the window, as if I have two vertical tab groups open then it happens more often. (I use Dina programming font, which isn't TrueType).

0

Please sign in to leave a comment.