Bug 86979 - Add computeSize (or computeWidth?) method for TableColumn
Summary: Add computeSize (or computeWidth?) method for TableColumn
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows 2000
: P3 enhancement with 2 votes (vote)
Target Milestone: ---   Edit
Assignee: Steve Northover CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-02 06:02 EST by Henning Rogge CLA
Modified: 2019-09-06 15:34 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Henning Rogge CLA 2005-03-02 06:02:22 EST
TableColumn has only the method pack() to calculate the preffered width of the
cell. Unfortunately pack() immediately sets the columns width to the "preffered"
value, which is not good if you plan to manage the column size yourself.

It would be good if the first part of pack() ( the calculation of the preffered
width ) could be extracted into a method of it's own.

public int getPreferredWidth() {
   // first part of old pack method

   return width;
}

public void pack() {
   int width = getPrefferedWidth();

   // set column width
}
Comment 1 Steve Northover CLA 2005-04-04 18:35:18 EDT
Not for 3.1.
Comment 2 Michael Seele CLA 2007-05-25 04:07:29 EDT
is there a chance to get it in 3.3 or 3.4?
Comment 3 Steve Northover CLA 2007-05-25 07:49:56 EDT
Not at this late stage in Eclipse 3.3.
Comment 4 Michael Seele CLA 2007-05-25 08:22:18 EDT
3.4? ;-)
Comment 5 Magnus Konze CLA 2009-03-02 04:42:54 EST
3.5? ;-)

I would like to have this method (getPreferredWidth()) too. My Tablemodel contains preferred sizes for columns, but i want to compare them with the preferred Width of the TableColumn.
Comment 6 Eclipse Webmaster CLA 2019-09-06 15:29:49 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.
Comment 7 Eclipse Webmaster CLA 2019-09-06 15:34:55 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.