Community
Participate
Working Groups
The type, completion, and priority columns of the Task list using the native table widget on MacOS X are much wider than are necessary for displaying the icons in those columns and appear not to be resizable.
These values are hard coded in TaskList. Note also that the native table does not yet support images in the column headers. Need the same fix as for GTK. Moving to Platform UI team.
Veronika, the current code only sets the width to 19, so they should not be that wide. I think there is an SWT or OS problem here too.
i will make the change to the images in the table headers, but.. veronika: the mac seems to make these columns about 40 pixels wide at least, which doesn't have to do with the tasklist hardcoding anything, i don't think.
McQ approves fix to change header to use text instead of icon on mac.
On the Mac, there is exta space in the header to the left and right of the text/image. Currently it is using the width of the image + 25 pixels. When you have text, it will be the width of the text + 25 pixels. Without the + 25 pixels, nothing will be displayed in the column header (or the text will be truncated with ...). This is the native table behaviour.
veronika: on mac apps this behavior doesn't seem to happen: imail, itunes, etc. all use the table with correct (i.e. 'small') column widths. how do we get that behavior?
i have put the text back in the 2nd and 3rd column as requested. passing to SWT to get us table columns with widths like itunes, imail, etc.
*** Bug 58000 has been marked as a duplicate of this bug. ***
Can we get a quick list of steps to reproduce the issue? What SWT control is being leveraged here? What is the underlying Carbon API?
The widget is the DataBrowser. Run the following example. If you are running against 3.1 M6 (or earlier), you will see that the column is much wider than the image. If you are running with the latest SWT from HEAD for 3.1, you will see that the column is as wide as the image but that the image is clipped and does not show the whole thing. public static void main (String [] args) { Display display = new Display (); Shell shell = new Shell (display); Table table = new Table(shell, SWT.BORDER); TableColumn column = new TableColumn(table, SWT.NONE); TableItem item = new TableItem(table, SWT.NONE); Image image = display.getSystemImage(SWT.ICON_ERROR); item.setImage(image); Rectangle imageSize = image.getBounds(); column.setWidth(imageSize.width); table.pack(); shell.open (); while (!shell.isDisposed ()) { if (!display.readAndDispatch ()) display.sleep (); } display.dispose (); } There are few carbon API involved but the ones that stand out are: SetDataBrowserTableViewNamedColumnWidth (parent.handle, id, (short) width); Also in the SWT Table there is a drawItemProc where the image and text are being drawn. This is installed on the DataBrowser using SetDataBrowserCustomCallbacks.
The SWT widget is org.eclipse.swt.widgets.Table.
On Tiger and later, developers can use the DataBrowserSetMetric API to customize the amount of extra space Data Browser uses around cell content.
Fixed > 20050824. Only on Tiger.