Skip to main content



      Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Table gridlines & headers misaligned
Table gridlines & headers misaligned [message #460816] Thu, 08 September 2005 01:05 Go to next message
Eclipse UserFriend
Developing with Win2K, SWT 3.1 (swt-win32-3138.dll), Table gridlines do not
align correctly with column headers. That is, vertical gridlines do not
align with the black grid that surrounds header "buttons". Rather, they
appear to be shifted one pixel to the right, aligning with the button
highlight. This is probably a strictly cosmetic issue, but it creates a
jarring visual effect.

I could not find this listed with Bugzilla, but wanted to check with others
before submitting a bug report. I'm still relatively new to SWT, and wanted
to make sure I'm not overlooking a property setting. (Test source appears
below.)

Thanks,

Eric Adamson
Lansing, MI


import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.*;
import org.eclipse.swt.graphics.*;

public class TableGridlines {

public static void main(String[] args) {

Display d = new Display();
Shell s = new Shell(d);

s.setBounds(200, 200, 500, 300);
s.setText("SWT-Win32 Table Gridlines \"Bug\"");
s.open();

Rectangle r = s.getClientArea();
Table t = new Table(s, SWT.BORDER);
t.setBounds(15, 15, r.width-30, r.height-30);
t.setLinesVisible(true);
t.setHeaderVisible(true);

for (int i=0; i<6; i++) {
TableColumn tc = new TableColumn(t, SWT.CENTER);
tc.setText("Column " + (i+1));
tc.setWidth(t.getClientArea().width/6);
}

while (!d.isDisposed()) {
if (!d.readAndDispatch()) {
d.sleep();
}
}

d.dispose();

}

}
Re: Table gridlines & headers misaligned [message #460833 is a reply to message #460816] Thu, 08 September 2005 09:09 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: ddana78ar.yahoo.com.ar

you are right, I have the same problem.
Re: Table gridlines & headers misaligned [message #460871 is a reply to message #460816] Fri, 09 September 2005 06:11 Go to previous message
Eclipse UserFriend
Sounds like a good bug to report; you've got sample code showing the problem which you can upload as an attachment, so raise a bug :-) It's because of hard-working users of Eclipse that such things get noted and fixed.
Previous Topic:DnD Drag behavour on Table control
Next Topic:how to build interface similar to eclipse ide
Goto Forum:
  


Current Time: Thu Jul 03 19:16:43 EDT 2025

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

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

Back to the top