The Inbox: ToolBuilder-Morphic-ct.264.mcz

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

The Inbox: ToolBuilder-Morphic-ct.264.mcz

commits-2
A new version of ToolBuilder-Morphic was added to project The Inbox:
http://source.squeak.org/inbox/ToolBuilder-Morphic-ct.264.mcz

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

Name: ToolBuilder-Morphic-ct.264
Author: ct
Time: 17 September 2020, 2:17:24.709813 pm
UUID: f0cb613b-9652-a146-9d77-016577d87700
Ancestors: ToolBuilder-Morphic-mt.263

Initially refresh window color when building a window.

While this also happens later #openInWorld, the call is missing is something else is done with the window instead, e.g. #openInWindow or #imageForm.

=============== Diff against ToolBuilder-Morphic-mt.263 ===============

Item was changed:
  ----- Method: MorphicToolBuilder>>buildPluggableWindow: (in category 'widgets required') -----
  buildPluggableWindow: aSpec
  | widget |
 
  aSpec layout == #proportional ifFalse:[
  "This needs to be implemented - probably by adding a single pane and then the rest"
  ^self error: 'Not implemented'.
  ].
 
  widget := (self windowClassFor: aSpec) new.
  self register: widget id: aSpec name.
 
  widget model: aSpec model.
 
  "Set child dependent layout properties."
  widget wantsPaneSplitters: (aSpec wantsResizeHandles ifNil: [true]).
  self setLayoutHintsFor: widget spec: aSpec.
  widget layoutInset: (aSpec padding ifNil: [ProportionalSplitterMorph gripThickness]).
  widget cellGap: (aSpec spacing ifNil: [ProportionalSplitterMorph gripThickness]).
 
  "Now create the children."
  panes := OrderedCollection new.
  aSpec children isSymbol
  ifTrue: [
  widget getChildrenSelector: aSpec children.
  widget update: aSpec children]
  ifFalse: [
  self buildAll: aSpec children in: widget].
  widget setUpdatablePanesFrom: panes.
 
  aSpec label ifNotNil: [:label|
  label isSymbol
  ifTrue:[widget getLabelSelector: label]
  ifFalse:[widget setLabel: label]].
 
  aSpec multiWindowStyle notNil ifTrue:
  [widget savedMultiWindowState: (SavedMultiWindowState on: aSpec model)].
 
  widget closeWindowSelector: aSpec closeAction.
  self buildHelpFor: widget spec: aSpec.
 
  widget bounds: (RealEstateAgent
  initialFrameFor: widget
  initialExtent: (aSpec extent ifNil:[widget initialExtent])
  world: self currentWorld).
 
+ widget refreshWindowColor.
+
  ^ widget!


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: ToolBuilder-Morphic-ct.264.mcz

marcel.taeumel
So, let's fix it in SystemWindow instead, not here. :-)

Best,
Marcel

Am 17.09.2020 14:17:33 schrieb [hidden email] <[hidden email]>:

A new version of ToolBuilder-Morphic was added to project The Inbox:
http://source.squeak.org/inbox/ToolBuilder-Morphic-ct.264.mcz

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

Name: ToolBuilder-Morphic-ct.264
Author: ct
Time: 17 September 2020, 2:17:24.709813 pm
UUID: f0cb613b-9652-a146-9d77-016577d87700
Ancestors: ToolBuilder-Morphic-mt.263

Initially refresh window color when building a window.

While this also happens later #openInWorld, the call is missing is something else is done with the window instead, e.g. #openInWindow or #imageForm.

=============== Diff against ToolBuilder-Morphic-mt.263 ===============

Item was changed:
----- Method: MorphicToolBuilder>>buildPluggableWindow: (in category 'widgets required') -----
buildPluggableWindow: aSpec
| widget |

aSpec layout == #proportional ifFalse:[
"This needs to be implemented - probably by adding a single pane and then the rest"
^self error: 'Not implemented'.
].

widget := (self windowClassFor: aSpec) new.
self register: widget id: aSpec name.

widget model: aSpec model.

"Set child dependent layout properties."
widget wantsPaneSplitters: (aSpec wantsResizeHandles ifNil: [true]).
self setLayoutHintsFor: widget spec: aSpec.
widget layoutInset: (aSpec padding ifNil: [ProportionalSplitterMorph gripThickness]).
widget cellGap: (aSpec spacing ifNil: [ProportionalSplitterMorph gripThickness]).

"Now create the children."
panes := OrderedCollection new.
aSpec children isSymbol
ifTrue: [
widget getChildrenSelector: aSpec children.
widget update: aSpec children]
ifFalse: [
self buildAll: aSpec children in: widget].
widget setUpdatablePanesFrom: panes.

aSpec label ifNotNil: [:label|
label isSymbol
ifTrue:[widget getLabelSelector: label]
ifFalse:[widget setLabel: label]].

aSpec multiWindowStyle notNil ifTrue:
[widget savedMultiWindowState: (SavedMultiWindowState on: aSpec model)].

widget closeWindowSelector: aSpec closeAction.
self buildHelpFor: widget spec: aSpec.

widget bounds: (RealEstateAgent
initialFrameFor: widget
initialExtent: (aSpec extent ifNil:[widget initialExtent])
world: self currentWorld).

+ widget refreshWindowColor.
+
^ widget!




Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: ToolBuilder-Morphic-ct.264.mcz

Christoph Thiede

Hi Marcel,


#refreshWindowColor depends on #paneColor which in turn depends on the model of the SystemWindow. If we call #refereshWindowColor directly in SystemWindow >> #initialize, the pane color will not match to the model at the end of #buildPluggableWindow:. Is this what we want?


Best,

Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Taeumel, Marcel
Gesendet: Donnerstag, 17. September 2020 16:19:39
An: squeak-dev
Betreff: Re: [squeak-dev] The Inbox: ToolBuilder-Morphic-ct.264.mcz
 
So, let's fix it in SystemWindow instead, not here. :-)

Best,
Marcel

Am 17.09.2020 14:17:33 schrieb [hidden email] <[hidden email]>:

A new version of ToolBuilder-Morphic was added to project The Inbox:
http://source.squeak.org/inbox/ToolBuilder-Morphic-ct.264.mcz

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

Name: ToolBuilder-Morphic-ct.264
Author: ct
Time: 17 September 2020, 2:17:24.709813 pm
UUID: f0cb613b-9652-a146-9d77-016577d87700
Ancestors: ToolBuilder-Morphic-mt.263

Initially refresh window color when building a window.

While this also happens later #openInWorld, the call is missing is something else is done with the window instead, e.g. #openInWindow or #imageForm.

=============== Diff against ToolBuilder-Morphic-mt.263 ===============

Item was changed:
----- Method: MorphicToolBuilder>>buildPluggableWindow: (in category 'widgets required') -----
buildPluggableWindow: aSpec
| widget |

aSpec layout == #proportional ifFalse:[
"This needs to be implemented - probably by adding a single pane and then the rest"
^self error: 'Not implemented'.
].

widget := (self windowClassFor: aSpec) new.
self register: widget id: aSpec name.

widget model: aSpec model.

"Set child dependent layout properties."
widget wantsPaneSplitters: (aSpec wantsResizeHandles ifNil: [true]).
self setLayoutHintsFor: widget spec: aSpec.
widget layoutInset: (aSpec padding ifNil: [ProportionalSplitterMorph gripThickness]).
widget cellGap: (aSpec spacing ifNil: [ProportionalSplitterMorph gripThickness]).

"Now create the children."
panes := OrderedCollection new.
aSpec children isSymbol
ifTrue: [
widget getChildrenSelector: aSpec children.
widget update: aSpec children]
ifFalse: [
self buildAll: aSpec children in: widget].
widget setUpdatablePanesFrom: panes.

aSpec label ifNotNil: [:label|
label isSymbol
ifTrue:[widget getLabelSelector: label]
ifFalse:[widget setLabel: label]].

aSpec multiWindowStyle notNil ifTrue:
[widget savedMultiWindowState: (SavedMultiWindowState on: aSpec model)].

widget closeWindowSelector: aSpec closeAction.
self buildHelpFor: widget spec: aSpec.

widget bounds: (RealEstateAgent
initialFrameFor: widget
initialExtent: (aSpec extent ifNil:[widget initialExtent])
world: self currentWorld).

+ widget refreshWindowColor.
+
^ widget!




Carpe Squeak!