[squeak-dev] Improving the SystemNavigation browseMessageList... stuff

tim Rowledge tim at rowledge.org
Sun Oct 25 23:52:13 UTC 2020



> On 2020-10-24, at 12:13 PM, Thiede, Christoph <Christoph.Thiede at student.hpi.uni-potsdam.de> wrote:
> 
> Hi Tim,
> 
> some scattered comments on your changes: It's a great idea to refactor this windowTitle stuff!
> 
> Personally, I think it would look nicer if you could leave out the spaces between the brackets, e.g. "Implementors of initialize [987]" instead of "Implementors of initialize [ 987 ]".

No argument there.

> 
> Not a regression, but still a bug: Select 42 in some method in a MessageTrace and browse senders -> Error: Instances of SmallInteger are not indexable from #findAgainNow. Is this related to your changes?

No, but certainly a bug. It's related to - I suspect - the problem I noticed in MessageTrace>>#getImplementorNamed: where we find that occasionally the parameter 'selectorSymbol' is actually a Character. Which is indeed not indexable.
*That* seems to stem from TextEditor>>implementorsOfIt where we see that we are using 
```	self selectedLiteral ifNotNil:
		[:aLiteral| ^self model browseAllImplementorsOf: aLiteral].
```
( a change tagged by Marcel about 6 months ago) and in this case aLiteral is the Character [

It's possible the code finding the literal is not working right. It's possible the concept is faulty - should it even try to find all the 'implementors' of something like $[ ?

One of my changes 'fixes' at least part of the problem but I couldn't replicate your exact case.

> 
> > Possibly better to do asOrderedCollection sort ?
> 
> Sounds reasonable.

Yeah, it works and reads better.

> 
> > Now, about that improvement to the Shout stuff...
> 
> Your ideas sound interesting. We have collected so many ideas on what Shout/attributes could do else (ShoutAttribute, highlight searched text, and here are some other rough ideas:


> highlight all occurrences of the currently selected word/selector as you may know it from VS Code;

No. Absolutely no. Nope. Nopetty nope with nope-sauce on top. I've encountered this in the horrific code editor used by WordPress and it is *horrible*. It's also an poorly bounded expense of time. I mean seriously, if you are editing a megabyte file and select 'e' wold it realyl make any sense at all to search out and highlight every damn 'e' ? Madness. Typical 'UI cleverness' from microsoft, the people that wouldn't know a good UI if it bit them on the cerebral cortex.


> automatically style hyperlinks with a TextURL (ask Tom Beckmann for more details on this idea) or class names with a TextLink; a text attribute that adds a tooltip to a certain subtext; allow to browse a word by Ctrl + clicking it, probably again via a text attribute; ...).

This is essentially the data parsing and marking stuff that is used in (amongst others) Apple Mail and can be used to do 'useful things' like spotting a likely appointment to add to your calendar. Again, there are potential performance issues that need careful consideration and there would need to be ways to specify which things get done for each situation - I really don't want time spent on searching for appointments in source code! Also, heavily covered by patents that have been litigated and cost people serious money - I know because I worked on one or two cases.

Given the lack of people screaming to not do it, I'll move a slightly updated version into the trunk and we'll see how it goes.

tim
--
tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
A bad random number generator:  1, 1, 1, 1, 1, 4.33e+67, 1, 1, 1




More information about the Squeak-dev mailing list