The NSTableCellView class of Cocoa, is a reusable container view shown for a particular cell in an NSTableView instance that uses rows for content.
Questions tagged [nstablecellview]
124 questions
2
votes
2 answers
NSTableCellView transparent background
In my custom NSTableCellView I override -(void)drawRect this way (I do this because I have pattern image background of NSWindow. I need to show only NSLabel in cellView):
- (void)drawRect:(NSRect)dirtyRect
{
[[NSColor clearColor] setFill];
…

Almas Adilbek
- 4,371
- 10
- 58
- 97
2
votes
1 answer
Can't CTRL+Drag NSButton to custom NSView header
I'd like to create a custom NSTableCellView instantiated by Interface Builder. I've set my Table Cell View class to MyTableCellView, and properly created MyTableCellView : NSTableCellView .m/.h files.
However, I just can't CTRL+Drag a simple button…

ldiqual
- 15,015
- 6
- 52
- 90
1
vote
0 answers
NSTableCellView custom draw text with CGBlendMode.exclusion
I have a custom NSTableCellView where the background of the cell has a colored bar that changes length from 0-100% based on the value of the text in the cell (it's part of a dynamic bar graph in the table). The problem is that depending on the…

Jc Nolan
- 450
- 4
- 15
1
vote
1 answer
How to disable accessibility voiceover on NSTableView for Mac OS using Swift
Tried the following so far and it doesn't work:
cellView?.setAccessibilityElement(false)
cellView?.setAccessibilityEnabled(false)
Both the above are getting called within tableView(_:viewFor:row:)
Any help would be greatly appreciated.

as diu
- 1,010
- 15
- 31
1
vote
0 answers
NSOutlineView: sometimes a row is not editable (just beeps)
I have a view-based NSOutlineView configured with a dataSource and delegate. It consists of two columns a custom NSTableCellView class.
Entries in the outline view are editable by selecting a row and pressing the Return key. Everything is set up…

Mark
- 6,647
- 1
- 45
- 88
1
vote
1 answer
NSOutlineView Selected Text Color Not Working in Swift
Swift 4, macOS 10.13
I have an NSOutlineView and I'm trying to customize the look of each row when the user clicks it.
I have a view-based NSTableCellView subclass that I'm using for the cell. When I override backgroundStyle, the icon change works…

Clifton Labrum
- 13,053
- 9
- 65
- 128
1
vote
0 answers
Focus (nextKeyView) in a tableview flowing from line to line
In my example I have tableview
@IBOutlet weak var tableview: NSTableView!
if for example the second textfield in line 2 "Dr" has the focus, I want to focus the first textfield in line 3 "tom" after a "tab"
I can do it "explicitly" row for row in…

mica
- 3,898
- 4
- 34
- 62
1
vote
1 answer
MakeViewWithIdentifier:owner: returns nil
When I attempt to construct a view per row for my view-based NSTableView the method makeViewWithIdentifier:owner: always returns nil. The table is build in IB and all seems to be linked properly, the delegate methods are all called as I'd expect.…

Mark Hasselbach
- 31
- 6
1
vote
1 answer
How to create a NSTableview with custom viewcells
I tried many different ways to create a NSTableview with custom NSTableCellView but I could not make it work. The question is, how can I do that thing?
Here is the last thing I tried:
func tableView(tableView: NSTableView, viewForTableColumn…

Rafa Febrer
- 184
- 14
1
vote
2 answers
Invert button image in selected table view row
What I'd like to have is that when a row in my view-based table view is selected, the images (or button images) get inverted, like in Safari:
I already have a button with the NSStopProgressFreestandingTemplate image (), but nothing happens when the…

Nickkk
- 2,261
- 1
- 25
- 34
1
vote
1 answer
NSTableCellView shows nothing if it's a group cell
I'm trying to make a simple view-based NSTableView with groups and regular cells. Every cell is drawn correct and shows everything I need unless I add this method to my NSTableViewDelegate/DataSource:
func tableView(tableView: NSTableView,…

Andrii Liakh
- 619
- 3
- 16
1
vote
0 answers
Dynamic TableviewCell heights in Cocoa (Mac)
I am trying to archive a similar behavior to what the Twitter for Mac App has.
It has TableViewCells of dynamic height that properly resize if the user resizes the whole window.
I started using an NSTableView with view based TableViewCells.
Now my…

Georg
- 3,664
- 3
- 34
- 75
1
vote
1 answer
setObjectValue:nil not called to deleted NSTableCellView
I'm using a View Based NSTableView and binding to display content of my objects.
When I delete one of them, the tableView reflect the change, by removing the cell for this object.
The problem is that the NSTableCellView doesn't receive the…

vtruant
- 273
- 1
- 12
1
vote
1 answer
NSTableView setup to automatically resize middle column?
Is it possible to set up a NSTableView with e.g. 4 columns in IB to allow just one column to resize when the table grows?
So far I couldn't achieve this with neither Resizing: Autoresizes or decreasing content hugging value for the TableCellView in…

ATV
- 4,116
- 3
- 23
- 42
1
vote
1 answer
Multiple NSTextFields in NSTableCellView; only first can be edited directly
I have multiple NSTextFields in my NSTableCellView:
With a double-click action, I call [self.outlineView editColumn:0 row:clickedRow withEvent:nil select: YES]; which works in activating editing in the first text field. I have also setup…

Z S
- 7,039
- 12
- 53
- 105