Re: number formatting
Re: number formatting
- Subject: Re: number formatting
- From: email@hidden
- Date: Fri, 22 Feb 2002 12:56:51 -0800
This is not a bug (it is a side-effect of using floating point
precision).
I don't agree with that. An object as big as a TextField (and intended
for users that don't know anything about IEEE floats) should know how to
handle truncation effects; even without a formatter. The fact is, the
behavior has been in Cocoa for 5 years or so, many people comment on it,
no one has done anything about it.
Um... nobody has done anything about it because it's not regarded as a
bug, would be my guess. :-> Modularity of design is good. If you want
your value formatted, use an NSFormatter. If you want a cheaper
solution, use setStringValue: and format the string yourself. But
building in code in NSTextfield that lets you set things like the
precision, the exponent format, etc. would be an exceedingly bad design,
IMHO.
Ben Haller
Stick Software
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.