openbox/otk/surface.hh

38 lines
662 B
C++
Raw Normal View History

2003-01-18 03:52:58 +00:00
// -*- mode: C++; indent-tabs-mode: nil; c-basic-offset: 2; -*-
#ifndef __surface_hh
#define __surface_hh
#include "point.hh"
2003-01-18 04:06:39 +00:00
#include "truerendercontrol.hh"
2003-01-18 03:52:58 +00:00
extern "C" {
#include <X11/Xlib.h>
}
namespace otk {
class Surface {
Point _size;
Pixmap _pm;
protected:
Surface();
Surface(const Point &size);
virtual void setSize(int w, int h);
public:
virtual ~Surface();
virtual const Point& size() const { return _size; }
virtual int width() const { return _size.x(); }
virtual int height() const { return _size.y(); }
2003-01-18 04:10:17 +00:00
virtual Pixmap pixmap() const { return _pm; } // TEMP
2003-01-18 04:06:39 +00:00
friend class TrueRenderControl;
2003-01-18 03:52:58 +00:00
};
}
#endif // __surface_hh