[Pharo-project] How to browse a selected method in code viewer
When I was using squeak a feature I used alot was the ability to browse a selected method. What I mean is that while browsing a method, if I found a message and wanted to browse its code i could highlight with my mouse (select the text) right click and select "browse" from the menu. This way I did not need to search for the method manually by mouse or use a search field. I am using Pharo 2.0 and I cannot find any such feature in the system browser , am I missing something ?
I don't understand... you do not find it? right click/extend search/browse it (or any of the other possibilities) Esteban On Apr 16, 2013, at 2:11 PM, dimitris chloupis <thekilon@yahoo.co.uk> wrote:
When I was using squeak a feature I used alot was the ability to browse a selected method. What I mean is that while browsing a method, if I found a message and wanted to browse its code i could highlight with my mouse (select the text) right click and select "browse" from the menu. This way I did not need to search for the method manually by mouse or use a search field. I am using Pharo 2.0 and I cannot find any such feature in the system browser , am I missing something ?
Ah ok its in there, i did not see it. Why is it not in top ? its seems very important tool to be in a sub menu. Also I have another issue it does not work always, if I select method and choose browser it does nothing but reopens the right menu, the weird thing is that senders and implementors work fine but also reopen the right click menu. In 90% of the cases does not work. Anyone else having the same issues on Ubuntu 12.10 mad64 ? I dont know if this is a AthensTutorial bug , seems some people have it with even do it. I tried Altbrowser from the configurations tool , changed to it and still get same behavior. -- View this message in context: http://forum.world.st/How-to-browse-a-selected-method-in-code-viewer-tp46818... Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
Le 16/04/2013 14:11, dimitris chloupis a écrit :
When I was using squeak a feature I used alot was the ability to browse a selected method. What I mean is that while browsing a method, if I found a message and wanted to browse its code i could highlight with my mouse (select the text) right click and select "browse" from the menu. This way I did not need to search for the method manually by mouse or use a search field. I am using Pharo 2.0 and I cannot find any such feature in the system browser , am I missing something ?
Gisela is currently implementing / has implemented that for Nautilus. If you want to experiment that, load the ConfigurationOfAltBrowser and try AltBrowser; you don't even need to select, the browser will extend and show you the selector (and then you can choose implementors). There are a few other commands implemented that way (access/rename instance variables). Thierry -- Thierry Goubier CEA list Laboratoire des Fondations des Systèmes Temps Réel Embarqués 91191 Gif sur Yvette Cedex France Phone/Fax: +33 (0) 1 69 08 32 92 / 83 95
what Gisela is doing is smart suggestions: not the same, a lot better :) The function Dimitris is asking for (browse a method imp. accesing with mouse) is already there (it never left), just in a different submenu Esteban On Apr 16, 2013, at 2:21 PM, Goubier Thierry <thierry.goubier@cea.fr> wrote:
Le 16/04/2013 14:11, dimitris chloupis a écrit :
When I was using squeak a feature I used alot was the ability to browse a selected method. What I mean is that while browsing a method, if I found a message and wanted to browse its code i could highlight with my mouse (select the text) right click and select "browse" from the menu. This way I did not need to search for the method manually by mouse or use a search field. I am using Pharo 2.0 and I cannot find any such feature in the system browser , am I missing something ?
Gisela is currently implementing / has implemented that for Nautilus.
If you want to experiment that, load the ConfigurationOfAltBrowser and try AltBrowser; you don't even need to select, the browser will extend and show you the selector (and then you can choose implementors). There are a few other commands implemented that way (access/rename instance variables).
Thierry -- Thierry Goubier CEA list Laboratoire des Fondations des Systèmes Temps Réel Embarqués 91191 Gif sur Yvette Cedex France Phone/Fax: +33 (0) 1 69 08 32 92 / 83 95
On Tue, Apr 16, 2013 at 2:11 PM, dimitris chloupis <thekilon@yahoo.co.uk> wrote:
What I mean is that while browsing a method, if I found a message and wanted to browse its code i could highlight with my mouse (select the text) right click and select "browse" from the menu.
As Esteban says, it is under the "Extended search" submenu. You can also press Alt+m to do the same. -- Damien Cassou http://damiencassou.seasidehosting.st "Success is the ability to go from one failure to another without losing enthusiasm." Winston Churchill
Yes Alt/Command (depending your OS) + m to find implementors and Alt + n to find senders. I found this post from Mariano very usefull http://marianopeck.wordpress.com/2012/05/19/pharo-tips-and-tricks/ And, yes, I'm working in adding smart suggestions and smart menus depending where you have the cursor :). Right now I have a prototype that offers you a small set of actions associated to your selection (a custom menu is displayed with alt + t), but still lot of work is missing. I've sent an email a couple of days before. 2013/4/16 Damien Cassou <damien.cassou@gmail.com>
On Tue, Apr 16, 2013 at 2:11 PM, dimitris chloupis <thekilon@yahoo.co.uk> wrote:
What I mean is that while browsing a method, if I found a message and wanted to browse its code i could highlight with my mouse (select the text) right click and select "browse" from the menu.
As Esteban says, it is under the "Extended search" submenu. You can also press Alt+m to do the same.
-- Damien Cassou http://damiencassou.seasidehosting.st
"Success is the ability to go from one failure to another without losing enthusiasm." Winston Churchill
Gisela how exactly does it work ? because I hover my mouse and nothing happens ? Are there instructions anywhere I can read ? Alt + t does nothing for me . -- View this message in context: http://forum.world.st/How-to-browse-a-selected-method-in-code-viewer-tp46818... Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
There is a better explanation in the thread: SmartSuggestions - Prototype 0 But o short one, first load the prototype: Gofer it smalltalkhubUser: 'gisela' project: 'SmartSuggestions'; package: 'SmartSuggestions'; package: 'SmartSuggestionsNautilus'; load. And then with the cursor (not necessary the mouse position) press ctrl + t (sorry, I was wrong, I changed alt by ctrl the other day) and if there are suggestions for you will appear a menu with the options. Right now it's just a prototype and only offers you: implementors (if you are in a message send), rename (if local variable) and rename, accesses and sotores if it's an instance variable. The menu is opening where the mouse is, it's a work in progress so, if you have any suggestion/bug report/improvements I will be happy to listen about it. Maybe in SmartSuggestions - Prototype 0 thread. 2013/4/16 kilon <thekilon@yahoo.co.uk>
Gisela how exactly does it work ? because I hover my mouse and nothing happens ? Are there instructions anywhere I can read ? Alt + t does nothing for me .
-- View this message in context: http://forum.world.st/How-to-browse-a-selected-method-in-code-viewer-tp46818... Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
ah thank you it works now. Well I am developing a project which I call "Ephestos" its an ide for visual , live coding for 3d graphics , sound and music for pharo. I started it for blender and python but I really enjoy pharo so I decided to port it. I had several ideas , nothing super original , live documentation, live display of implementors and senders with no need of right clicks , menus and such. If you take a look at LightTable it already implements several of my ideas. http://www.chris-granger.com/lighttable/ <http://www.chris-granger.com/lighttable/> if you implement those features then certainly I will be reusing your code. It seems to me that you are very close to those ideas. -- View this message in context: http://forum.world.st/How-to-browse-a-selected-method-in-code-viewer-tp46818... Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
Dammien Alt+m is the implementors, and as i said implementors works for me, however alt+b which is for browsing does nothing. -- View this message in context: http://forum.world.st/How-to-browse-a-selected-method-in-code-viewer-tp46818... Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
On Apr 16, 2013, at 2:35 PM, kilon <thekilon@yahoo.co.uk> wrote:
Dammien Alt+m is the implementors, and as i said implementors works for me, however alt+b which is for browsing does nothing.
strange and how can we know in which class it is? Browse on a selector => should be equivalent to implementors. similarly implementor on a class => browse We lost this cross binding in 20. Stef
On Tue, Apr 16, 2013 at 2:35 PM, kilon <thekilon@yahoo.co.uk> wrote:
Dammien Alt+m is the implementors, and as i said implementors works for me, however alt+b which is for browsing does nothing.
please report on fogbugz with exact steps to reproduce -- Damien Cassou http://damiencassou.seasidehosting.st "Success is the ability to go from one failure to another without losing enthusiasm." Winston Churchill
Is it a bug ? If I select a class and do alt+b it works , if I select the entire message it does not . For example In Athens-Cairo-Paints packages AthensCairoPatternPaint>>intialize in line NBExternalResourceManager addResource: self data: handle. if I select "NBExternalResourceManager" alt+b works and browses the relevant class If I select "NBExternalResourceManager addResource: self data: handle." and hit alt+b it does nothing Is that a bug and can you reproduce that bug ? if yes in both accounts then I am more than happy to create the bug report. -- View this message in context: http://forum.world.st/How-to-browse-a-selected-method-in-code-viewer-tp46818... Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
On Apr 17, 2013, at 11:51 AM, kilon <thekilon@yahoo.co.uk> wrote:
Is it a bug ? If I select a class and do alt+b it works , if I select the entire message it does not . For example
Yes, there is a bug report there already since Apr 9, 2012: https://pharo.fogbugz.com/f/cases/5628/More-permissive-navigation-Shortcuts-... Marcus
Thank you Marcus, good to know its not only me. -- View this message in context: http://forum.world.st/How-to-browse-a-selected-method-in-code-viewer-tp46818... Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
participants (8)
-
Damien Cassou -
dimitris chloupis -
Esteban Lorenzano -
Gisela Decuzzi -
Goubier Thierry -
kilon -
Marcus Denker -
stephane ducasse