Hi, On Wed, Feb 11, 2015 at 6:25 AM, Laura Risani <laura.ris...@gmail.com> wrote:
> > What do you mean about all existing menus in the image? Right now, the >> default Spotter searches for the top level entries in the World menu and >> then lets you dive if you want. It can also be made easily to search for >> all menu entries from the World menu. Is that what you have in mind? >> > > At that moment i thought of searching on all existing menu entries, for > example if Spotter-search for "Browse" menu-category results will include > "Browse scoped" (an entry of a menu you get for classes on the > ClassBrowser). Yet at this moment i'm not sure of how useful it could be. > > >> In this mail alone you list 4 different search tools: Finder, >> MessageBrowser, Spotlight, Search in Nautilus. Each of these behaves >> radically different without much of an added value. >> > >> The whole philosophy of Smalltalk revolves around a minimal and uniform >> model that can be used to express elegantly any action. For example, >> Smalltalk has a simple syntax, and yet you can explain with that simple >> syntax all things for which other languages require lots of hardcoded >> constructs. The same rigor should be applied to the user interface. With >> Spotter we strive to reach such a simple model that can be infinitely >> moldable to fit custom needs. >> >> Now, besides elegance, if any, what else is there? Given that search is >> such a pervasive action, before I start anything I first want to find an >> entry point. That can be a method, a class, a file, or whatever other >> object. To this end, first people think of what tool to use and then of how >> to find the interesting object inside that tool. With Spotter we want to >> eliminate the first step: we just open Spotter and start searching for what >> we want. It's not quite there, but I think it is amazingly close to this >> goal. >> >> > I liked a lot these paragraphs in theirself and also as a motivation for > Spotter. > > 2) Not having the regular features of a window that are useful depending >>> on the case, for shortcuting i would like volatile but for browsing results >>> i could depending on the case prefer persistency . >>> >> >> Certainly. The current solution focuses on search. Creating a persistent >> list of objects is still a work in progress but it is out of scope at the >> moment. >> >> > If at the method GTSpotterGlobalShortcut>>openGlobalSpotter one changes > #openInWorld by #openInWindow , one gets the persistent behavior (it also > includes the preview if opened). > So now i can open a volatile or persistent Spotter, i'm going to have a > keycombination for each one. In addition i get all the regular window > behavior i in some cases want. > This makes me really happy :) > > Only one little keybordian issue, Cmd+w doesn't close the window as usual, > the same happens with GTPlayground. It would be nice if these come > implemented so one doesn't have to add them. > Spotter is not yet meant to be used in a window. The rendering is really not appropriate for that :). Cmd+w should work for Playground. Does it not? Indeed openInWindow does not install the Cmd+W action, but that is morphic specific. > This already works. As explained before, something like: >> d #i >> >> will give you only the implementors of "d". So, # will search for the >> name of the category. This feature is not yet complete in that it does not >> highlight properly the results, but could you try to see if this fits what >> you have in mind? >> > > I've just read about that, and also the last bit on custom categories on > the blog. So now i will define a category for classes+selectors and map a > keycombination to open a volatile Spotter on ti, and remove the 5 results > limit (how do i do this?). This gives me my wanted "selector/class > shortcut" Spotlight provided me, improving the annoying deficiency > Spotlight has of showing no-longer defined names (i asked about it in a > recent mail to the list). > > Having a shortcut (Cmd+Shift+ArrowUp/ArrowDown) to jump through > categories, then why to limit the number of results in each category to 5? > Why not to show them all to avoid the need of going into the category? > Because you still want to have an overview of what is being detected. Spotter should not be optimized for the default pane that is being opened. It has to handle any object. Nevertheless, we do need a more obvious way to show the all items. > Did you try compiling the method that I sent in the previous mail >> (basically just copy paste that method in the GTSpotter class)? It should >> provide the behavior of Spotlight. Please try and let me know if it works >> for you. >> >> > Yes, it works at some degree. > I face this issue, if i type 'openIn' i get only 1/1 selector > #openeningDelimiters, and only if i continue to type 'openInW' i get 5/28 > selectors. > There was a mistake in the algorithm as the matching was case sensitive which is not useful in our case. So, try this: spotterSelectorsFor: aStep <spotterOrder: 0> | processor | processor := aStep listProcessor. processor title: 'Selectors'; filter: [ :originalQuery :stream | |query selectors | query := originalQuery trimBoth asLowercase. query isEmpty ifFalse: [ selectors := Set new. SystemNavigation default allBehaviorsDo: [:class | class selectorsDo:[ :selector | ((selectors includes: selector) not and: [ selector *asLowercase* beginsWith: query ]) ifTrue: [ selectors add: selector. selectors size > 5 ifFalse: [ stream addObject: selector inProcessor: processor ]]]]. selectors ] ]; actLogic: [ :each | self systemNavigation browseAllImplementorsOf: each ] > Also at some point i started to get an #inform: msg saying "WorldState > interCyclePause failed". > As Ben suggested, this is a separate issue. > So additions i would like to see built by default > Cmd+w to close on GTSpotter and GTPlayground. > This works. Could you explain what you do (including the versions and OS you use)? > Remove/know-how-to remove the 5 limit on results. > Every processor is defined in a class extensions annotated with <spotterPreview:>. The processor can specify the limit. Right now, the implementations specify 5 items. You can play with variations. > Selectors category. > You can just install this in your image. That is the whole point of a moldable tool: that you have the power of easily specifying what works for you. Font size configured at SystemBrowser to have effect on GTSpotter both on > search results and preview. > Good point. Could you open a Pharo issue for this one? > To summarize i love Spotter and it will be the tool i use the most (in > number of openings). > You see :) Thanks, Doru > Love, > Laura > > -- www.tudorgirba.com "Every thing has its own flow"