The Trunk: Morphic-mt.1694.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Morphic-mt.1694.mcz

commits-2
Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.1694.mcz

==================== Summary ====================

Name: Morphic-mt.1694
Author: mt
Time: 8 October 2020, 1:33:30.775799 pm
UUID: 3a8e59fb-2478-664c-93e8-131f20222cf0
Ancestors: Morphic-tonyg.1687, Morphic-ct.1693

Merges and tweaks Morphic-ct.1693.

Note that label positioning now works as implemented in system progress bars: #leftCenter for short labels, #topCenter for labels longer than the bar. Do we want to keep it that way or center always?

=============== Diff against Morphic-tonyg.1687 ===============

Item was changed:
  ----- Method: SystemProgressMorph>>reposition (in category 'private') -----
  reposition
+ "Put ourself in the requested position on the display, but ensure completely within the bounds of the display. Compute layout first via #fullBounds to get correct #center."
+
+ self fullBounds.
- "Put ourself in the requested position on the display, but ensure completely within the bounds of the display"
- | position |
  self bounds:
+ ((self bounds
+ align: self center
+ with: (self requestedPosition ifNil: [ self center ]))
+ translatedToBeWithin: self currentWorld bounds).
+
+ "Check to see if labels are wider than progress bars. In that case do a centered instead of the default left aligned layout."
+ self cellPositioning:
+ (self layoutExtent x > BarWidth
+ ifTrue: [ #topCenter ]
+ ifFalse: [ #leftCenter ]).!
- ((self fullBounds
- align: self fullBounds center
- with: (self requestedPosition ifNil: [ self fullBounds center ])) translatedToBeWithin: Display boundingBox).
- "Check to see if labels are wider than progress bars. In that case do
- a centered instead of the default left aligned layout."
- position := self width > (Inset x * 2 + (self borderWidth * 2) + BarWidth)
- ifTrue: [ #topCenter ]
- ifFalse: [ #leftCenter ].
- self cellPositioning: position!