www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.dwt - Table.setHeaderVisible(true)does not work

Hi BB & Frank,

Sorry for so many questions to ask.As subjected,Table.setHeaderVisible(true)
does not show the table header,below is the source:
//******************************
module testTable;

import dwt.DWT;
import dwt.widgets.Display;
import dwt.widgets.Shell;
import dwt.layout.FillLayout;
import dwt.widgets.Table;
import dwt.widgets.TableItem;
import dwt.widgets.TableColumn;

int main(char[][] args)
{
	
	Display display=new Display;
	Shell shell=new Shell(display);
	shell.setLayout(new FillLayout);
		
	Table table=new Table(shell,DWT.BORDER);
		
		
	TableColumn tbc1=new TableColumn(table,DWT.CENTER);
	tbc1.setText("First Name");
	tbc1.setWidth(100);
		
	TableColumn tbc2=new TableColumn(table,DWT.CENTER);
	tbc2.setText("Last Name");
	tbc2.setWidth(100);
		
	TableColumn tbc3=new TableColumn(table,DWT.CENTER);
	tbc3.setText("Address");
	tbc3.setWidth(120);
		
	table.setHeaderVisible(true);
	table.setLinesVisible(true);
		
	shell.open;
		
	while(! shell.isDisposed)
	{
		if(! display.readAndDispatch)
		display.sleep;
	}
	display.dispose;
		
		

	return 0;
}
//************************
I don't know why.
Thanks.
Sam
Sep 09 2008