|
![](/i/fill.gif) |
On Thu, 14 Jan 1999 11:02:53 -0600, Thorsten Froehlich
<fro### [at] charlie cns iit edu> wrote:
>In article <369df85a.0@news.povray.org> , par### [at] my-dejanews com (Ron Parker)
>wrote:
>
>>If you say so.... :)
>>
>>Actually, you don't need to know how many spaces. Since the Mac doesn't
>>have a command line, you use the mouse to pick the file you want, and the
>>computer already knows how many spaces there are. Programs that use command
>>lines, though, should support quoting. You have to use quotes on Windows
>>console-mode programs when using filenames with embedded spaces as well,
>>but the shell handles them, which leads me to believe that whatever solution
>>is found should be platform-specific.
>
>Well, to the honest, even single or double quotes won't help - the Mac allows nearly
>everything as a name.
I'm pretty sure Unix allows just about anything as well. (files named -rf,
anyone?) I think they get around it by escaping important characters. So a
file named "test file", including the quotes, would be referenced on the
command line as "\"test file\"" or something similar. I suppose this depends
on your shell, as well. But on operating systems that support command lines
and have proper shells, this all happens at the shell level, before POV-Ray
even sees it. The only way it seems there's a problem is if POV-Ray can't
handle getting " myfile.pov" (without the quotes) as an argument without
making invalid assumptions (such as that the spaces are redundant) about it.
I guess that brings me to my point: I thought POV just used argv to do its
command-line parsing. argv is filled in by the shell on OSes with command
lines, so POV should just take what it's given without any further parsing,
at least by default. I assume (without checking) that the Windows GUI takes
the arguments that are specified in the Render Options edit box, splits them
on spaces, and fills in an argv for altmain. This is too simplistic, and
probably wrong, but it's a Windows issue rather than a core issue. I thought
the Mac UI had a more advanced way to specify these options anyway, so why
is it a big deal in the first place? If the Mac UI does allow you to specify
a command line, it seems like it's the UI's job to parse it into a format
that's acceptable to altmain.
Unfortunately, I don't have the source code handy at the moment, so I can't
say for sure whether any of these assertions are grounded in fact, but I'm
sure you'll correct me if I'm wrong. :)
Post a reply to this message
|
![](/i/fill.gif) |