Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18042
Modified Files: Tag: impd_0_37 g_canvas.c g_canvas.h m_atom.c Log Message: .
Index: g_canvas.h =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_canvas.h,v retrieving revision 1.1.1.4.2.4.2.4 retrieving revision 1.1.1.4.2.4.2.5 diff -C2 -d -r1.1.1.4.2.4.2.4 -r1.1.1.4.2.4.2.5 *** g_canvas.h 3 May 2004 02:57:27 -0000 1.1.1.4.2.4.2.4 --- g_canvas.h 18 Aug 2004 19:07:47 -0000 1.1.1.4.2.4.2.5 *************** *** 313,317 **** };
! /* cursor definitions; used as return value for t_parentclickfn */ #define CURSOR_RUNMODE_NOTHING 0 #define CURSOR_RUNMODE_CLICKME 1 --- 313,317 ---- };
! /* cursor definitions; used as return value for t_parentclickfn */ #define CURSOR_RUNMODE_NOTHING 0 #define CURSOR_RUNMODE_CLICKME 1 *************** *** 341,345 **** EXTERN void gobj_save(t_gobj *x, t_binbuf *b); EXTERN void gobj_properties(t_gobj *x, struct _glist *glist); - EXTERN void gobj_save(t_gobj *x, t_binbuf *b);
/* -------------------- functions on glists --------------------- */ --- 341,344 ----
Index: m_atom.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/m_atom.c,v retrieving revision 1.1.1.2.2.3.2.2 retrieving revision 1.1.1.2.2.3.2.3 diff -C2 -d -r1.1.1.2.2.3.2.2 -r1.1.1.2.2.3.2.3 *** m_atom.c 24 May 2004 22:20:18 -0000 1.1.1.2.2.3.2.2 --- m_atom.c 18 Aug 2004 19:07:47 -0000 1.1.1.2.2.3.2.3 *************** *** 73,77 **** case A_COMMA: strcpy(buf, ","); break; case A_POINTER: ! strcpy(buf, "(pointer)"); break; case A_FLOAT: --- 73,77 ---- case A_COMMA: strcpy(buf, ","); break; case A_POINTER: ! sprintf (buf, "pointer:0x%08x",a->a_w.w_gpointer); break; case A_FLOAT: *************** *** 83,91 **** case A_SYMBOL: { char *sp; unsigned int len; int quote; for (sp = a->a_w.w_symbol->s_name, len = 0, quote = 0; *sp; sp++, len++) ! if (*sp == ';' || *sp == ',' || *sp == '\' || (*sp == '$' && sp == a->a_w.w_symbol->s_name && sp[1] >= '0' && sp[1] <= '9')) --- 83,94 ---- case A_SYMBOL: { + /* HERE the quoting of whitespace (now disabled) was a hack by Guenter */ char *sp; unsigned int len; int quote; for (sp = a->a_w.w_symbol->s_name, len = 0, quote = 0; *sp; sp++, len++) ! if ( ! /* *sp == ' ' || */ ! *sp == ';' || *sp == ',' || *sp == '\' || (*sp == '$' && sp == a->a_w.w_symbol->s_name && sp[1] >= '0' && sp[1] <= '9')) *************** *** 97,101 **** while (bp < ep && *sp) { ! if (*sp == ';' || *sp == ',' || *sp == '\' || (*sp == '$' && bp == buf && sp[1] >= '0' && sp[1] <= '9')) *bp++ = '\'; --- 100,107 ---- while (bp < ep && *sp) { ! /* GG: quoting for whitespace */ ! if ( ! /* *sp == ' ' || */ ! *sp == ';' || *sp == ',' || *sp == '\' || (*sp == '$' && bp == buf && sp[1] >= '0' && sp[1] <= '9')) *bp++ = '\'; *************** *** 116,128 **** } } ! break; ! case A_DOLLAR: ! sprintf(buf, "$%d", a->a_w.w_index); ! break; ! case A_DOLLSYM: ! sprintf(buf, "$%s", a->a_w.w_symbol->s_name); ! break; ! default: ! bug("atom_string"); } } --- 122,129 ---- } } ! break; ! case A_DOLLAR: sprintf(buf, "$%d", a->a_w.w_index); break; ! case A_DOLLSYM: sprintf(buf, "$%s", a->a_w.w_symbol->s_name); break; ! default: bug("atom_string"); } }
Index: g_canvas.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_canvas.c,v retrieving revision 1.1.1.4.2.7.2.15 retrieving revision 1.1.1.4.2.7.2.16 diff -C2 -d -r1.1.1.4.2.7.2.15 -r1.1.1.4.2.7.2.16 *** g_canvas.c 1 May 2004 18:19:03 -0000 1.1.1.4.2.7.2.15 --- g_canvas.c 18 Aug 2004 19:07:47 -0000 1.1.1.4.2.7.2.16 *************** *** 159,175 **** { if (!x) bug("canvas_getenv"); ! while (!x->gl_env) ! if (!(x = x->gl_owner)) ! bug("t_canvasenvironment", x); ! return (x->gl_env); }
! int canvas_getdollarzero( void) { t_canvas *x = canvas_getcurrent(); t_canvasenvironment *env = (x ? canvas_getenv(x) : 0); ! if (env) ! return (env->ce_dollarzero); ! else return (0); }
--- 159,171 ---- { if (!x) bug("canvas_getenv"); ! while (!x->gl_env) { x=x->gl_owner; if (!x) bug("t_canvasenvironment",x);} ! return x->gl_env; }
! int canvas_getdollarzero(void) { t_canvas *x = canvas_getcurrent(); t_canvasenvironment *env = (x ? canvas_getenv(x) : 0); ! return env ? env->ce_dollarzero : 0; }
*************** *** 197,212 **** }
- t_symbol *canvas_getcurrentdir(void) - { - t_canvasenvironment *e = canvas_getenv(canvas_getcurrent()); - return (e->ce_dir); - } - t_symbol *canvas_getdir(t_canvas *x) { t_canvasenvironment *e = canvas_getenv(x); ! return (e->ce_dir); }
void canvas_makefilename(t_canvas *x, char *file, char *result, int resultsize) { --- 193,204 ---- }
t_symbol *canvas_getdir(t_canvas *x) { t_canvasenvironment *e = canvas_getenv(x); ! return e->ce_dir; }
+ t_symbol *canvas_getcurrentdir(void) {return canvas_getdir(canvas_getcurrent());} + void canvas_makefilename(t_canvas *x, char *file, char *result, int resultsize) { *************** *** 232,247 **** void canvas_rename(t_canvas *x, t_symbol *s, t_symbol *dir) { ! if (strcmp(x->gl_name->s_name, "Pd")) ! pd_unbind(&x->gl_pd, canvas_makebindsym(x->gl_name)); x->gl_name = s; ! if (strcmp(x->gl_name->s_name, "Pd")) ! pd_bind(&x->gl_pd, canvas_makebindsym(x->gl_name)); ! if (glist_isvisible(x)) ! canvas_reflecttitle(x); ! if (dir && dir != &s_) ! { ! t_canvasenvironment *e = canvas_getenv(x); ! e->ce_dir = dir; ! } }
--- 224,233 ---- void canvas_rename(t_canvas *x, t_symbol *s, t_symbol *dir) { ! t_symbol *a = x->gl_name; ! if (strcmp(a->s_name, "Pd")) pd_unbind(&x->gl_pd, canvas_makebindsym(a)); x->gl_name = s; ! if (strcmp(a->s_name, "Pd")) pd_bind( &x->gl_pd, canvas_makebindsym(a)); ! if (glist_isvisible(x)) canvas_reflecttitle(x); ! if (dir && dir != &s_) canvas_getenv(x)->ce_dir = dir; }
*************** *** 906,911 **** canvas_pop(x, x->gl_willvis);
! if (!(z = gensym("#X")->s_thing)) error("canvas_restore: out of context"); ! else if (*z != canvas_class) error("canvas_restore: wasn't a canvas"); else { --- 892,897 ---- canvas_pop(x, x->gl_willvis);
! if (!(z = gensym("#X")->s_thing)) pd_error(x,"canvas_restore: out of context"); ! else if (*z != canvas_class) pd_error(x,"canvas_restore: wasn't a canvas"); else {