On 2006-06-08 17:57:22 +0200 Nate Smith <[EMAIL PROTECTED]> wrote:
So when I run it, and enter in:
Hi\n

That is four (4) characters you entered

It prints out:
output: |Hi\n|

So four (4) characters are printed,

but I want it to print out:
output: |Hi
|

and not three (3) as you would want it to.

I could always manually parse the output, and if a "\n" is found, then
really print a newline, but that seems a bit too muddled. Any ideas?

How is your program, or rather any of the functions/methods supposed to know that you want your two character entry '\n' to be a one character entry '(new line)' ?

Take a look at eg NSString-rangeOfString: you can use to 'parse' your input string and 'scan' for the two characters '\n'

--
Chris



_______________________________________________
Discuss-gnustep mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/discuss-gnustep

Reply via email to