[PD-cvs] pd/src desire.c, 1.1.2.170, 1.1.2.171 desire.h, 1.1.2.35, 1.1.2.36
Mathieu Bouchard
matju at users.sourceforge.net
Fri Sep 8 22:59:06 CEST 2006
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22291
Modified Files:
Tag: devel_0_39
desire.c desire.h
Log Message:
more cleanup
Index: desire.h
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.h,v
retrieving revision 1.1.2.35
retrieving revision 1.1.2.36
diff -C2 -d -r1.1.2.35 -r1.1.2.36
*** desire.h 8 Sep 2006 20:34:05 -0000 1.1.2.35
--- desire.h 8 Sep 2006 20:59:04 -0000 1.1.2.36
***************
*** 21,27 ****
In this case "gl_havewindow" is always set.
! canvas_list is a list of root windows only, which can be traversed using glists_each.
! If a glist has a window it may still not be "mapped." Miniaturized
windows aren't mapped, for example, but a window is also not mapped
immediately upon creation. In either case gl_havewindow is true but
--- 21,27 ----
In this case "gl_havewindow" is always set.
! canvas_list is a list of root windows only, which can be traversed using canvases_each.
! If a canvas has a window it may still not be "mapped." Miniaturized
windows aren't mapped, for example, but a window is also not mapped
immediately upon creation. In either case gl_havewindow is true but
***************
*** 29,39 ****
Closing a non-root window makes it invisible; closing a root destroys it.
! A glist that's just a text object on its parent is always "toplevel." An
! embedded glist can switch back and forth to appear as a toplevel by double-
clicking on it. Single-clicking a text box makes the toplevel become visible
and raises the window it's in.
! If a glist shows up as a graph on its parent, the graph is blanked while the
! glist has its own window, even if miniaturized.
*/
--- 29,39 ----
Closing a non-root window makes it invisible; closing a root destroys it.
! A canvas that's just a text object on its parent is always "toplevel." An
! embedded canvas can switch back and forth to appear as a toplevel by double-
clicking on it. Single-clicking a text box makes the toplevel become visible
and raises the window it's in.
! If a canvas shows up as a graph on its parent, the graph is blanked while the
! canvas has its own window, even if miniaturized.
*/
***************
*** 66,70 ****
#define t_fielddesc struct _fielddesc
! /* the t_tick structure describes where to draw x and y "ticks" for a glist */
typedef struct _tick { /* where to put ticks on x or y axes */
float point; /* one point to draw a big tick at */
--- 66,70 ----
#define t_fielddesc struct _fielddesc
! /* the t_tick structure describes where to draw x and y "ticks" for a canvas */
typedef struct _tick { /* where to put ticks on x or y axes */
float point; /* one point to draw a big tick at */
***************
*** 75,83 ****
/* the t_canvas structure, which describes a list of elements that live on an area of a window.*/
struct _glist {
! t_object gl_obj; /* header in case we're a glist */
t_gobj *list; /* the actual data */
struct _gstub *stub; /* safe pointer handler */
int valid; /* incremented when pointers might be stale */
! t_canvas *owner; /* parent glist, supercanvas, or 0 if none */
int pixwidth, pixheight; /* width in pixels (on parent, if a graph) */
float x1,y1,x2,y2; /* bounding rectangle in our own coordinates */
--- 75,83 ----
/* the t_canvas structure, which describes a list of elements that live on an area of a window.*/
struct _glist {
! t_object gl_obj; /* header in case we're a canvas */
t_gobj *list; /* the actual data */
struct _gstub *stub; /* safe pointer handler */
int valid; /* incremented when pointers might be stale */
! t_canvas *owner; /* parent canvas, supercanvas, or 0 if none */
int pixwidth, pixheight; /* width in pixels (on parent, if a graph) */
float x1,y1,x2,y2; /* bounding rectangle in our own coordinates */
***************
*** 143,147 ****
t_gobj x_gobj;
t_scalar *scalar; /* scalar "containing" the array */
! t_canvas *glist; /* containing glist */
t_symbol *name; /* unexpanded name (possibly with leading '$') */
t_symbol *realname; /* expanded name (symbol we're bound to) */
--- 143,147 ----
t_gobj x_gobj;
t_scalar *scalar; /* scalar "containing" the array */
! t_canvas *canvas; /* containing canvas */
t_symbol *name; /* unexpanded name (possibly with leading '$') */
t_symbol *realname; /* expanded name (symbol we're bound to) */
***************
*** 151,155 ****
};
! /* structure for traversing all the connections in a glist */
typedef struct _linetraverser {
t_canvas *canvas;
--- 151,155 ----
};
! /* structure for traversing all the connections in a canvas */
typedef struct _linetraverser {
t_canvas *canvas;
***************
*** 169,173 ****
doesn't work on array elements... LATER reconsider this */
! #define STUFF t_gobj *x, struct _glist *glist, t_word *data, t_template *tmpl
typedef void (*t_parentgetrectfn)( STUFF, float basex, float basey, int *x1, int *y1, int *x2, int *y2);
typedef void (*t_parentdisplacefn)(STUFF, float basex, float basey, int dx, int dy);
--- 169,173 ----
doesn't work on array elements... LATER reconsider this */
! #define STUFF t_gobj *x, t_canvas *canvas, t_word *data, t_template *tmpl
typedef void (*t_parentgetrectfn)( STUFF, float basex, float basey, int *x1, int *y1, int *x2, int *y2);
typedef void (*t_parentdisplacefn)(STUFF, float basex, float basey, int dx, int dy);
***************
*** 235,239 ****
EXTERN t_scalar *scalar_new(t_canvas *owner, t_symbol *templatesym);
EXTERN void word_free(t_word *wp, t_template *tmpl);
! EXTERN void scalar_redraw(t_scalar *x, t_canvas *glist);
EXTERN t_template *template_new(t_symbol *sym, int argc, t_atom *argv);
EXTERN void template_free(t_template *x);
--- 235,239 ----
EXTERN t_scalar *scalar_new(t_canvas *owner, t_symbol *templatesym);
EXTERN void word_free(t_word *wp, t_template *tmpl);
! EXTERN void scalar_redraw(t_scalar *x, t_canvas *canvas);
EXTERN t_template *template_new(t_symbol *sym, int argc, t_atom *argv);
EXTERN void template_free(t_template *x);
Index: desire.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.c,v
retrieving revision 1.1.2.170
retrieving revision 1.1.2.171
diff -C2 -d -r1.1.2.170 -r1.1.2.171
*** desire.c 8 Sep 2006 20:34:03 -0000 1.1.2.170
--- desire.c 8 Sep 2006 20:59:03 -0000 1.1.2.171
***************
*** 57,64 ****
#define class_addmethod3(_cl,_ptr,_str,_sig) class_addmethod2(_cl,(t_method)_ptr,gensym(_str),_sig)
! #define canvas_each(CHILD,GLIST) for(CHILD=(GLIST)->list; CHILD; CHILD=CHILD->g_next)
! #define canvases_each(GLIST,GLISTS) for(GLIST=GLISTS; GLIST; GLIST=GLIST->gl_next)
! #define canvas_wires_each(WIRE,TRAV,GLIST) \
! for (linetraverser_start(&TRAV,GLIST); (WIRE=linetraverser_next(&TRAV)); )
static void postatom2(const char *s, int argc, t_atom *argv);
--- 57,64 ----
[...1248 lines suppressed...]
--- 7841,7846 ----
static void cnv_get_pos(t_cnv *x) {
if(x->snd && x->snd->s_thing) {
! x->at[0].a_w.w_float = text_xpix((t_text *)x, x->canvas);
! x->at[1].a_w.w_float = text_ypix((t_text *)x, x->canvas);
pd_list(x->snd->s_thing, &s_list, 2, x->at);
}
***************
*** 7991,7995 ****
}
! void g_canvas_setup(void) {
/* we prevent the user from typing "canvas" in an object box
by sending 0 for a creator function. */
--- 7959,7963 ----
}
! static void g_canvas_setup(void) {
/* we prevent the user from typing "canvas" in an object box
by sending 0 for a creator function. */
More information about the Pd-cvs
mailing list