diff options
-rw-r--r-- | gui/gcanvas.c | 63 |
1 files changed, 31 insertions, 32 deletions
diff --git a/gui/gcanvas.c b/gui/gcanvas.c index d59c983..b13951c 100644 --- a/gui/gcanvas.c +++ b/gui/gcanvas.c @@ -1,43 +1,42 @@ -/* (C) Guenter Geiger <geiger@xdv.org> */
-
-
-#include <m_pd.h>
-#include "g_canvas.h"
-
-/* ------------------------ gcanvas ----------------------------- */
-
-
-#define BACKGROUNDCOLOR "grey"
-
-#define DEFAULTSIZE 80
-
-static t_class *gcanvas_class;
-
-typedef struct _gcanvas
-{
- t_object x_obj;
- t_glist * x_glist;
- t_outlet* out2;
- int x_width;
- int x_height;
- int x;
- int y;
-} t_gcanvas;
-
-/* widget helper functions */
-
-void gcanvas_drawme(t_gcanvas *x, t_glist *glist, int firsttime)
+/* (C) Guenter Geiger <geiger@xdv.org> */ + + +#include <m_pd.h> +#include "g_canvas.h" + +/* ------------------------ gcanvas ----------------------------- */ + + +#define BACKGROUNDCOLOR "grey" + +#define DEFAULTSIZE 80 + +static t_class *gcanvas_class; + +typedef struct _gcanvas +{ + t_object x_obj; + t_glist * x_glist; + t_outlet* out2; + int x_width; + int x_height; + int x; + int y; +} t_gcanvas; + +/* widget helper functions */ + +void gcanvas_drawme(t_gcanvas *x, t_glist *glist, int firsttime) {
if (firsttime) {
- sys_vgui(".x%x.c create rectangle \
-%d %d %d %d -tags %xS -fill %s\n",
+ sys_vgui(".x%x.c create rectangle %d %d %d %d -tags %xS -fill %s\n",
glist_getcanvas(glist),
x->x_obj.te_xpix, x->x_obj.te_ypix,
x->x_obj.te_xpix + x->x_width, x->x_obj.te_ypix + x->x_height,
x,BACKGROUNDCOLOR);
}
else {
- sys_vgui(".x%x.c coords %xS \
+ sys_vgui(".x%x.c coords %xS \ %d %d %d %d\n",
glist_getcanvas(glist), x,
x->x_obj.te_xpix, x->x_obj.te_ypix,
|