• 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
Re: word-wrap in cells of an NSTableView?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: word-wrap in cells of an NSTableView?


  • Subject: Re: word-wrap in cells of an NSTableView?
  • From: cricket <email@hidden>
  • Date: Sat, 15 May 2004 00:03:22 -0700

Perhaps there are other ways to do this, but I usually use an attributed string. One of the attributes you can set on an attributed string is the NSParagraphStyleAttributeName. A paragraph style can have a line-break mode. There is a chart of possible line-break modes in this document:

http://developer.apple.com/documentation/Cocoa/Reference/ ApplicationKit/ObjC_classic/Classes/NSParagraphStyle.html

NSLineBreakByWordWrapping is probably the one you want.

- cricket

On May 14, 2004, at 11:18 PM, Steven D.Arnold wrote:

I have an NSTableView which contains one column, and each cell is an example sentence, which can be at least somewhat long. I would like each cell in the NSTableView to word-wrap, so that the right-hand side of the text is not obscured. I haven't been able to find an easy way to do this -- any ideas?

---------->
My so-called life. To go.
_______________________________________________
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: word-wrap in cells of an NSTableView?
      • From: Erik Hanson <email@hidden>
    • Re: word-wrap in cells of an NSTableView?
      • From: Mark Munz <email@hidden>
References: 
 >word-wrap in cells of an NSTableView? (From: "Steven D.Arnold" <email@hidden>)

  • Prev by Date: word-wrap in cells of an NSTableView?
  • Next by Date: Loading fonts with kATSFontContextGlobal
  • Previous by thread: word-wrap in cells of an NSTableView?
  • Next by thread: Re: word-wrap in cells of an NSTableView?
  • Index(es):
    • Date
    • Thread