Mantis - Squeak
Viewing Issue Advanced Details
4700 Morphic minor always 09-03-06 18:14 09-06-06 00:33
new 3.10  
0004700: System Window features ( collapse box, expand box, flexing and halos ) need better integration.
See 0004699, 0004677, 0004611 for related reports.

for this one start as in 4699. Get a workspace and tilt it.

Collapse via halo and uncollapse.
This works pretty much as expected.
The Morph collapses to an unflexed system window (Collapse Morph).
The expand box is hidden.
pressing the uncollapse box button restores the workspace to its former position.

Now collapse the tilted workspace by pressing the collapse box button.
as per 4699 the collapsed morph dissappears. It can be found by openning a system menu over the left portion of the screen.

Note that the collapsed morph is tilted and the expand box is still visible.

If we were to press the collapse box the workspace would return to its initial position.

However if at this point we pressed the expand box we get a mess.
The workspace appears somewhere tilted but now expanded to the size of the screen. Or on a limited system the system my hang as too much memory needs to be allowcated to render the now too large workspace.

So a good overhaul or collapse/ uncollapse and expand/unexpand
and probably flex is called for.

The expand box should not ever appear on collapsed morphs. Or should apply to the collapsed morph only.

Tests for all cases need to be writ.
In particular there is a preference for collapsing in place which has be left disabled here and in the above reports.

Collapsing in place is good. However it also means double the testing is needed.

Flexing makes everything more complicated too.

So my suggestion is:

For all non system windows do a collapse to icon ala the enhancements in 4611.
Overhaul the collapse and uncollapse logic to make simpler for system windows.
Collapsed morphs should never have expand boxes. This should be the job of the Collapsed morph creator to enforce.
Flexed morphs should either not have expand boxes or expanding a flexed morph should remove the flex so you get expanded to exactly the full screen not the full screen flexed.
If you choose the latter then the flex probably has to be remembered somewhere so unexpanding will get back the previous state.

child of 0005124new  SystemWindows is ripe for a refactoring. 

09-06-06 00:33   
Further analysis

the more I look into this the more I realize how much System Windows is due for an overhaul. The number of ivars for sys window is huge. Which is one sign of a overall bad smell here.

There has been a lot of code written to get around times when the expand/shrink box is desired not desired. Each works in a limited context. With nothing suggesting itself for easy reuse.

And unfortunately the message #expand itself is being used to mean uncollapse. It has nothing to do with the expand function.

At times like these we should start with the desired story.


what should be:

If an expand box appears in the in the label area then the end result of pressing should be an uncollapsed, untilted full screen version of the window.
the window should remember the last untilted position and extent of its unexpanded size.
And if it was collapsed it should also remember the position to collapse to in the future. (unless we are collapsing in place by preference).

It should integrate well with the close box and collapse box.
It also needs to behave well with the renderers of a tilted window.

As always the user should be allowed to balk ( mouse up outside the button) with out penalty. (i.e. nothing would change.)