How to prevent SystemWindow from overriding the color of a Morph?

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

How to prevent SystemWindow from overriding the color of a Morph?

Helene Bilbo
Hi,
when i open a Morph via openInWindow in a SystemWindow it's color is overriden by the SystemWindow or the UITheme (i suppose). See attachment for illustration (the Morph is indeed displayed in the Window, but white).

Should i file a bug? Is this a feature? Can i somehow avoid this behaviour?

Best regards, Helene.


Reply | Threaded
Open this post in threaded view
|

Re: How to prevent SystemWindow from overriding the color of a Morph?

Helene Bilbo
Helene Bilbo wrote
when i open a Morph via openInWindow in a SystemWindow it's color is overriden by the SystemWindow or the UITheme (i suppose). See attachment for illustration (the Morph is indeed displayed in the Window, but white).
I found the cause for this behaviour here:

Morph>>initialColorInSystemWindow: aSystemWindow
   "Answer the colour the receiver should be when added to a SystemWindow."
   ^Color white

which is called by:
SystemWindow>>addMorph: aMorph fullFrame: aLayoutFrame

Can anyone explain, why this is here?
Reply | Threaded
Open this post in threaded view
|

Re: How to prevent SystemWindow from overriding the color of a Morph?

Stéphane Ducasse
In reply to this post by Helene Bilbo
It was a kind of feature but should be probably be fixed. propose a fix.

In the past the color of the top level frame was propagated to the submorphs or seomthing like that.
Stef

On Jan 5, 2013, at 1:02 PM, Helene Bilbo wrote:

> Hi,
> when i open a Morph via openInWindow in a SystemWindow it's color is
> overriden by the SystemWindow or the UITheme (i suppose). See attachment for
> illustration (the Morph is indeed displayed in the Window, but white).
>
> Should i file a bug? Is this a feature? Can i somehow avoid this behaviour?
>
> Best regards, Helene.
>
> <http://forum.world.st/file/n4662154/ProblemWithMorphInSystemWindow.png>
>
>
>
>
> --
> View this message in context: http://forum.world.st/How-to-prevent-SystemWindow-from-overriding-the-color-of-a-Morph-tp4662154.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>