• 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: NSTableView RowHeight and font vertical alignment
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTableView RowHeight and font vertical alignment


  • Subject: Re: NSTableView RowHeight and font vertical alignment
  • From: Frank Midgley <email@hidden>
  • Date: Mon, 15 Nov 2004 18:41:36 -0600

On Nov 15, 2004, at 3:44PM, Byron Wright wrote:

I currently have a tableview that has a row height of 40. The text being displayed in my rows is always vertically aligned to the top of the row. Is there a constant I can use to vertically align the text in my rows to the middle? I can't seem to find a way to do this with the NSTableView.

I don't believe AppKit currently supports this. The easiest way to do this would be to make an NSCell subclass and override -drawInteriorWithFrame:inView: to draw the string vertically centered. Then tell each column in the table to use your subclass for its dataCell.


-Frank

------------------------------------
Frank M. Midgley
email@hidden
http://homepage.mac.com/knarf/

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: NSTableView RowHeight and font vertical alignment
      • From: Byron Wright <email@hidden>
References: 
 >NSTableView RowHeight and font vertical alignment (From: Byron Wright <email@hidden>)

  • Prev by Date: Re: Access instance var from NSValueTransformer
  • Next by Date: Re: Access instance var from NSValueTransformer
  • Previous by thread: NSTableView RowHeight and font vertical alignment
  • Next by thread: Re: NSTableView RowHeight and font vertical alignment
  • Index(es):
    • Date
    • Thread