LDraw.org Discussion Forums
Re: Spaces in filenames - Printable Version

+- LDraw.org Discussion Forums (https://forums.ldraw.org)
+-- Forum: Models and Parts (https://forums.ldraw.org/forum-18.html)
+--- Forum: Parts Authoring (https://forums.ldraw.org/forum-19.html)
+--- Thread: Re: Spaces in filenames (/thread-1477.html)

Re: Spaces in filenames - Tore Eriksson - 2011-11-23

Travis Cobbs Wrote:
> Michael Heidemann pointed out that the newly created OMR spec requires that filenames contain spaces,
> while the pre-existing LDraw 1.0.0 spec strongly discourages spaces or tabs in filenames.
> He (quite rightly, in my opinion) felt that this was inconsistent.
> So, the way I see it, we have three choices:
> 1. Ignore the problem.
> 2. Remove the discouragement text from the LDraw standard.
> 3. Change the OMR standard so that the filenames don't include spaces.
> My vote is to do go with option 2, at least for spaces.

I very strongly disagree. The space character is the way LDraw separates arguments.

Before taking such a giant leap in the LDraw evolution to accept spaces in file names (if so only in OMR MPD's) has anyone ever considered the consequences? How many of our programs and utilities in use will be rendered useless by this reform? Just because maybe noone in the LSC is using them doesn't mean that noone else uses and needs them.

And what if a space character is accidently placed at the end of a type one line, invisible for us humans but how will various softwares handle it? Is "3001.dat " equal to "3001.dat"? And I have this habit of normally add an extra space before the file reference, in order to make it easier to read. Will that lead to a reference to the non-existing " 3001.dat"?


Re: Spaces in filenames - Travis Cobbs - 2011-11-23

I believe that a check was made in the past, and the main LDraw-based software didn't have a problem with spaces in filenames. Having said that, I have two items:
  • The LDraw spec does not currently prohibit spaces, but merely strongly discourages them. As such, support for spaces in filenames in LDraw compatible software is required by the spec, and has been required by the spec since 2007.
  • Users expect spaces to work, and MLCAD allows them without any kind of warning. Since users aren't going to read the spec, the discouragement there seems pointless.

Re: Spaces in filenames - Don Heyse - 2011-11-23

According to this MLCAD ignores leading and trailing whitespace, so that's the defacto standard.

It also lets you put quotes in your filenames, which seems weird, but oh well.

Re: Spaces in filenames - Tore Eriksson - 2011-11-23

Good. MLCAD is ONE program in huge the LDraw family... Wink
L3P also supports quotation marks, LDView doesn't. At least, not the version I use (v4.1, 3 dec 2009).