2008-09-21 10:13:21 +02:00
|
|
|
/*
|
2010-10-06 13:35:14 +02:00
|
|
|
* drawin.h - drawin functions header
|
2008-09-21 10:13:21 +02:00
|
|
|
*
|
2009-07-28 16:04:58 +02:00
|
|
|
* Copyright © 2007-2009 Julien Danjou <julien@danjou.info>
|
2010-10-06 13:35:14 +02:00
|
|
|
* Copyright © 2010 Uli Schlachter <psychon@znc.in>
|
2008-09-21 10:13:21 +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 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* 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.
|
|
|
|
*
|
|
|
|
* 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.,
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
#ifndef AWESOME_OBJECTS_DRAWIN_H
|
|
|
|
#define AWESOME_OBJECTS_DRAWIN_H
|
2008-09-21 10:13:21 +02:00
|
|
|
|
2009-09-30 16:04:42 +02:00
|
|
|
#include "objects/window.h"
|
2009-08-17 16:38:56 +02:00
|
|
|
#include "common/luaobject.h"
|
2010-10-06 13:27:21 +02:00
|
|
|
#include "draw.h"
|
2008-09-21 10:13:21 +02:00
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
/** Drawin type */
|
|
|
|
struct drawin_t
|
2009-04-17 16:18:14 +02:00
|
|
|
{
|
2009-09-30 16:04:42 +02:00
|
|
|
WINDOW_OBJECT_HEADER
|
2009-04-17 16:18:14 +02:00
|
|
|
/** Ontop */
|
|
|
|
bool ontop;
|
|
|
|
/** Visible */
|
2009-08-17 16:56:03 +02:00
|
|
|
bool visible;
|
2009-04-17 16:18:14 +02:00
|
|
|
/** Cursor */
|
|
|
|
char *cursor;
|
2010-12-12 21:14:04 +01:00
|
|
|
/** Background color */
|
|
|
|
color_t bg_color;
|
2009-07-28 16:04:58 +02:00
|
|
|
/** The pixmap copied to the window object. */
|
|
|
|
xcb_pixmap_t pixmap;
|
2010-10-06 13:49:50 +02:00
|
|
|
/** Surface for drawing to the pixmap. */
|
|
|
|
cairo_surface_t *surface;
|
2009-07-28 16:04:58 +02:00
|
|
|
/** The window geometry. */
|
|
|
|
area_t geometry;
|
2009-04-17 16:18:14 +02:00
|
|
|
};
|
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
void drawin_unref_simplified(drawin_t **);
|
2009-04-17 16:18:14 +02:00
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
ARRAY_FUNCS(drawin_t *, drawin, drawin_unref_simplified)
|
2008-10-19 19:14:55 +02:00
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
drawin_t * drawin_getbywin(xcb_window_t);
|
2009-04-11 00:27:06 +02:00
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
void drawin_refresh_pixmap_partial(drawin_t *, int16_t, int16_t, uint16_t, uint16_t);
|
2009-08-17 16:56:03 +02:00
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
void drawin_class_setup(lua_State *);
|
2008-09-24 12:13:21 +02:00
|
|
|
|
2010-10-06 13:35:14 +02:00
|
|
|
lua_class_t drawin_class;
|
2008-09-21 10:13:21 +02:00
|
|
|
|
|
|
|
#endif
|
2011-09-11 16:50:01 +02:00
|
|
|
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80
|