[Monodevelop-devel] Refactoring and navigation commands
monoman at gmail.com
Thu Jan 8 08:53:35 EST 2009
Having used Resharper on a previous job, I like that they have it all on the
first-level context menu, but vary the list according to where you are in
the source structure. Taking your example, if you are in a field you can
rename it but not the class it is contained, but you can do some actions on
the class like moving it to another namespace or source-file, I think the
key word is to have commands that are "unequivocally" associated with the
current context OR (exclusive) its containers. If I want to rename a class,
I should position the cursor on its name or, maybe, in first-level
whitespace in it: a blank line inside the class definition block, but not
inside a member's definition block.
Just my 2 cents,
On Thu, Jan 8, 2009 at 5:34 AM, Michael Hutchinson <m.j.hutchinson at gmail.com
> I recently implemented "Go to definition" and "Find references"
> commands as top-level items in the text editor context menu. This
> allows them to be bound to keyboard shortcuts, F12 and Shift-F12.
> However, I haven't committed them yet as I have a few concerns about
> how it relates to the existing refactoring/navigation context menus.
> Currently, MD dynamically generates submenus for the symbol under the
> cursor, and its enclosing/parent items, i.e. the enclosing member, the
> enclosing class, and (if it's a variable) the type. Each of these
> menus allows refactoring and navigation operations on the associated
> There are a few problems with this. Since the submenus are dynamically
> generated, user extensions cannot add new refactoring operations to
> the menu, nor can extensions override the handling of these commands.
> Also, the commands cannot be keybound -- and even if they could, it
> would not be obvious which commands the shortcuts would apply to,
> since the menus contain identical commands.
> So, my question is: are all of the submenus really necessary? How
> useful is it to be able to implement members on a class from the
> context menu on a field within it? What I'd like to do is replace all
> these menus with a simple refactor/navigate menu that would apply only
> to the item under the cursor, as this would be keybindable and
> extensible. However, would it be noticeably less usable or functional?
> Michael Hutchinson
> Monodevelop-devel-list mailing list
> Monodevelop-devel-list at lists.ximian.com
Rafael "Monoman" Teixeira
"I myself am made entirely of flaws, stitched together with good
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Monodevelop-devel-list