• 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 row-based, not redrawing on 10.9
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTableview row-based, not redrawing on 10.9


  • Subject: Re: NSTableview row-based, not redrawing on 10.9
  • From: Martin Hewitson <email@hidden>
  • Date: Fri, 25 Oct 2013 21:07:07 +0200

Implementing this doesn’t seem to make any difference. I checked that it is called. In any case, the release notes say that responsive scrolling is not active if you link against 10.7, which I do.

Martin

On 25 Oct 2013, at 08:47 pm, Michael Cinkosky <email@hidden> wrote:

> I believe you need to implement a new delegate method for this table:
>
> +(BOOL) isCompatibleWithResponsiveScrolling {
> 	return NO;
> }
>
> https://developer.apple.com/library/prerelease/mac/releasenotes/AppKit/RN-AppKit/index.html#//apple_ref/doc/uid/TP30000741-CH2-SW28
>
> Michael
>
>
>
>
> On Oct 25, 2013, at 12:41 PM, Martin Hewitson <email@hidden> wrote:
>
>> Dear list,
>>
>> I have a view-based tableview. In the row views there are some textfields which are a subclass of NSTextField. Since moving to 10.9, the textfields which are in rows which are out of view when the table loads are rendered all black when those rows are scrolled into view. This is new behaviour. Is this supposed to happen? In other words, did I miss some changes in the release notes which indicate I should do things differently now? Clicking in the offending textfields causes them to then draw properly. The reason I have subclassed NSTextField is because I draw them in different colours depending on the colour of the row background they are embedded in. My drawRect: is below, in case there is something fishy in there that might be causing this.
>>
>> Any one else seen this behaviour?
>>
>> Thanks,
>>
>> Martin
>>
>>
>> - (void)drawRect:(NSRect)dirtyRect
>> {
>> 	NSView *superview = [self superview];
>> 	[self setTextColor:[NSColor blackColor]];
>> 	if ([superview respondsToSelector:@selector(startingColor)]) {
>> 		NSColor *c = [superview performSelector:@selector(startingColor)];
>> 		[self setTextColor:[c contrastingLabelColor]];
>> 		[self setDrawsBackground:NO];
>>   		NSBezierPath *path = [NSBezierPath bezierPathWithRoundedRect:NSInsetRect([self bounds], 0.5, 0.5) xRadius:5.0 yRadius:5.0];
>>   		[[c shadowWithLevel:0.1] set];
>>   		[path stroke];
>> 		if (mouseOver) {
>> 			[[c highlightWithLevel:0.2] set];
>> 			[path fill];
>> 		}
>> 		if ([[self currentEditor] respondsToSelector:@selector(setInsertionPointColor:)]) {
>> 			[[self currentEditor] performSelector:@selector(setInsertionPointColor:) withObject:[c contrastingLabelColor]];
>> 		}
>> 	}
>> 	[super drawRect:dirtyRect];
>> }
>> _______________________________________________
>>
>> Cocoa-dev mailing list (email@hidden)
>>
>> Please do not post admin requests or moderator comments to the list.
>> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>>
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Martin Hewitson
Albert-Einstein-Institut
Max-Planck-Institut fuer
    Gravitationsphysik und Universitaet Hannover
Callinstr. 38, 30167 Hannover, Germany
Tel: +49-511-762-17121, Fax: +49-511-762-5861
E-Mail: email@hidden
WWW: http://www.aei.mpg.de/~hewitson
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~






_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: NSTableview row-based, not redrawing on 10.9
      • From: Martin Hewitson <email@hidden>
References: 
 >NSTableview row-based, not redrawing on 10.9 (From: Martin Hewitson <email@hidden>)
 >Re: NSTableview row-based, not redrawing on 10.9 (From: Michael Cinkosky <email@hidden>)

  • Prev by Date: Re: Not documented: NSArray responds to -allObjects
  • Next by Date: MKLaunchOptionsMapTypeKey in OS X Mavericks
  • Previous by thread: Re: NSTableview row-based, not redrawing on 10.9
  • Next by thread: Re: NSTableview row-based, not redrawing on 10.9
  • Index(es):
    • Date
    • Thread