##The Current Window
All Titanium windows are UI.UserWindow objects. Code running in context of an HTML page can easily access the current window:
From there it is easy to modify the window at will:
All Titanium applications have an initial window, which can be set up in the tiapp.xml file (check out KitchenSink's tiapp.xml file or the guide. Once a window has been opened, it can be closed once, freeing its resources and can never be opened again. If you'd just like to hide a window, try the following:
Most window properties can be changed:
Some properties can only be changed before a window is originally open though. In particular, a window may only change its use of chrome before it is opened.
There are two types of transparency in Titanium. Full window transparency specified with the transparency property and background transparency specified with the transparent-background property.
###The Transparency Setting
The transparent element should contain a value between 0.0 and 1.0 and specifies the opacity of the total window. A window with a transparency value of 0.7 would look like:
The transparency setting of a window can be modified after it has been opened. The following example will cause the new window to fade away when closed:
###The Transparenct Background Setting
The transparent-background property specifies that the WebView in a window has a background which is transparent. Elements in the WebView may specify different opacities to create non-rectangular windows. Here is an example of a non-rectangular Titanium window with a transparent-background value of true:
Note that currently the transparent-background property disables all chrome and overrides the transparency property. The transparent-background property cannot be changed once a window is open.