public void UpdateColumn(ListViewColumn col, object handle, ListViewColumnChange change) { NSTableColumn tcol = (NSTableColumn)handle; var c = CellUtil.CreateCell(ApplicationContext, Table, this, col.Views, cols.IndexOf(tcol)); tcol.DataCell = c; }
public void UpdateColumn(ListViewColumn col, object handle, ListViewColumnChange change) { NSTableColumn tcol = (NSTableColumn)handle; switch (change) { case ListViewColumnChange.CanResize: tcol.ResizingMask = col.CanResize ? NSTableColumnResizing.UserResizingMask : NSTableColumnResizing.Autoresizing; break; case ListViewColumnChange.Cells: var c = CellUtil.CreateCell(ApplicationContext, Table, this, col.Views, cols.IndexOf(tcol)); c.Alignment = col.Alignment.ToNSTextAlignment(); tcol.DataCell = c; break; case ListViewColumnChange.Title: tcol.HeaderCell.Title = col.Title ?? string.Empty; if (!col.CanResize) { tcol.SizeToFit(); } break; case ListViewColumnChange.Alignment: tcol.HeaderCell.Alignment = col.Alignment.ToNSTextAlignment(); break; } }
public virtual NSTableColumn AddColumn (ListViewColumn col) { var tcol = new NSTableColumn (); tcol.Editable = true; cols.Add (tcol); var c = CellUtil.CreateCell (ApplicationContext, Table, this, col.Views, cols.Count - 1); tcol.DataCell = c; Table.AddColumn (tcol); var hc = new NSTableHeaderCell (); hc.Title = col.Title ?? ""; tcol.HeaderCell = hc; Widget.InvalidateIntrinsicContentSize (); return tcol; }
public virtual object AddColumn(ListViewColumn col) { var tcol = new NSTableColumn(); cols.Add(tcol); var c = CellUtil.CreateCell(this, col.Views); tcol.DataCell = c; Table.AddColumn(tcol); var hc = new NSTableHeaderCell(); hc.Title = col.Title; tcol.HeaderCell = hc; return(tcol); }
public virtual object AddColumn(ListViewColumn col) { var tcol = new NSTableColumn(); cols.Add(tcol); var c = CellUtil.CreateCell(this, col.Views); tcol.DataCell = c; Table.AddColumn(tcol); var hc = new NSTableHeaderCell(); hc.Title = col.Title ?? ""; tcol.HeaderCell = hc; Widget.InvalidateIntrinsicContentSize(); return(tcol); }
public virtual NSTableColumn AddColumn(ListViewColumn col) { var tcol = new NSTableColumn(); tcol.Editable = true; cols.Add(tcol); var c = CellUtil.CreateCell(ApplicationContext, Table, this, col.Views, cols.Count - 1); tcol.DataCell = c; Table.AddColumn(tcol); var hc = new NSTableHeaderCell(); hc.Title = col.Title ?? ""; tcol.HeaderCell = hc; tcol.HeaderCell.Alignment = col.Alignment.ToNSTextAlignment(); tcol.ResizingMask = col.CanResize ? NSTableColumnResizing.UserResizingMask : NSTableColumnResizing.Autoresizing; tcol.SizeToFit(); Widget.InvalidateIntrinsicContentSize(); return(tcol); }
public void UpdateColumn(ListViewColumn col, object handle, ListViewColumnChange change) { NSTableColumn tcol = (NSTableColumn)handle; tcol.DataCell = CellUtil.CreateCell(this, col.Views); }