# How to disable window shadow globally?

dastultz
797 8

I've run in to a problem with datebox and the shadow from the calendar sticking around. I'll detail that later. I've also found another problem with moving windows that involves the shadow. Is there a way to turn off window shadows globally as a temporary workaround to the problems I'm seeing?

/Daryl

delete retag edit

## 9 Replies

jumperchen
3909 2 8
http://jumperchen.blogspo...

Hi,
you can use a lang-addon.xml to specify the window with disabled shadow.

/Jumper

dastultz
797 8

I tried this:

<component>
<component-name>window</component-name>
<extends>window</extends>
<property>
<property-value>false</property-value>
</property>
</component>


This works:

<window shadow="false">...</window>

but there doesn't seem to be any property "shadow" of org.zkoss.zul.Window. How do I disable the shadow of a Window from Java?

/Daryl

jumperchen
3909 2 8
http://jumperchen.blogspo...

Have you specified the lang-addon.xml into zk.xml too?
From Java code, you can use the method "setShadow()" of Window.

/Jumper

dastultz
797 8

Yes, I edited an existing lang-addon.xml for which other components are working fine. There is no such method "setShadow()" of Window.

This works:

	<window visible="false" closable="true" id="win1" border="normal">
<caption label="Test" />
<label>...</label>
</window>
<zscript>
</zscript>


But this in Java won't compile:

Window win = new Window("Stuff", "normal", true);
win.setPage(page);


How is that possible?

/Daryl

jumperchen
3909 2 8
http://jumperchen.blogspo...

Which zk version did you use?

/Jumper

dastultz
797 8

I am using ZK 3.6.1.FL.

/Daryl

dastultz
797 8

It looks like a build path problem. It seems I got my links mixed up. Sorry about that. I can't seem to find the FL downloads. I'm pretty sure I downloaded a FL after 3/23 (4/23) but the 3/23FL is the only zip file I can find on my local system. I tried to download the latest FL from the web site but I just see some jspTags stuff. Where's the Freshly download page?

/Daryl

dastultz
797 8

Ok, setShadow() works from Java but the lang-addon above does not. Is it because I'm using Java and not ZUL? I'm using xul/html as the language-name. Is there something else I should be using? Ultimately I'm looking for a workaround to bug #2779599 which you don't seem to want to fix. I need a way to disable shadows on all windows so I can drag them around in Mac/FF.

/Daryl

yayatip
12

I am also looking solution for this? Anyone has a workaround to disable shadows in the application?

[hide preview]