aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pd/extra/pd~/pd~.c15
-rw-r--r--pd/src/g_template.c2
-rw-r--r--pd/src/g_text.c3
-rw-r--r--pd/src/m_pd.h2
-rw-r--r--pd/src/notes.txt3
-rw-r--r--pd/src/s_main.c7
-rw-r--r--pd/src/u_main.tk5
-rw-r--r--pd/src/x_connective.c3
-rw-r--r--pd/src/x_gui.c3
9 files changed, 24 insertions, 19 deletions
diff --git a/pd/extra/pd~/pd~.c b/pd/extra/pd~/pd~.c
index 3cf713fe..eba594c8 100644
--- a/pd/extra/pd~/pd~.c
+++ b/pd/extra/pd~/pd~.c
@@ -466,21 +466,16 @@ static void pd_tilde_tick(t_pd_tilde *x)
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)
diff --git a/pd/src/g_template.c b/pd/src/g_template.c
index 34541c06..f216b104 100644
--- a/pd/src/g_template.c
+++ b/pd/src/g_template.c
@@ -106,7 +106,7 @@ t_template *template_new(t_symbol *templatesym, int argc, t_atom *argv)
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);
diff --git a/pd/src/g_text.c b/pd/src/g_text.c
index b8680e87..f927bf38 100644
--- a/pd/src/g_text.c
+++ b/pd/src/g_text.c
@@ -131,6 +131,7 @@ static void canvas_objtext(t_glist *gl, int xpix, int ypix, int selected,
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 @@ static void canvas_howputnew(t_canvas *x, int *connectp, int *xpixp, int *ypixp,
{
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;
diff --git a/pd/src/m_pd.h b/pd/src/m_pd.h
index 9d8ffa13..534faac0 100644
--- a/pd/src/m_pd.h
+++ b/pd/src/m_pd.h
@@ -10,7 +10,7 @@ extern "C" {
#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
diff --git a/pd/src/notes.txt b/pd/src/notes.txt
index 369b7ffe..c11ef4e8 100644
--- a/pd/src/notes.txt
+++ b/pd/src/notes.txt
@@ -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 @@ mac:
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
diff --git a/pd/src/s_main.c b/pd/src/s_main.c
index 8e9cb08d..a246e38a 100644
--- a/pd/src/s_main.c
+++ b/pd/src/s_main.c
@@ -81,6 +81,7 @@ int sys_extraflags;
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 @@ static char *(usagemessage[]) = {
"-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 @@ int sys_argparse(int argc, char **argv)
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"))
{
diff --git a/pd/src/u_main.tk b/pd/src/u_main.tk
index 4a49d460..8834d232 100644
--- a/pd/src/u_main.tk
+++ b/pd/src/u_main.tk
@@ -126,10 +126,9 @@ bind Text <Control-s> {}
# 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 @@ pack .controls.inout.out.label .controls.inout.out.level \
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
diff --git a/pd/src/x_connective.c b/pd/src/x_connective.c
index 8687154e..b9093f46 100644
--- a/pd/src/x_connective.c
+++ b/pd/src/x_connective.c
@@ -1245,7 +1245,8 @@ static void makefilename_scanformat(t_makefilename *x)
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;
diff --git a/pd/src/x_gui.c b/pd/src/x_gui.c
index 7cc23d26..6ba58a7b 100644
--- a/pd/src/x_gui.c
+++ b/pd/src/x_gui.c
@@ -158,8 +158,7 @@ static void gfxstub_free(t_gfxstub *x)
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,