[PD-dev] [ pure-data-Patches-1981332 ] add path arg to openpanel and savepanel

SourceForge.net noreply at sourceforge.net
Tue Jun 3 09:02:36 CEST 2008


Patches item #1981332, was opened at 2008-06-01 16:38
Message generated for change (Comment added) made by zmoelnig
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=478072&aid=1981332&group_id=55736

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: puredata
Group: feature
Status: Open
>Resolution: Duplicate
Priority: 5
Private: No
Submitted By: Martin Peach (mrpeach)
Assigned to: Nobody/Anonymous (nobody)
Summary: add path arg to openpanel and savepanel

Initial Comment:
This patch adds a path argument to openpanel and savepanel which is saved whenever the enclosing patch is saved.
I used A_GIMME for the argument, but only a single symbol will be used, any other args will be quietly ignored.



----------------------------------------------------------------------

>Comment By: IOhannes m zmölnig (zmoelnig)
Date: 2008-06-03 09:02

Message:
Logged In: YES 
user_id=564396
Originator: NO

isn't that a dupe of:

http://sourceforge.net/tracker/index.php?func=detail&aid=1244757&group_id=55736&atid=478072

----------------------------------------------------------------------

Comment By: Martin Peach (mrpeach)
Date: 2008-06-02 19:38

Message:
Logged In: YES 
user_id=919007
Originator: YES

...and periods of course. Part of the problem is that odd characters in
filenames can get mangled by intervening software, as in the case of Pd,
where you can't use { } or \ in a filename because you can't enter it, you
get a message like "keycode 92: dropped" instead.

----------------------------------------------------------------------

Comment By: Martin Peach (mrpeach)
Date: 2008-06-02 19:22

Message:
Logged In: YES 
user_id=919007
Originator: YES

Of course you're right. In my experience of cross-platformity though it's
best to use underscores instead of spaces, never start a filename with a
number, and otherwise use only alphanumeric characters in file names. It
just _always_ works that way.

----------------------------------------------------------------------

Comment By: Hans-Christoph Steiner (eighthave)
Date: 2008-06-02 19:04

Message:
Logged In: YES 
user_id=27104
Originator: NO

FYI: commas are valid in all the major filesystems, EXT2/3, HFS+, NTFS,
XFS, etc.  I think even FAT supports commas.  Same with semi-colons.

Basically, the NTFS restrictions are the common denominator
(http://en.wikipedia.org/wiki/NTFS), you can't use these characters:

U+0000 (NUL) / (slash) \ (backslash) : (colon) * (asterisk) ? (Question
mark) " (quote) < (less than) > (greater than) and | (pipe)

EXT2/3 only limits (NULL /) and HFS+ APIs limit (NULL / :) 


----------------------------------------------------------------------

Comment By: Martin Peach (mrpeach)
Date: 2008-06-02 18:08

Message:
Logged In: YES 
user_id=919007
Originator: YES

OK, here is a patch that just makes a path from all the arguments. If the
path doesn't work it seems to be quietly ignored by tcl. Not sure which OSs
allow commas in file names...

File Added: panelpatch2.diff

----------------------------------------------------------------------

Comment By: Hans-Christoph Steiner (eighthave)
Date: 2008-06-02 00:54

Message:
Logged In: YES 
user_id=27104
Originator: NO

how about using all of the arguments as the path name?  That way you can
easily include paths that have spaces in them, which are quite common.  you
can see an example of how to convert the argv t_atom list to a binbuf then
to a string here, in function print_new():

http://pure-data.svn.sourceforge.net/viewvc/pure-data/branches/pd-extended/v0-40/pd/src/x_interface.c?view=markup

Ideally, it would also handle commas, etc.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=478072&aid=1981332&group_id=55736




More information about the Pd-dev mailing list