• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
What type of view for a simple editable list?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

What type of view for a simple editable list?


  • Subject: What type of view for a simple editable list?
  • From: Jerry Krinock <email@hidden>
  • Date: Tue, 17 Feb 2004 21:31:45 -0800

Hi,

In my application I want to give the user a field in which to enter an
arbitrary number of short words or phrases, for example:

brocolli
peanut butter
CD-ROM

So I made an NSTextView which seems to work pretty well; after reading in
the textStorage I separate each line into a separate string using
componentsSeparatedByString at "\n", which gives me an NSArray of strings,
which is what I want.

But then I thought, gee this is inappropriate to use this text-oriented
field when the user is actually giving me a list of items. So, I made an
NSTableView with one column. This seems more "appropriate", but it looks
like there is no way for the user to type in more items. I'd have to put a
"Add New Item" button which would add an empty string to the data source,
which the user would then click on to edit.

So now I think I had it right the first time with the NSTextView.

Am I missing something? What kind of view would you use for something like
this?

Jerry Krinock
_______________________________________________
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.

  • Follow-Ups:
    • Re: What type of view for a simple editable list?
      • From: Daniel Todd Currie <email@hidden>
    • Re: What type of view for a simple editable list?
      • From: Scott Anguish <email@hidden>
References: 
 >Sorting NSTableView with NSDictionary objects in Panther (From: Roberto Sobachi <email@hidden>)

  • Prev by Date: Re: General Question: Debugging these "NS" Objects: Answered
  • Next by Date: Re: What type of view for a simple editable list?
  • Previous by thread: Re: Sorting NSTableView with NSDictionary objects in Panther
  • Next by thread: Re: What type of view for a simple editable list?
  • Index(es):
    • Date
    • Thread