Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Technology Project and PMC » Cannot center image in table column
Cannot center image in table column [message #592444] Thu, 03 April 2003 15:00
Laurent Gauthier is currently offline Laurent GauthierFriend
Messages: 2
Registered: October 2009
Junior Member
I am trying to center images in a table column but no cigar!

It is always left aligned!

Centering text is no problem.

Here is a code snippet:
TableColumn column5 = new TableColumn(table, SWT.CENTER);

I am using a TableViewer and subclassed CheckboxCellEditor so that layout
data would be SWT.CENTER but that does not work either.

Here is the CCheckboxCellEditor class:

public class CCheckboxCellEditor extends CheckboxCellEditor {
public CCheckboxCellEditor(Composite parent) {
* @return the layout data object
public LayoutData getLayoutData() {
LayoutData result = new LayoutData();
result.horizontalAlignment = SWT.CENTER;
return result;
Previous Topic:Cannot center image in table column
Next Topic:Eclipse won't open!
Goto Forum:

Current Time: Sun Apr 14 01:55:46 GMT 2024

Powered by FUDForum. Page generated in 0.04661 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top