Revision: 10737 http://pure-data.svn.sourceforge.net/pure-data/?rev=10737&view=rev Author: millerpuckette Date: 2009-02-05 03:28:27 +0000 (Thu, 05 Feb 2009)
Log Message: ----------- 0.42-4. Fixes "send" template bug, "gfxstub" bug, 2 pd~ bugs
Modified Paths: -------------- trunk/pd/extra/pd~/pd~.c trunk/pd/src/g_template.c trunk/pd/src/g_text.c trunk/pd/src/m_pd.h trunk/pd/src/notes.txt trunk/pd/src/s_main.c trunk/pd/src/u_main.tk trunk/pd/src/x_connective.c trunk/pd/src/x_gui.c
Modified: trunk/pd/extra/pd~/pd~.c =================================================================== --- trunk/pd/extra/pd~/pd~.c 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/extra/pd~/pd~.c 2009-02-05 03:28:27 UTC (rev 10737) @@ -466,21 +466,16 @@ static void pd_tilde_anything(t_pd_tilde *x, t_symbol *s, int argc, t_atom *argv) { - char msgbuf[MAXPDSTRING], *sp, *ep = msgbuf+MAXPDSTRING; + char msgbuf[MAXPDSTRING]; if (!x->x_outfd) return; - msgbuf[0] = 0; - strncpy(msgbuf, s->s_name, MAXPDSTRING); - msgbuf[MAXPDSTRING-1] = 0; - sp = msgbuf + strlen(msgbuf); + fprintf(x->x_outfd, "%s ", s->s_name); while (argc--) { - if (sp < ep-1) - sp[0] = ' ', sp[1] = 0, sp++; - atom_string(argv++, sp, ep-sp); - sp += strlen(sp); + atom_string(argv++, msgbuf, MAXPDSTRING); + fprintf(x->x_outfd, "%s ", msgbuf); } - fprintf(x->x_outfd, "%s;\n", msgbuf); + fprintf(x->x_outfd, ";\n"); }
static void *pd_tilde_new(t_symbol *s, int argc, t_atom *argv)
Modified: trunk/pd/src/g_template.c =================================================================== --- trunk/pd/src/g_template.c 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/g_template.c 2009-02-05 03:28:27 UTC (rev 10737) @@ -106,7 +106,7 @@ bad: argc -= 2; argv += 2; } - if (templatesym->s_name) + if (*templatesym->s_name) { x->t_sym = templatesym; pd_bind(&x->t_pdobj, x->t_sym);
Modified: trunk/pd/src/g_text.c =================================================================== --- trunk/pd/src/g_text.c 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/g_text.c 2009-02-05 03:28:27 UTC (rev 10737) @@ -131,6 +131,7 @@ canvas_unsetcurrent((t_canvas *)gl); }
+extern int sys_noautopatch; /* utility routine to figure out where to put a new text box from menu and whether to connect to it automatically */ static void canvas_howputnew(t_canvas *x, int *connectp, int *xpixp, int *ypixp, @@ -138,7 +139,7 @@ { int xpix, ypix, indx = 0, nobj = 0, n2, x1, x2, y1, y2; int connectme = (x->gl_editor->e_selection && - !x->gl_editor->e_selection->sel_next); + !x->gl_editor->e_selection->sel_next && !sys_noautopatch); if (connectme) { t_gobj *g, *selected = x->gl_editor->e_selection->sel_what;
Modified: trunk/pd/src/m_pd.h =================================================================== --- trunk/pd/src/m_pd.h 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/m_pd.h 2009-02-05 03:28:27 UTC (rev 10737) @@ -10,7 +10,7 @@
#define PD_MAJOR_VERSION 0 #define PD_MINOR_VERSION 42 -#define PD_BUGFIX_VERSION 3 +#define PD_BUGFIX_VERSION 4 #define PD_TEST_VERSION ""
/* old name for "MSW" flag -- we have to take it for the sake of many old
Modified: trunk/pd/src/notes.txt =================================================================== --- trunk/pd/src/notes.txt 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/notes.txt 2009-02-05 03:28:27 UTC (rev 10737) @@ -1,3 +1,5 @@ +bug: go to ~/rep/rand, start pd, use open panel to open ../mark/mark.pd - crash + ---------------- dolist --------------------
test: @@ -14,6 +16,7 @@ Gnome: why don't windows pop up when clicked on?
problems: +pd~ "start" followed by messages gives race condition because of "fromgui" biz get rid of remaining -export-dynamic in makefiles saving as "x.pd" on mac writes to "x.pd.pd" (can't reproduce this.) find asdf$1 (e.g.) doesn't work
Modified: trunk/pd/src/s_main.c =================================================================== --- trunk/pd/src/s_main.c 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/s_main.c 2009-02-05 03:28:27 UTC (rev 10737) @@ -81,6 +81,7 @@ char sys_extraflagsstring[MAXPDSTRING]; int sys_run_scheduler(const char *externalschedlibname, const char *sys_extraflagsstring); +int sys_noautopatch; /* temporary hack to defeat new 0.42 editing */
/* here the "-1" counts signify that the corresponding vector hasn't been specified in command line arguments; sys_set_audio_settings will detect it @@ -398,6 +399,7 @@ "-schedlib <file> -- plug in external scheduler\n", "-extraflags <s> -- string argument to send schedlib\n", "-batch -- run off-line as a batch process\n", +"-noautopatch -- defeat auto-patching new from selected objects\n", };
static void sys_parsedevlist(int *np, int *vecp, int max, char *str) @@ -832,6 +834,11 @@ sys_printtostderr = sys_nogui = 1; argc--; argv++; } + else if (!strcmp(*argv, "-noautopatch")) + { + sys_noautopatch = 1; + argc--; argv++; + } #ifdef UNISTD else if (!strcmp(*argv, "-rt") || !strcmp(*argv, "-realtime")) {
Modified: trunk/pd/src/u_main.tk =================================================================== --- trunk/pd/src/u_main.tk 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/u_main.tk 2009-02-05 03:28:27 UTC (rev 10737) @@ -126,10 +126,9 @@ # the menus are instantiated here for the main window # for the patch windows, they are created by pdtk_canvas_new menu .mbar -canvas .dummy -height 2p -width 6c
frame .controls -pack .controls .dummy -side top -fill x +pack .controls -side top -fill x menu .mbar.file -tearoff $pd_tearoff .mbar add cascade -label "File" -menu .mbar.file menu .mbar.find -tearoff $pd_tearoff @@ -194,7 +193,7 @@
button .controls.dio -text "DIO\nerrors" \ -command {pd [concat pd audiostatus ;]} -button .controls.clear -text "clear\nprinout" \ +button .controls.clear -text "clear\nprintout" \ -command {.printout.text delete 0.0 end}
pack .controls.inout.in .controls.inout.out -side left -padx 6
Modified: trunk/pd/src/x_connective.c =================================================================== --- trunk/pd/src/x_connective.c 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/x_connective.c 2009-02-05 03:28:27 UTC (rev 10737) @@ -1245,7 +1245,8 @@ static void *makefilename_new(t_symbol *s) { t_makefilename *x = (t_makefilename *)pd_new(makefilename_class); - if (!s || !s->s_name) s = gensym("file.%d"); + if (!s || !*s->s_name) + s = gensym("file.%d"); outlet_new(&x->x_obj, &s_symbol); x->x_format = s; x->x_accept = A_NULL;
Modified: trunk/pd/src/x_gui.c =================================================================== --- trunk/pd/src/x_gui.c 2009-02-04 09:13:34 UTC (rev 10736) +++ trunk/pd/src/x_gui.c 2009-02-05 03:28:27 UTC (rev 10737) @@ -158,8 +158,7 @@
static void gfxstub_setup(void) { - gfxstub_class = class_new(gensym("gfxstub"), (t_newmethod)gfxstub_new, - (t_method)gfxstub_free, + gfxstub_class = class_new(gensym("gfxstub"), 0, (t_method)gfxstub_free, sizeof(t_gfxstub), CLASS_PD, 0); class_addanything(gfxstub_class, gfxstub_anything); class_addmethod(gfxstub_class, (t_method)gfxstub_signoff,
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.