NSScrollView displays problems in Xcode 5 after scrolling

NSScrollView displays an NSTableView based on a custom view (image, checkbox, and text label). When I scroll - I have a lag (error?) With redrawing lines.

Normal: Normal

Scanned after scrolling: Bugged after scroll

The project (and the .xib file) has been upgraded from Xcode 4 to Xcode 5. I think this error appeared after it, but I'm not sure.

Any suggestions for fixing it?

Protocol implementation NSTableViewDataSource, NSTableViewDelegate:

 - (NSInteger) numberOfRowsInTableView: (NSTableView *) aTableView { return [arrayOfObjects count]; } - (NSView *)tableView:(NSTableView *)tableView viewForTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row { CMListItem *currentObject = [arrayOfObjects objectAtIndex: row]; NSString *currentName = [currentObject name]; BOOL currentState = [currentObject state]; NSImage *currentImage = [currentObject getArtwork]; NSString *identifier = [tableColumn identifier]; if ([identifier isEqualToString:@"MainCell"]) { CMTableCellView *cellView = [tableView makeViewWithIdentifier: identifier owner: self]; cellView.textField.stringValue = currentName; cellView.button.state = currentState; cellView.imageView.image = currentImage; return cellView; } return nil; } 

NSScrollView not changed. My own view of a table cell is a subclass of NSTableCellView with a few extra outputs.

UPDATE: this thing helped me: set Can Draw Concurrently for all NSTableView in the On state, then put it in the Off state.

+4
source share
1 answer

I think that sometimes I saw this problem when the "Copy to scroll" option is enabled. Try disabling this option in IB (in the attribute inspector, in the scroll section, behavior).

+3
source

All Articles