Omnibrowser - SystemBrowser - display all methods by default + *class browsing*

Cédrick Béler cbeler at
Wed Jun 27 12:04:58 UTC 2007

>> 1) In the system browser, I'd like to display all methods when selecting
>> a class - Alexandre Bergel posted a cs for that but I can't find it
>> anymore and I can't do it by myself too. Does someone have this change
>> set or can you tell me where to look at... What is the "action" done
>> when selecting a class (probably an announcment related update...) ?
> Everybody want this, but Colin hasn't found a good way of doing it.
ahh... I fell less stupid then ;)

I ended up looking at OBColumn and OBColumnPanel
OBColumn subscribes to 5 OBAnnoucments especially OBSelectionChanged or 
Anyway, I'll see later...
>> 2) also when displaying all methods, I'd like to color each list item
>> according to a category color. Is it feasible ? Can you point me where
>> to look at ?
> I think you should change what OBMethodNode>>label returns or
> something like this. I guess you can return a Text with colors.
Thanks, I'll have a look

Oh and last request,  when OB is enabled by default,   hitting the 
browse shortcut on a class name (in a worspace for instace) doens't work 
for me. The browser is opening with nothing selected.
This is calling the following code wich reproduces for me the same 
problem (opens a browser with no class selected):
OTToolset browse: WAComponent selector: nil.    

Is it normal (maybe I don't have the last version) because browsing a 
class (alt+b) inside OB works... ?

I solved this by adding a test in the following method:

OBSystemBrowserAdaptor>>fullOnClass: aClass selector: aSelector
    aSelector ifNil: [
        ^ OBSystemBrowser
            openOnClass: aClass].
    ^ OBSystemBrowser
        openOnClass: aClass
        selector: aSelector

Last, I couldn't open a browser from the inspector/explorer (same pb - 
empty browser)
I changed (I think here it's more a problem with the ToolSet integration):

    "Create and schedule a full Browser and then select the current 
class and message."

    | myClass |
    (myClass := self selectedClassOrMetaClass) ifNotNil:
        [ToolSet browse: myClass selector: self selectedMessageName.]   
"instead of ....   Browser fullOnClass: myClass selector: self 
selectedMessageName   "

More information about the Squeak-dev mailing list