Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 355911 - TableEditor.grabVertical is not modifiable through CellEditor.getLayoutData
Summary: TableEditor.grabVertical is not modifiable through CellEditor.getLayoutData
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.6.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-26 01:16 EDT by Christian Kloner CLA
Modified: 2019-11-14 03:10 EST (History)
1 user (show)

See Also:


Attachments
Patch for CellEditor, TableViewerEditor and TreeViewerEditor (2.49 KB, patch)
2011-08-26 01:55 EDT, Christian Kloner CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Kloner CLA 2011-08-26 01:16:45 EDT
Build Identifier: 3.6.1

Aligning a CellEdtior's control to the top, center or bottom of a table cell is not possible because API is incomplete (LayoutData.grabVertical was forgotten to be implemented).

In the class org.eclipse.swt.custom.TableEditor, the method computeBounds() calculates the bounds of the CellEditor's control that is going to be shown.
This calculation depends on the ControlEditor's properties grabHorizontal, minimumWidth, grabVertical and minimumHeight and are filled through ColumnViewerEditor.setLayoutData(CellEditor.LayoutData). The LayoutData is got from the CellEditor to open. Unfortunately the LayoutData that is returned by CellEditor.getLayoutData() does only define the property grabHorizontal but NOT grabVertical. 
As result, the value of LayoutData.minimumHeight cannot be used to center or align a celleditor's control whose height must not be the height of the table's cell.


Reproducible: Always
Comment 1 Christian Kloner CLA 2011-08-26 01:55:08 EDT
Created attachment 202198 [details]
Patch for CellEditor, TableViewerEditor and TreeViewerEditor

grabVertical field was added to the CellEditor.LayoutData and was got through TableViewerEditor and TreeViewerEditor so that the existing grapVertical field of TableEditor and TreeEditor can be assigned with the correct value.
Comment 2 Lars Vogel CLA 2019-11-14 03:10:39 EST
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.

If the bug is still relevant, please remove the "stalebug" whiteboard tag.