alpha access function

This commit is contained in:
fluxgen 2004-06-07 20:24:38 +00:00
parent ae6315acc3
commit 5530ce6450
2 changed files with 10 additions and 2 deletions

View file

@ -19,7 +19,7 @@
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE. // DEALINGS IN THE SOFTWARE.
// $Id: FbWindow.cc,v 1.34 2004/05/24 13:09:32 rathnor Exp $ // $Id: FbWindow.cc,v 1.35 2004/06/07 20:24:38 fluxgen Exp $
#include "FbWindow.hh" #include "FbWindow.hh"
@ -249,6 +249,13 @@ void FbWindow::setAlpha(unsigned char alpha) {
#endif // HAVE_XRENDER #endif // HAVE_XRENDER
} }
unsigned char FbWindow::alpha() const {
#ifdef HAVE_XRENDER
if (m_transparent.get())
return m_transparent->alpha();
#endif // HAVE_XRENDER
return 255;
}
FbWindow &FbWindow::operator = (const FbWindow &win) { FbWindow &FbWindow::operator = (const FbWindow &win) {
m_parent = win.parent(); m_parent = win.parent();

View file

@ -19,7 +19,7 @@
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE. // DEALINGS IN THE SOFTWARE.
// $Id: FbWindow.hh,v 1.30 2004/05/17 15:01:32 rathnor Exp $ // $Id: FbWindow.hh,v 1.31 2004/06/07 20:24:37 fluxgen Exp $
#ifndef FBTK_FBWINDOW_HH #ifndef FBTK_FBWINDOW_HH
#define FBTK_FBWINDOW_HH #define FBTK_FBWINDOW_HH
@ -151,6 +151,7 @@ public:
inline unsigned int height() const { return m_height; } inline unsigned int height() const { return m_height; }
inline unsigned int borderWidth() const { return m_border_width; } inline unsigned int borderWidth() const { return m_border_width; }
inline int depth() const { return m_depth; } inline int depth() const { return m_depth; }
unsigned char alpha() const;
int screenNumber() const; int screenNumber() const;
long eventMask() const; long eventMask() const;
/// compare X window /// compare X window