Restricting input to NSTextViewCell inside NSMatrix - objective-c

Objecive-C/Cocoa newbie...I have an NSMatrix composed of NSTextViewCells. I would like the user to be able to type at most one letter into each cell, have the letter upcased if necessary, and automatically tab to the next field.
It looks to me as if I can use an NSFormatter to do the upcasing, but I can't figure out how to get the auto-tabbing.
Is it just me, or is the available documentation in general less than wonderful? I've been reading Hillegass' book, which is great, but it only goes as far as it goes :)
Thanks.

Related

How to create "menu grid" in kotlin

I have searched google/stackoverflow etc. for answer to my question, but I didn't quite manage to find the right one. I believe I just don't know, how to set the question properly, and thus I cannot find solution.
Is there any way, how to create grid like I drawed in following image (with red colour):
I need to add this red grid to several images, which look very simmilar. The grid field (the one selected) have rolling menu, prescribed position, and a field for additional text. Black lines in background are image in background, and the red supposed to be grid above the image. I thought of creating a lot of buttons alined to each other, but i think that is very bad way to do so.
I would like a pop-up menu from selected field, but opening new activity with same fields is usable aswell. Is there any "simple" solution for creating such grid/menu ?
Btw, I am not programmer with many experience with coding, let's say, I know basics only.
Thanks in advance.

How can I replicate a user created table?

This is a part of the iTunes smart playlist creation window; for my application I need to create something very similar to this:
The changes I'll be making would be the column that says artist would be integers (but still a pop up button), same with the second column. The third column would be text input like in the picture. I would like to keep the functionality of the "+" and "-" buttons but I don't have much use for the "..." button. Is there any easy way to recreate this? I need the user to be able to add as many or few fields as necessary.
Thanks in advance!
If you don't need to support 10.4, take a look at NSPredicateEditor. It should allow you to easily recreate iTunes' interface with the changes you describe. http://nvie.com/posts/nspredicateeditor-tutorial/ may be useful to help you get started.

Formatted Text and Popovers in iOS4

I'm working on a prototype app that has a challenging behavior. I thought I'd ask for advice before really tearing into it...
Part of the app has an area of text that needs to be formatted in a manner where there will be a description of an item in bold, followed by one or more detail items:
Item Description: Item Detail 1. Item Detail 2. Item Detail N.
In most cases these items will require multiple lines, so word wrapping will be necessary.
The the user will be able to tap on any bolded item description to expose a popover with options they can select that will populate the plain item details.
I was about to attempt doing this with a webview, to be able to format the text, provide natural word wrapping and use hyperlinks to call methods, etc... As I look into this more, I can see it will be a pretty weighty task and want to make sure there aren't alternatives to this before I head down what looks like a fairly long, dark tunnel.
I'm still fairly new to iOS dev, so bear with me if I come back with "noob" questions.
Thanks in advance!
The alternative is Core Text but it is a fairly long, dark tunnel, too.

spell check textfield

I am trying to get a spellchecker to check spelling in a text field as the user types. I am well aware that browsers such as firefox have this feature for textfields (but this requires a user to manually enable it in the right click menu.
The ideal script Im looking for would accept an id as a parameter, since the id for the field I want to be checked cannot change.
Thanks
My suggestion would to look at a predictive text tool, similar to the tag-finder that SO uses where you have a dictionary, and as a term is typed, you do some kind of AJAX-y lookup to see if they're typing correctly.
Adding a new word would be similar to adding new tags on SO - if the predicted word is not picked, add it to your dictionary.
I'm sure there are others who have done a similar task, though - and this suggestion might be harder to implement than in sounds in my head.

NSFormCell for content other than text

I am building a dynamic form in a Cocoa application and am planning to use the NSForm object to add entries to it from an array.
Some of the entries require a text input, but some require a boolean input (i.e. a dropdown list), and some even require a file input (i.e. a place to upload an image or a movie or sound file).
It seems that an NSFormCell is only equipped to handle text. My question is: Should I subclass NSFormCell and if so, what would be the best way to do this? Are there any better ways to do this?
Thank you for any help you can offer!
You might want to look into using an NSMatrix instead. From the NSForm documentation, NSForm is simply a subclass of NSMatrix with some convenience methods geared specifically towards creating a text form in a certain configuration.
NSMatrix will let you use any cell you want for any cell (using the putCell:atRow:column: method). Thus, you could have a two-column matrix, with the left column being composed entirely of text cells, and the right column being whatever type of cell you want.
As I haven't dealt much with NSForm myself (and haven't heard of NSFormCell before), I would personally use an NSMatrix for this task, adding the appropriate cells (NSTextFieldCell, NSButtonCell, NSPopUpButtonCell, etc) where necessary. Though I've not done this exactly in the same way as you describe before, I'm sure it should work.
-Steven Degutis
Edit: My goodness, looks like Matt Ball beat me to it. Thanks, Stackoverflow.com's-3-minute-limit-for-newbs! :D