[fpc-pascal] transparent windows on X11
idokan at gmail.com
Mon Mar 17 15:38:15 CET 2008
Copy paste from : http://www.faqs.org/faqs/x-faq/part7/
Subject: 175) How do I create a transparent window?
A completely transparent window is easy to get -- use an InputOnly
window. In order to create a window which is *mostly* transparent, you have
- the SHAPE extension first released with X11R4 offers an easy way to
make non-rectangular windows, so you can set the shape of the window to fit the
areas where the window should be nontransparent; however, not all servers
support the extension.
- a machine-specific method of implementing transparent windows for
particular servers is to use an overlay plane supported by the hardware. Note
that there is no X notion of a "transparent color index".
- a generally portable solution is to use a large number of tiny
windows, but this makes operating on the application as a unit difficult.
- a final answer is to consider whether you really need a transparent
window or if you would be satisfied with being able to overlay your application
window with information; if so, you can draw into separate bitplanes in colors
that will appear properly.
[thanks to der Mouse, mouse at lightning.McRCIM.McGill.EDU, 3/92; see also
The X Journal 1:4 for a more complete answer, including code samples for this
On Mon, Mar 17, 2008 at 4:17 PM, Graeme Geldenhuys
<graemeg.lists at gmail.com> wrote:
> Anybody know how to use Xlib API to create transparent windows? This
> is for use with fpGUI Toolkit. For example. I have a Label component
> (which is actually a mini window) and have to always specify and paint
> a background color. If I don't, I see all kinds of rubbish as the
> I want to place the Label component/window on another window (Form),
> and only want to see the text of the label. The background window must
> show through. Any ideas?
> - Graeme -
> fpGUI - a cross-platform Free Pascal GUI toolkit
> fpc-pascal maillist - fpc-pascal at lists.freepascal.org
More information about the fpc-pascal