• 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
Odd tooltip behavior in NSTableView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Odd tooltip behavior in NSTableView


  • Subject: Odd tooltip behavior in NSTableView
  • From: Dustin Wenz <email@hidden>
  • Date: Wed, 15 Jun 2005 16:21:00 -0500

I have an nstableview with a modest number of rows and columns. Some of the cell contents can be quite long, so I need a tooltip to display the entire cell contents when the cursor hovers over it. Should be trivial right? I just implement this in my delegate:

- (NSString *)tableView:(NSTableView *)aTableView toolTipForCell:(NSCell *)aCell rect:(NSRectPointer)rect tableColumn:(NSTableColumn *)aTableColumn row:(int)row mouseLocation:(NSPoint)mouseLocation
{
    return [aCell stringValue];
}

That mostly works. Unfortunately, the tooltips stop working when the user clicks too many times in the table. If the user clicks once in the tableview, nothing is affected and the toolTipForCell delegate method still gets invoked properly. If the user clicks twice or more (it usually takes at least four clicks) in the table, the method no longer gets called for any cell that the cursor then rests over. Functionality can be restored by moving the cursor out of the table rectangle and then back in over a cell, after which the tooltips start working again.

Is this normal behavior? If it is, it seems really inconsistent and confusing.


    Dustin Wenz

    IS Companies

    320.534.5112


 _______________________________________________
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: Odd tooltip behavior in NSTableView
      • From: Corbin Dunn <email@hidden>
References: 
 >NSTextView - calculating current col (with tabs) (From: Duncan Campbell <email@hidden>)

  • Prev by Date: Re: Call a void on a controller from main.m
  • Next by Date: NSUserDefaults and non-property-list objects
  • Previous by thread: NSTextView - calculating current col (with tabs)
  • Next by thread: Re: Odd tooltip behavior in NSTableView
  • Index(es):
    • Date
    • Thread