Questions tagged [nstablecolumn]

The NSTableColumn class stores the display characteristics and attribute identifier for a column in an NSTableView instance.

The NSTableColumn class stores the display characteristics and attribute identifier for a column in an NSTableView instance.

More: NSTableColumn Class Reference

82 questions
2
votes
1 answer

Text colors in an NSTableColumn on highlight

I've got an column of cells in an NSTableView that get their text color from the app's preference plist. I want to set the text color to white when highlighted, but have been unable to figure out a good way to do this. Anybody got any ideas?
Allyn
  • 20,271
  • 16
  • 57
  • 68
2
votes
2 answers

NSTableView visual issue

Can someone tell me what might cause this white rectangle in the column to appear? Thanks. Thanks! EDIT: If i resize that table column it goes away.
user635064
  • 6,219
  • 12
  • 54
  • 100
2
votes
1 answer

NSTableColumn auto resize only the first column

I have an NSTableView with 4 columns. I want to change the auto resizing properties of the first NSTableColumn. If the user resizes the app, only the first column is allowed to change his width. My code : // First 3 columns similar to the 4th…
Bruno
  • 87
  • 1
  • 9
2
votes
1 answer

Problem retrieving NSCell data via [NSTableColumn dataCellForRow]

I am trying to retrieve a specific NSCell data from an NSTableView through [NSTableColumn dataCellForRow] but every time it shows different value for same row and same column. The data source remains the same at all time. The NSTableView is bound to…
Omayr
  • 1,949
  • 4
  • 22
  • 35
2
votes
2 answers

How to refresh an NSTableVIew when you populate the NSMutableArray (bind) associated with it

I tried to bind my NSArraycontroller to an NSMutableArray; the array holds objects of type "iData" (it's a custom class). The class further contains some NSMutableString variables which are set as keys for KVC. Then I bound the my NSTableColumn to…
2
votes
1 answer

NSTableView doesn't display return value of objectValueForTableColumn method

It doesn't matter what I return, the table view will display only display text that is manually set (the 'Title' of the NSTextField) in the .xib file. Please help me figure out what I'm doing wrong. Thanks. My NSTableView only has 1 column. Here is…
AyushISM
  • 381
  • 7
  • 21
2
votes
1 answer

How to set the column name of an NSTableColumn in a view-based NSTableView?

I've created an NSTableView programmatically and added a single column (an instance of NSTableColumn). How can I set the name of this column (by default it's named "Field")? In NSTableColumn there's a method with signature -…
2
votes
1 answer

How to make NSTableView column fit its content on resize?

Im my app I have NSTableView (view based) and when I add the value that is too long to the last column first it "hits" the scroller then when I resize the window the row is not getting resized to fit the content does anyone know how to deal with…
Eugene Gordin
  • 4,047
  • 3
  • 47
  • 80
2
votes
2 answers

How can I bind to NSTableColumn's headerTitle?

I would like to bind NSTableColumn's headerTitle property to an NSMutableArray in my model layer (via an NSArrayController). Basically I want to have an array where I can change values and have the table column header titles update. Is that…
Daniel Farrell
  • 9,316
  • 8
  • 39
  • 62
2
votes
1 answer

Checkbox on table column won't register click

I've a table view to which I add columns dynamically. It must be done this way because I can't predict how many or which columns I will need. Some columns are checkboxes but I can't click on them when I run my application. The column and checkbox…
ruipacheco
  • 15,025
  • 19
  • 82
  • 138
2
votes
2 answers

Custom NSCell in NStableColumn and Cocoa Bindings?

I'm currently trying to use Cocoa Bindings to populate a NSTableView using Cocoa Bindings. I encounter a major problem with some columns where I use custom NSCell subclass. My XIB file contains a NStableView and a NSArrayController. In interface…
yageek
  • 4,115
  • 3
  • 30
  • 48
2
votes
0 answers

Adding columns to an NSTableView

I'm attempting to add columns dynamically to an NSTableView but they don't display anything: NSTableColumn *col = [[NSTableColumn alloc] initWithIdentifier:@"test"]; [[col headerCell] setStringValue:@"Header"]; [myTableView…
Drew
  • 12,578
  • 11
  • 58
  • 98
2
votes
1 answer

How do I bind an NSTableColumn to NSArrayController arrangedObjects programmatically?

So i have an NSTableView with dynamic NSTableColumns. The columns should get it's data from an NSArrayController's arrangedObject. Since everything is dynamic, I can't really use the interface builder to bind values. How do I do this…
ssj
  • 881
  • 1
  • 10
  • 21
1
vote
1 answer

About the automatic table column identifier

I have create a NSTableView and 2 NSTableColumn in the view. Both of the identifiers of these 2 NSTableColumn set to "Automatic" in Interface Builder. In the method: (NSView *)tableView:(NSTableView *)tableView viewForTableColumn:(NSTableColumn…
Ruoxin Wang
  • 13
  • 1
  • 6
1
vote
1 answer

JTable - why doesn't it keep the TableColumns after adding a row?

I'm using a JTable : public class MyPanel extends JPanel { public MyPanel () { init() } init () { DataModel model = new DataModel(); JTable table = new JTable (model); TableColumnModel tcm = agentsTable.getColumnModel(); …
Adi Mor
  • 2,145
  • 5
  • 25
  • 44