custom ui theme

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

custom ui theme

Tudor Girba
Hi,

I am trying to tweak a bit the way the splitters are drawn in the  
watery2 theme. So, I created a subclass of UIThemeWatery2 uitheme, and  
I just overrode resizer* and splitter* methods.

However, when I make MyTheme beCurrent, the windows get painted in  
Squeakish colors (blue, green) instead of gray.

I am probably missing something, but I do not know what. What should I  
do to get the gray back?

Cheers,
Doru


--
www.tudorgirba.com

"Presenting is storytelling."


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: custom ui theme

Stan Shepherd
Tudor Girba wrote
Hi,

I am trying to tweak a bit the way the splitters are drawn in the  
watery2 theme. So, I created a subclass of UIThemeWatery2 uitheme, and  
I just overrode resizer* and splitter* methods.

However, when I make MyTheme beCurrent, the windows get painted in  
Squeakish colors (blue, green) instead of gray.

I am probably missing something, but I do not know what. What should I  
do to get the gray back?

Cheers,
Doru
Hi Doru, you might try in

MyTheme class>>newDefaultSettings
     ^super newDefaultSettings standardColorsOnly: true

Seems like you could have overridden an override

Good luck,    ...Stan
Reply | Threaded
Open this post in threaded view
|

Re: custom ui theme

Tudor Girba
Hi,

I did not override this method: MyTheme class>>newDefaultSettings

But, adding the code you mention does not seem to have an effect.

Still confused :).

Cheers,
Doru


On 14 Jan 2010, at 17:44, Stan Shepherd wrote:

>
>
> Tudor Girba wrote:
>>
>> Hi,
>>
>> I am trying to tweak a bit the way the splitters are drawn in the
>> watery2 theme. So, I created a subclass of UIThemeWatery2 uitheme,  
>> and
>> I just overrode resizer* and splitter* methods.
>>
>> However, when I make MyTheme beCurrent, the windows get painted in
>> Squeakish colors (blue, green) instead of gray.
>>
>> I am probably missing something, but I do not know what. What  
>> should I
>> do to get the gray back?
>>
>> Cheers,
>> Doru
>>
>>
>
> Hi Doru, you might try in
>
> MyTheme class>>newDefaultSettings
>     ^super newDefaultSettings standardColorsOnly: true
>
> Seems like you could have overridden an override
>
> Good luck,    ...Stan
>
> --
> View this message in context: http://n2.nabble.com/custom-ui-theme-tp4391907p4393746.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

--
www.tudorgirba.com

"Don't give to get. Just give."




_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: custom ui theme

Gary Chambers-4
You could try sending #resetDefaultSettings to your new theme class,
maybe something odd happened.

The defaults are stored in a class instance variable so each theme can
retain a, potentially user customised, set of settings that will survive
selection between alternate themes.

Had a go doing a subclass myself but encountered no apparent problem
here.

Regards, and good luck,

Gary


On Thu, 2010-01-14 at 21:51 +0100, Tudor Girba wrote:

> Hi,
>
> I did not override this method: MyTheme class>>newDefaultSettings
>
> But, adding the code you mention does not seem to have an effect.
>
> Still confused :).
>
> Cheers,
> Doru
>
>
> On 14 Jan 2010, at 17:44, Stan Shepherd wrote:
>
> >
> >
> > Tudor Girba wrote:
> >>
> >> Hi,
> >>
> >> I am trying to tweak a bit the way the splitters are drawn in the
> >> watery2 theme. So, I created a subclass of UIThemeWatery2 uitheme,  
> >> and
> >> I just overrode resizer* and splitter* methods.
> >>
> >> However, when I make MyTheme beCurrent, the windows get painted in
> >> Squeakish colors (blue, green) instead of gray.
> >>
> >> I am probably missing something, but I do not know what. What  
> >> should I
> >> do to get the gray back?
> >>
> >> Cheers,
> >> Doru
> >>
> >>
> >
> > Hi Doru, you might try in
> >
> > MyTheme class>>newDefaultSettings
> >     ^super newDefaultSettings standardColorsOnly: true
> >
> > Seems like you could have overridden an override
> >
> > Good luck,    ...Stan
> >
> > --
> > View this message in context: http://n2.nabble.com/custom-ui-theme-tp4391907p4393746.html
> > Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
> >
> > _______________________________________________
> > Pharo-project mailing list
> > [hidden email]
> > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
> --
> www.tudorgirba.com
>
> "Don't give to get. Just give."
>
>
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project



_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: custom ui theme

Tudor Girba
Thanks Gary,

Resending #resetDefaultSettings still does not work, but it looks like  
the problem appears only in one of my images where I created this  
code. I loaded the code in another image and it works just as expected.

It could be that the problem is that I executed MyTheme in an  
intermediary step, even before I made it a subclass of UIThemeWatery2,  
and this probably got the system into some unwanted state.

Cheers,
Doru


On 15 Jan 2010, at 01:42, Gary Chambers wrote:

> You could try sending #resetDefaultSettings to your new theme class,
> maybe something odd happened.
>
> The defaults are stored in a class instance variable so each theme can
> retain a, potentially user customised, set of settings that will  
> survive
> selection between alternate themes.
>
> Had a go doing a subclass myself but encountered no apparent problem
> here.
>
> Regards, and good luck,
>
> Gary
>
>
> On Thu, 2010-01-14 at 21:51 +0100, Tudor Girba wrote:
>> Hi,
>>
>> I did not override this method: MyTheme class>>newDefaultSettings
>>
>> But, adding the code you mention does not seem to have an effect.
>>
>> Still confused :).
>>
>> Cheers,
>> Doru
>>
>>
>> On 14 Jan 2010, at 17:44, Stan Shepherd wrote:
>>
>>>
>>>
>>> Tudor Girba wrote:
>>>>
>>>> Hi,
>>>>
>>>> I am trying to tweak a bit the way the splitters are drawn in the
>>>> watery2 theme. So, I created a subclass of UIThemeWatery2 uitheme,
>>>> and
>>>> I just overrode resizer* and splitter* methods.
>>>>
>>>> However, when I make MyTheme beCurrent, the windows get painted in
>>>> Squeakish colors (blue, green) instead of gray.
>>>>
>>>> I am probably missing something, but I do not know what. What
>>>> should I
>>>> do to get the gray back?
>>>>
>>>> Cheers,
>>>> Doru
>>>>
>>>>
>>>
>>> Hi Doru, you might try in
>>>
>>> MyTheme class>>newDefaultSettings
>>>    ^super newDefaultSettings standardColorsOnly: true
>>>
>>> Seems like you could have overridden an override
>>>
>>> Good luck,    ...Stan
>>>
>>> --
>>> View this message in context: http://n2.nabble.com/custom-ui-theme-tp4391907p4393746.html
>>> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>> --
>> www.tudorgirba.com
>>
>> "Don't give to get. Just give."
>>
>>
>>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

--
www.tudorgirba.com

"Problem solving efficiency grows with the abstractness level of  
problem understanding."




_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project