Re: C: treated as a path component

2009-04-15 Thread Keary Suska
On Apr 14, 2009, at 5:57 PM, Dragan Milić wrote: Hell all, Let's suppose I've got NSString @C:omponent , which represents the name of a file. Is there a way to instruct NSString class not to treat a leading single letter followed by a column as a path separator? Namely, I need this one

Re: C: treated as a path component

2009-04-15 Thread Charles Srstka
On Apr 15, 2009, at 10:51 AM, Keary Suska wrote: On Apr 14, 2009, at 5:57 PM, Dragan Milić wrote: Hell all, Let's suppose I've got NSString @C:omponent , which represents the name of a file. Is there a way to instruct NSString class not to treat a leading single letter followed by a

Re: C: treated as a path component

2009-04-15 Thread Greg Guerin
Charles Srstka wrote: I tried this, and it doesn't seem to have anything to do with HFS+ paths, as Cocoa abstracts colons away into slashes there anyway. What's more, it only does this if you have only one letter before the colon, as in @C:omponent. If you use @CC:omponent instead, it

Re: C: treated as a path component

2009-04-15 Thread Jean-Daniel Dupas
Le 15 avr. 09 à 01:57, Dragan Milić a écrit : Hell all, Let's suppose I've got NSString @C:omponent , which represents the name of a file. Is there a way to instruct NSString class not to treat a leading single letter followed by a column as a path separator? Namely, I need this one

Re: C: treated as a path component

2009-04-15 Thread Steve Christensen
On Apr 15, 2009, at 1:34 PM, Jean-Daniel Dupas wrote: Le 15 avr. 09 à 01:57, Dragan Milić a écrit : Hell all, Let's suppose I've got NSString @C:omponent , which represents the name of a file. Is there a way to instruct NSString class not to treat a leading single letter followed by a

Fwd: C: treated as a path component

2009-04-15 Thread Jeremy W. Sherman
You could also use basename(3) instead of Cocoa/CF calls. Since it could modify the passed-in string, you'll need to either use -[NSString getFileSystemRepresentation:maxLength:] or copy the string returned by -[NSString fileSystemRepresentation]. Of course, if you're worried about the path

C: treated as a path component

2009-04-14 Thread Dragan Milić
Hell all, Let's suppose I've got NSString @C:omponent , which represents the name of a file. Is there a way to instruct NSString class not to treat a leading single letter followed by a column as a path separator? Namely, I need this one treated as only one path component @C:omponent,