openbox/otk/rendertest.cc

32 lines
585 B
C++
Raw Normal View History

2003-01-18 00:33:48 +00:00
#include "otk.hh"
#include "rendercontrol.hh"
2003-01-18 04:31:16 +00:00
#include "rendertexture.hh"
2003-01-18 00:33:48 +00:00
#include <stdio.h>
2003-01-18 04:10:17 +00:00
#include <X11/Xlib.h>
2003-01-18 00:33:48 +00:00
int main(int argc, char **argv)
{
printf("\n");
otk::Application app(argc, argv);
otk::AppWidget foo(&app);
foo.resize(600, 500);
foo.show();
otk::RenderControl *rc = otk::RenderControl::getRenderControl(0);
2003-01-18 04:31:16 +00:00
otk::RenderTexture tex;
rc->drawBackground(&foo, tex);
2003-01-18 04:10:17 +00:00
XSetWindowBackgroundPixmap(**otk::display, foo.window(), foo.pixmap());
XClearWindow(**otk::display, foo.window());
2003-01-18 00:33:48 +00:00
app.run();
delete rc;
printf("\n");
return 0;
}