[squeak-dev] Review Request: fix-preference-browser-overflow.1.cs

Marcel Taeumel marcel.taeumel at hpi.de
Thu Jun 16 09:53:05 UTC 2022


Hi Christoph --

I don't like the reason you provide for changing the title of that preference. This kind of change is not maintainable in the long term. So, you drop the information "tool" for some highly fragile UI optimization. This is not okay. Next time somebody increases the width of that input field for #String, your change becomes void again.

Also, you even increased the #initialExtent. So you made two very different changes to tackle the same problem. Why not just increase the #initialExtent only to support this very configuration of preferences we have at the moment? This is not maintainable.

Your choice but this is a clear -1 from my side.

Best,
Marcel
Am 16.06.2022 11:34:12 schrieb christoph.thiede at student.hpi.uni-potsdam.de <christoph.thiede at student.hpi.uni-potsdam.de>:
=============== Summary ===============

Change Set:        fix-preference-browser-overflow
Date:            16 June 2022
Author:            Christoph Thiede

Fixes default width of preference browser. The new preference 'RealEstateAgent windowScaleFactor' had such a long name that it did not fit into the standard width. Shorten the name and extend the initial window extent so that selecting the preference does no longer offsets all items in the list.

Note that this is only a quick-fix and might fail again once you change your screen size or fonts. In the long term, it would be nicer if we had something like StringMorph >> #maxWidth: for this (maybe even with an automatic ellipsis ...).

=============== Diff ===============

PreferenceBrowser>>initialExtent {user interface} · ct 6/16/2022 11:24 (changed)
initialExtent
    "Scale here because the receiver is not built through a tool builder. See #buildPluggableWindow:."
    
-     ^ (660 at 440 * RealEstateAgent scaleFactor) rounded
+     ^ (705 @ 440 * RealEstateAgent scaleFactor) rounded

RealEstateAgent class>>windowScaleFactor {preferences} · ct 6/16/2022 11:23 (changed)
- windowScaleFactor
-     <preference: 'Scale Factor for Default Extent of Tool Windows'
+ windowScaleFactor
+     <preference: 'Scale Factor for Default Window Extent'
        categoryList: #(Morphic Tools Accessibility)
-         description: 'The extent of tool windows is tweaked for a world extent of 1024 at 768 (or its scaled equivalent). If you have a larger screen available, you might want to increase a tool''s default extent. Note that you can also increase the system''s overall scale factor instead.'
+         description: 'The extent of windows is tweaked for a world extent of 1024 at 768 (or its scaled equivalent). If you have a larger screen available, you might want to increase a tool''s default extent. Note that you can also increase the system''s overall scale factor instead.'
        type: #String>
    ^ WindowScaleFactor ifNil: [1.0]

["fix-preference-browser-overflow.1.cs"]

---
Sent from Squeak Inbox Talk [https://github.com/hpi-swa-lab/squeak-inbox-talk]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20220616/3638f337/attachment.html>


More information about the Squeak-dev mailing list