Interface Builder's User Defined Runtime Attributes not accepting floats?

2.4k Views Asked by At

I created an NSView subclass that has a float property and I'd like to set it in Interface Builder. In the User Defined Runtime Attributes section the only suitable Type is Number. But if I want to enter a decimal number (either using . or , as delimiter) it just rounds to the nearest integer. Is this a bug or on purpose? How can I define a float instead of an Integer?

1

There are 1 best solutions below

6
On BEST ANSWER

Use a string type and enter your value like this

0.7