[squeak-dev] Merge Request: autoEncloseBeforeSpace.cs

Jakob Reschke jakres+squeak at gmail.com
Thu Dec 23 12:39:33 UTC 2021


Hi,

Am Do., 23. Dez. 2021 um 01:51 Uhr schrieb David T. Lewis <lewis at mail.msen.com>:
>
> Discussion theme #1: Keyboard shortcuts should not do strange and
> unexpected things. Expectations vary, but muscle memory is important.
>

As a matter of fact, modern code editors (e. g. VS Code, Atom,
Brackets) adopt the enclose selection and auto enclose behaviors as
defaults. But one can find debates over it elsewhere, just like it is
a requested feature if it is missing [1][2][3][4][5].

So I do not believe we will be able to agree on the "best" default for
these preferences. Under these circumstances, to not require further
clicks from either group in the future, we should write default
preferences to ~/.config/squeak-default-preferences.dat or so when the
wizard is finished for the first time (and tell the user about it),
and for each fresh image to come, load that before showing the wizard
(and tell the user about it). I believe similar things have already
been proposed multiple times in previous threads. If an error occurs
while reading the file, ignore it and show the wizard with "factory
settings".

Most young people arriving in my team at work naturally start working
on our C codebase with VS Code (rather than with what is recommended
in the Wiki, so it seems to be a general contemporary favorite). So
they may already be used to the enclose behavior from their modern
code editors. When they also encounter it in Squeak they *may* think:
"oh nice, Squeak can do that too." If they do hate it here and there,
I think they will actively seek ways to turn it off. If they did like
it in other editors but never see it in Squeak by default, I believe
it is more likely that they will mistakenly assume that Squeak simply
does not support it. I believe that because Squeak does not have a
reputation of being a state of the art, customizable code editor, as
far as I am aware. (Admittedly, no hard facts in this paragraph.)

That's why I would vote for showing off all the bells and whistles by
default, and make it easy to disable them if they are annoying.
Combined with the automatic loading of preferences defaults, this
could be achieved without bothering our experienced community members
who have already found their preferences and do not want to get
annoyed or do not want to click in the wizard in every new image.

When everything is on by default, another helpful thing for contested
preferences could be a non-interrupting popup in a corner of the world
asking something like: "Did you find that useful? If not you can
disable it in the preferences _here_ ...", which goes away if not used
and does not show up if the preference has already been set
deliberately (e.g. through the defaults file).

If none of this meets endorsement, I will just shrug and continue to
toggle the preferences in the wizard in every new image. I am relaxed
about this one even though I wrote so much text once again. o:-)

Kind regards,
Jakob


[1] https://github.com/microsoft/vscode/issues/34606
[2] https://stackoverflow.com/questions/46470363/disable-automatic-curly-brace-or-bracket-insertion-in-vscode
[3] https://www.reddit.com/r/learnpython/comments/dg16n2/serious_what_is_the_purpose_of_automatically/
[4] https://feedback.textasticapp.com/en/communities/1/topics/591-automatically-balance-brace-and-brackets
[5] https://lists.qt-project.org/pipermail/qt-creator-old/2009-May/003163.html


More information about the Squeak-dev mailing list