|
|
Re: Separate Styling for different Windows [message #1067240 is a reply to message #1067003] |
Sun, 07 July 2013 21:27 |
Jonas Helming Messages: 699 Registered: July 2009 |
Senior Member |
|
|
Hi Tom,
thanks for th suggestion. The problem is that I want to really switch
des thme of windows, not only style the differently, so the selector
work around does not really work. I am aware that the current
implementation does not support this use case. However, I think it
should be possible to rework the CSSEngine to manage the Theme one level
below th display, don't you? AFAIK, the CSSSWTEngine iterates thru all
Shells anyways to apply a new theme, so it could only apply a theme for
a selected one. Do you see any big technical issues with that approach?
Can you imagine to accept a reworked version of the Engine?
You are a good person to have an opinion on that, as you have
implementes the JavaFX version, don't you?
Regards
Jonas
Am 05.07.2013 13:58, schrieb Tom Schindl:
> Themes are a per application and the underlying CSSEngine works on the
> display (see ThemeEngineManager). So without reworking the complete
> CSS-Engine you can't do that.
>
> The only solution is the cascading nature of CSS. You tag windows with
> "windowA"/"windowB" and then you have selectors
>
> ..windowA > * > .MPart {
> background-color: red:
> }
>
>
> ..windowB > * > .MPart {
> background-color: green:
> }
>
> Tom
> On 05.07.13 12:16, Jonas Helming wrote:
>> Hi,
>>
>> for an application I would like to apply separate styles to different
>> windows of the Application. That means, e.g. window A has Theme 1
>> applied and in parallel Window B Theme 2. This use case is currently not
>> supported by the API's of the theme engine and the styling engine.
>> Before I look more detailled into enabnling this: Are there any previous
>> thoughts on this? Would you be willing to accept such as contribution?
>>
>> regards
>> Jonas
>
|
|
|
Re: Separate Styling for different Windows [message #1067255 is a reply to message #1067240] |
Mon, 08 July 2013 06:47 |
Thomas Schindl Messages: 6651 Registered: July 2009 |
Senior Member |
|
|
On 07.07.13 23:27, Jonas Helming wrote:
> Hi Tom,
> thanks for th suggestion. The problem is that I want to really switch
> des thme of windows, not only style the differently, so the selector
> work around does not really work. I am aware that the current
> implementation does not support this use case. However, I think it
> should be possible to rework the CSSEngine to manage the Theme one level
> below th display, don't you? AFAIK, the CSSSWTEngine iterates thru all
> Shells anyways to apply a new theme, so it could only apply a theme for
> a selected one. Do you see any big technical issues with that approach?
> Can you imagine to accept a reworked version of the Engine?
> You are a good person to have an opinion on that, as you have
> implementes the JavaFX version, don't you?
in FX the root of a Stylesheet system is the Scene (and Stage has a
Scene) so there you have what you request. Currently the Theme
implementation provided by e(fx)clipse does not allow what you request
either although the underlying structure (fx-css-engine) would make it
possible.
Tom
|
|
|
|
Powered by
FUDForum. Page generated in 0.02078 seconds