2008-04-24 14:49:12 +02:00
|
|
|
/***************************************************************************
|
|
|
|
|
2009-08-17 12:41:51 +02:00
|
|
|
CDrawingArea.cpp
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-08-17 12:41:51 +02:00
|
|
|
(c) 2000-2009 Benoît Minisini <gambas@users.sourceforge.net>
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-08-17 12:41:51 +02:00
|
|
|
This program is free software; you can redistribute it and/or modify
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
the Free Software Foundation; either version 2, or (at your option)
|
|
|
|
any later version.
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-08-17 12:41:51 +02:00
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
GNU General Public License for more details.
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-08-17 12:41:51 +02:00
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
along with this program; if not, write to the Free Software
|
|
|
|
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
***************************************************************************/
|
|
|
|
|
|
|
|
#define __CDRAWINGAREA_CPP
|
|
|
|
|
2008-05-01 01:08:02 +02:00
|
|
|
#include <QApplication>
|
2008-04-24 14:49:12 +02:00
|
|
|
#include <QPaintEvent>
|
|
|
|
#include <QPixmap>
|
2008-05-01 01:08:02 +02:00
|
|
|
#include <QPainter>
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-07-12 23:49:13 +02:00
|
|
|
#include "CDraw.h"
|
2009-12-28 02:19:27 +01:00
|
|
|
#include "cpaint_impl.h"
|
2009-07-12 23:49:13 +02:00
|
|
|
#include "CDrawingArea.h"
|
|
|
|
|
2008-04-24 14:49:12 +02:00
|
|
|
#ifndef NO_X_WINDOW
|
2008-04-29 15:40:55 +02:00
|
|
|
#include <QX11Info>
|
2008-04-24 14:49:12 +02:00
|
|
|
#include <X11/Xlib.h>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
DECLARE_EVENT(EVENT_draw);
|
|
|
|
|
|
|
|
|
|
|
|
/***************************************************************************
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
class MyDrawingArea
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
***************************************************************************/
|
|
|
|
|
2009-09-01 03:14:13 +02:00
|
|
|
MyDrawingArea::MyDrawingArea(QWidget *parent) : MyContainer(parent)
|
2008-04-24 14:49:12 +02:00
|
|
|
{
|
|
|
|
drawn = 0;
|
|
|
|
cache = 0;
|
2009-01-03 23:24:02 +01:00
|
|
|
_background = 0;
|
|
|
|
_frozen = false;
|
|
|
|
_event_mask = 0;
|
2009-12-28 02:19:27 +01:00
|
|
|
_use_paint = false;
|
2009-01-03 23:24:02 +01:00
|
|
|
setMerge(false);
|
|
|
|
setCached(false);
|
|
|
|
setBackground();
|
|
|
|
setAllowFocus(false);
|
|
|
|
|
2008-04-29 15:40:55 +02:00
|
|
|
setAttribute(Qt::WA_KeyCompression, false);
|
2008-05-01 01:08:02 +02:00
|
|
|
setAttribute(Qt::WA_OpaquePaintEvent, true);
|
2009-09-24 01:21:08 +02:00
|
|
|
setAttribute(Qt::WA_NativeWindow, true);
|
|
|
|
setAttribute(Qt::WA_DontCreateNativeAncestors, true);
|
2008-05-01 01:08:02 +02:00
|
|
|
//setAttribute(Qt::WA_PaintOnScreen, true);
|
|
|
|
//setAttribute(Qt::WA_NoSystemBackground, true);
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
MyDrawingArea::~MyDrawingArea()
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
if (_background)
|
2009-09-01 03:14:13 +02:00
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
delete _background;
|
2009-09-01 03:14:13 +02:00
|
|
|
_background = 0;
|
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
void MyDrawingArea::setAllowFocus(bool f)
|
|
|
|
{
|
|
|
|
if (f)
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
setFocusPolicy(Qt::WheelFocus);
|
|
|
|
setAttribute(Qt::WA_InputMethodEnabled, true);
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
else
|
2008-05-01 01:08:02 +02:00
|
|
|
{
|
2008-04-24 14:49:12 +02:00
|
|
|
setFocusPolicy(Qt::NoFocus);
|
2008-05-01 01:08:02 +02:00
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void MyDrawingArea::setMerge(bool m)
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
_merge = m;
|
|
|
|
/*if (_merge)
|
|
|
|
clearWFlags(Qt::WPaintClever);
|
|
|
|
else
|
|
|
|
setWFlags(Qt::WPaintClever);*/
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
void MyDrawingArea::setFrozen(bool f)
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
XWindowAttributes attr;
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
if (f == _frozen)
|
|
|
|
return;
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
#ifndef NO_X_WINDOW
|
2009-01-03 23:24:02 +01:00
|
|
|
if (f)
|
|
|
|
{
|
|
|
|
//setBackgroundMode(Qt::NoBackground);
|
|
|
|
XGetWindowAttributes(QX11Info::display(), winId(), &attr);
|
|
|
|
_event_mask = attr.your_event_mask;
|
|
|
|
XSelectInput(QX11Info::display(), winId(), ExposureMask);
|
|
|
|
//clearWFlags(Qt::WPaintClever);
|
|
|
|
//qDebug("frozen");
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
//setBackgroundMode(Qt::PaletteBackground);
|
|
|
|
XSelectInput(QX11Info::display(), winId(), _event_mask);
|
|
|
|
setMerge(_merge);
|
|
|
|
//qDebug("unfrozen");
|
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
#endif
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
_frozen = f;
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
#if 1
|
|
|
|
void MyDrawingArea::paintEvent(QPaintEvent *event)
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
if (_background)
|
|
|
|
{
|
2009-09-24 01:21:08 +02:00
|
|
|
QPainter paint( this );
|
|
|
|
drawFrame(&paint);
|
|
|
|
//MyContainer::paintEvent(event);
|
2009-01-03 23:24:02 +01:00
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
QPainter paint( this );
|
|
|
|
QRect r;
|
|
|
|
|
2009-09-01 03:14:13 +02:00
|
|
|
r = event->rect().intersect(rect());
|
2009-01-03 23:24:02 +01:00
|
|
|
if (r.isValid())
|
|
|
|
{
|
|
|
|
QPainter *p;
|
2009-09-01 03:14:13 +02:00
|
|
|
void *object = CWidget::getReal(this);
|
|
|
|
|
|
|
|
if (!object)
|
|
|
|
return;
|
|
|
|
|
2008-04-24 14:49:12 +02:00
|
|
|
bool frame = !contentsRect().contains(event->rect());
|
|
|
|
|
|
|
|
cache = new QPixmap(r.width(), r.height());
|
2009-01-03 23:24:02 +01:00
|
|
|
cache->fill(this, r.x(), r.y());
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
//qDebug("paint: %d %d %d %d", event->rect().x(), event->rect().y(), event->rect().width(), event->rect().height());
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
//status = DRAW_status();
|
|
|
|
//DRAW_begin(NULL, p, width(), height());
|
|
|
|
|
2009-12-28 02:19:27 +01:00
|
|
|
if (_use_paint)
|
|
|
|
{
|
|
|
|
PAINT_begin(object);
|
|
|
|
p = PAINT_get_current();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
DRAW_begin(object);
|
|
|
|
p = DRAW_get_current();
|
|
|
|
}
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
p->translate(-r.x(), -r.y());
|
|
|
|
p->setClipRect(r);
|
|
|
|
//p->setClipRegion(event->region().intersect(contentsRect()));
|
|
|
|
p->setBrushOrigin(-r.x(), -r.y());
|
|
|
|
|
2008-04-24 14:49:12 +02:00
|
|
|
if (frame)
|
|
|
|
p->save();
|
|
|
|
|
2009-12-28 02:19:27 +01:00
|
|
|
GB.Raise(object, EVENT_draw, 0);
|
|
|
|
|
2008-04-24 14:49:12 +02:00
|
|
|
if (!contentsRect().contains(event->rect()))
|
|
|
|
{
|
|
|
|
p->restore();
|
|
|
|
//paint.setClipRegion( event->region().intersect(frameRect()) );
|
2008-05-01 01:08:02 +02:00
|
|
|
p->setRenderHint(QPainter::Antialiasing, false);
|
2008-04-24 14:49:12 +02:00
|
|
|
drawFrame(p);
|
|
|
|
}
|
2009-12-28 02:19:27 +01:00
|
|
|
|
|
|
|
if (_use_paint)
|
|
|
|
PAINT_end();
|
|
|
|
else
|
|
|
|
DRAW_end();
|
2009-07-18 04:30:07 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
paint.drawPixmap(r.x(), r.y(), *cache);
|
|
|
|
delete cache;
|
|
|
|
cache = 0;
|
|
|
|
}
|
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
void MyDrawingArea::setBackground()
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
if (_background)
|
|
|
|
{
|
|
|
|
_background->detach();
|
|
|
|
|
|
|
|
#ifdef NO_X_WINDOW
|
|
|
|
setErasePixmap(*_background);
|
|
|
|
#else
|
|
|
|
XSetWindowBackgroundPixmap(QX11Info::display(), winId(), _background->handle());
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
#ifdef NO_X_WINDOW
|
|
|
|
setBackgroundMode(Qt::NoBackground);
|
|
|
|
#else
|
|
|
|
XSetWindowBackgroundPixmap(QX11Info::display(), winId(), None);
|
|
|
|
#endif
|
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
void MyDrawingArea::refreshBackground()
|
|
|
|
{
|
|
|
|
#ifndef NO_X_WINDOW
|
2009-01-03 23:24:02 +01:00
|
|
|
XClearWindow(QX11Info::display(), winId());
|
|
|
|
#endif
|
2009-09-24 01:21:08 +02:00
|
|
|
repaint();
|
2008-04-24 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void MyDrawingArea::clearBackground()
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
if (_background)
|
|
|
|
{
|
|
|
|
QPainter p(_background);
|
2009-09-24 01:21:08 +02:00
|
|
|
p.fillRect(0, 0, _background->width(), _background->height(), palette().color(backgroundRole()));
|
2009-01-03 23:24:02 +01:00
|
|
|
p.end();
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
setBackground();
|
|
|
|
refreshBackground();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
setBackground();
|
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
bool MyDrawingArea::doResize()
|
|
|
|
{
|
|
|
|
int wb, hb, w, h;
|
|
|
|
|
|
|
|
if (drawn)
|
|
|
|
{
|
|
|
|
GB.Error("DrawingArea is being drawn");
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
if (_background)
|
|
|
|
{
|
|
|
|
w = QMAX(width(), 1);
|
|
|
|
h = QMAX(height(), 1);
|
|
|
|
|
|
|
|
QPixmap *p = new QPixmap(w, h);
|
2009-09-24 01:21:08 +02:00
|
|
|
p->fill(palette().color(backgroundRole()));
|
2009-01-03 23:24:02 +01:00
|
|
|
|
|
|
|
wb = QMIN(w, _background->width());
|
|
|
|
hb = QMIN(h, _background->height());
|
|
|
|
|
|
|
|
//bitBlt(p, 0, 0, _background, 0, 0, wb, hb, CopyROP);
|
|
|
|
QPainter pt(p);
|
|
|
|
pt.drawPixmap(0, 0, *_background, 0, 0, wb, hb);
|
2009-09-24 01:21:08 +02:00
|
|
|
//drawFrame(&pt);
|
2009-01-03 23:24:02 +01:00
|
|
|
pt.end();
|
|
|
|
|
|
|
|
delete _background;
|
|
|
|
_background = p;
|
|
|
|
|
|
|
|
setBackground();
|
2009-09-24 01:21:08 +02:00
|
|
|
refreshBackground();
|
2009-01-03 23:24:02 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
void MyDrawingArea::resizeEvent(QResizeEvent *e)
|
|
|
|
{
|
2009-09-01 03:14:13 +02:00
|
|
|
MyContainer::resizeEvent(e);
|
2009-01-03 23:24:02 +01:00
|
|
|
if (e->oldSize() != e->size())
|
|
|
|
doResize();
|
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
void MyDrawingArea::setCached(bool c)
|
|
|
|
{
|
|
|
|
if (_background)
|
|
|
|
delete _background;
|
|
|
|
|
|
|
|
if (c)
|
|
|
|
{
|
|
|
|
_background = new QPixmap(width(), height());
|
2009-09-24 01:21:08 +02:00
|
|
|
_background->fill(palette().color(backgroundRole()));
|
|
|
|
//setAttribute(Qt::WA_NoSystemBackground, true);
|
|
|
|
setAttribute(Qt::WA_StaticContents, true);
|
|
|
|
setAttribute(Qt::WA_PaintOnScreen, true);
|
2009-01-03 23:24:02 +01:00
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
_background = 0;
|
2009-09-24 01:21:08 +02:00
|
|
|
setAttribute(Qt::WA_PaintOnScreen, false);
|
|
|
|
//setAttribute(Qt::WA_NoSystemBackground, false);
|
|
|
|
setAttribute(Qt::WA_StaticContents, false);
|
2009-01-03 23:24:02 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
setBackground();
|
|
|
|
}
|
|
|
|
|
|
|
|
void MyDrawingArea::setPalette(const QPalette &pal)
|
|
|
|
{
|
2009-09-01 03:14:13 +02:00
|
|
|
MyContainer::setPalette(pal);
|
2009-01-03 23:24:02 +01:00
|
|
|
repaint();
|
|
|
|
}
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
/***************************************************************************
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
DrawingArea
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
***************************************************************************/
|
|
|
|
|
|
|
|
BEGIN_METHOD(CDRAWINGAREA_new, GB_OBJECT parent)
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
MyDrawingArea *wid = new MyDrawingArea(QCONTAINER(VARG(parent)));
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
//THIS->widget.background = QColorGroup::Base;
|
|
|
|
THIS->container = wid;
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
CWIDGET_new(wid, (void *)_object);
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
END_METHOD
|
|
|
|
|
|
|
|
|
|
|
|
BEGIN_PROPERTY(CDRAWINGAREA_cached)
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
if (READ_PROPERTY)
|
|
|
|
GB.ReturnBoolean(WIDGET->isCached());
|
|
|
|
else
|
|
|
|
WIDGET->setCached(VPROP(GB_BOOLEAN));
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
END_PROPERTY
|
|
|
|
|
|
|
|
|
|
|
|
DECLARE_METHOD(CCONTROL_background);
|
|
|
|
|
|
|
|
|
|
|
|
BEGIN_METHOD_VOID(CDRAWINGAREA_clear)
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
WIDGET->clearBackground();
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
END_METHOD
|
|
|
|
|
|
|
|
|
|
|
|
BEGIN_PROPERTY(CDRAWINGAREA_background)
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
CCONTROL_background(_object, _param);
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
if (!READ_PROPERTY)
|
|
|
|
WIDGET->clearBackground();
|
|
|
|
|
|
|
|
END_PROPERTY
|
|
|
|
|
|
|
|
BEGIN_PROPERTY(CDRAWINGAREA_border)
|
|
|
|
|
2009-09-01 03:14:13 +02:00
|
|
|
CCONTAINER_border(_object, _param);
|
2009-01-03 23:24:02 +01:00
|
|
|
|
|
|
|
if (!READ_PROPERTY)
|
|
|
|
WIDGET->clearBackground();
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
END_PROPERTY
|
|
|
|
|
|
|
|
BEGIN_PROPERTY(CDRAWINGAREA_enabled)
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
CCONTROL_enabled(_object, _param);
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
if (!READ_PROPERTY)
|
|
|
|
WIDGET->setFrozen(!VPROP(GB_BOOLEAN));
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
END_PROPERTY
|
|
|
|
|
|
|
|
BEGIN_PROPERTY(CDRAWINGAREA_merge)
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
if (READ_PROPERTY)
|
|
|
|
GB.ReturnBoolean(WIDGET->isMerge());
|
|
|
|
else
|
|
|
|
WIDGET->setMerge(VPROP(GB_BOOLEAN));
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
END_PROPERTY
|
|
|
|
|
|
|
|
BEGIN_PROPERTY(CDRAWINGAREA_focus)
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
if (READ_PROPERTY)
|
|
|
|
GB.ReturnBoolean(WIDGET->isAllowFocus());
|
|
|
|
else
|
|
|
|
WIDGET->setAllowFocus(VPROP(GB_BOOLEAN));
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
END_PROPERTY
|
|
|
|
|
2009-12-28 02:19:27 +01:00
|
|
|
BEGIN_PROPERTY(CDRAWINGAREA_paint)
|
|
|
|
|
|
|
|
if (READ_PROPERTY)
|
|
|
|
GB.ReturnBoolean(WIDGET->isPaint());
|
|
|
|
else
|
|
|
|
WIDGET->setPaint(VPROP(GB_BOOLEAN));
|
|
|
|
|
|
|
|
END_PROPERTY
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
GB_DESC CDrawingAreaDesc[] =
|
|
|
|
{
|
2009-01-03 23:24:02 +01:00
|
|
|
GB_DECLARE("DrawingArea", sizeof(CDRAWINGAREA)), GB_INHERITS("Container"),
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
GB_METHOD("_new", NULL, CDRAWINGAREA_new, "(Parent)Container;"),
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
GB_PROPERTY("Cached", "b", CDRAWINGAREA_cached),
|
|
|
|
GB_PROPERTY("Merge", "b", CDRAWINGAREA_merge),
|
|
|
|
|
|
|
|
GB_PROPERTY("Border", "i", CDRAWINGAREA_border),
|
|
|
|
GB_PROPERTY("Background", "i", CDRAWINGAREA_background),
|
|
|
|
|
|
|
|
GB_PROPERTY("Focus", "b", CDRAWINGAREA_focus),
|
|
|
|
GB_PROPERTY("Enabled", "b", CDRAWINGAREA_enabled),
|
2009-12-28 02:19:27 +01:00
|
|
|
GB_PROPERTY("Painted", "b", CDRAWINGAREA_paint),
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
GB_METHOD("Clear", NULL, CDRAWINGAREA_clear, NULL),
|
2008-04-24 14:49:12 +02:00
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
GB_EVENT("Draw", NULL, NULL, &EVENT_draw),
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
GB_INTERFACE("Draw", &DRAW_Interface),
|
2009-12-28 02:19:27 +01:00
|
|
|
GB_INTERFACE("Paint", &PAINT_Interface),
|
2008-04-24 14:49:12 +02:00
|
|
|
|
|
|
|
DRAWINGAREA_DESCRIPTION,
|
|
|
|
|
2009-01-03 23:24:02 +01:00
|
|
|
GB_END_DECLARE
|
2008-04-24 14:49:12 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|