Namaste! I've got a custom formatter for limiting text input to a certain-length string. I did this because the default delayed message of "<attribute> is too long" isn't exactly a good way to keep our users from shooting themselves in the foot (though I AM glad it is there). Also, writing validation methods for each and every attribute that could have a length issue seems ridiculous too.
I'd like to instantiate this formatter in IB and connect it via "rubber bands" to the formatter outlet for each affected text field. This to avoid lots of coding otherwise. However, each affected text field may have a different allowable length. So, to facilitate that (and not create a formatter for each desired length), the formatter has a settable property to determine the correct length. Right now, this is all done through code (IBOutlets to each field, setFormatter, etc.). My original thought was to hopefully instantiate the formatter via an IB Object (the blue cube). However, the property isn't exposed (I suspected it wouldn't be). My overall question is: How do I expose that property in IB? To create this formatter for use in IB, should I go the route of a plug-in? I do have several apps in which this could be useful, and the answer to the other two questions are "no" as well. I started looking into that. -OR- Is it possible to simply instantiate the object with a settable property? And where may I find documentation that describes the particular process of exposing the property so IB can see it (if other than creating a plug-in) and thus allowing setting? As a side note, has anyone requested of Apple that some sort of min or maxLength properties be made available? That would be a really good default property to have on any sort of text field! Thanks in advance! Peace, Love, and Light, /s/ Jon C. Munson II _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com