本文整理了Java中org.eclipse.swt.widgets.Table.layout()
方法的一些代码示例,展示了Table.layout()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Table.layout()
方法的具体详情如下:
包路径:org.eclipse.swt.widgets.Table
类名称:Table
方法名:layout
暂无
代码示例来源:origin: pentaho/pentaho-kettle
table.layout( true, true );
代码示例来源:origin: pentaho/pentaho-kettle
table.layout();
table.pack();
代码示例来源:origin: io.sarl/io.sarl.eclipse
this.sresList.getTable().layout(true);
restoreColumnWidths(settings);
this.sortColumn = Column.NAME;
代码示例来源:origin: org.eclipse/org.eclipse.jdt.debug.ui
/**
* Restore table settings from the given dialog store using the
* given key.
*
* @param settings dialog settings store
* @param qualifier key to restore settings from
*/
public void restoreColumnSettings(IDialogSettings settings, String qualifier) {
fVMList.getTable().layout(true);
restoreColumnWidths(settings, qualifier);
try {
fSortColumn = settings.getInt(qualifier + ".sortColumn"); //$NON-NLS-1$
} catch (NumberFormatException e) {
fSortColumn = 1;
}
switch (fSortColumn) {
case 1:
sortByName();
break;
case 2:
sortByLocation();
break;
case 3:
sortByType();
break;
}
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Sets the font of the Node 1 TreeItems in column 1.
*/
void setCellFont () {
if (!instance.startup) {
textNode1.setFont (1, cellFont);
imageNode1.setFont (1, cellFont);
}
/* Set the font item's image to match the font of the item. */
Font ft = cellFont;
if (ft == null) ft = textNode1.getFont (1);
TableItem item = colorAndFontTable.getItem(CELL_FONT);
Image oldImage = item.getImage();
if (oldImage != null) oldImage.dispose();
item.setImage (fontImage(ft));
item.setFont(ft);
colorAndFontTable.layout ();
}
代码示例来源:origin: com.github.rinde/rinsim-pdptw
@Override
public void initializePanel(Composite parent) {
parent.setLayout(new FillLayout());
table = new Table(parent, SWT.BORDER | SWT.SINGLE);
final TableColumn tc1 = new TableColumn(table, 0);
tc1.setText("Vehicle");
tc1.setWidth(COLUMN_WIDTH_PX);
final TableColumn tc2 = new TableColumn(table, 0);
tc2.setText("Route length");
tc2.setWidth(COLUMN_WIDTH_PX);
final TableColumn tc3 = new TableColumn(table, 0);
tc3.setText("Route");
tc3.setWidth(COLUMN_WIDTH_PX);
table.setHeaderVisible(true);
for (final RouteFollowingVehicle v : list) {
createItem(v);
}
table.layout();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Sets the font of the Node 1 TreeItems.
*/
void setItemFont () {
if (!instance.startup) {
textNode1.setFont (itemFont);
imageNode1.setFont (itemFont);
}
/* Set the font item's image to match the font of the item. */
Font ft = itemFont;
if (ft == null) ft = textNode1.getFont ();
TableItem item = colorAndFontTable.getItem(ITEM_FONT);
Image oldImage = item.getImage();
if (oldImage != null) oldImage.dispose();
item.setImage (fontImage(ft));
item.setFont(ft);
colorAndFontTable.layout ();
}
代码示例来源:origin: rinde/RinSim
@Override
public void initializePanel(Composite parent) {
parent.setLayout(new FillLayout());
table = new Table(parent, SWT.BORDER | SWT.SINGLE);
final TableColumn tc1 = new TableColumn(table, 0);
tc1.setText("Vehicle");
tc1.setWidth(COLUMN_WIDTH_PX);
final TableColumn tc2 = new TableColumn(table, 0);
tc2.setText("Route length");
tc2.setWidth(COLUMN_WIDTH_PX);
final TableColumn tc3 = new TableColumn(table, 0);
tc3.setText("Route");
tc3.setWidth(COLUMN_WIDTH_PX);
table.setHeaderVisible(true);
for (final RouteFollowingVehicle v : list) {
createItem(v);
}
table.layout();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Sets the font of the "Example" widgets.
*/
void setExampleWidgetFont () {
if (colorAndFontTable == null) return; // user cannot change color/font on this tab
Control [] controls = getExampleControls ();
if (!instance.startup) {
for (Control control : controls) {
control.setFont(font);
}
}
/* Set the font item's image and font to match the font of the example widget(s). */
Font ft = font;
if (controls.length == 0) return;
if (ft == null) ft = controls [0].getFont ();
TableItem item = colorAndFontTable.getItem(FONT);
Image oldImage = item.getImage();
if (oldImage != null) oldImage.dispose();
item.setImage (fontImage (ft));
item.setFont(ft);
colorAndFontTable.layout ();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Sets the font of TableItem 0.
*/
void setItemFont () {
if (!instance.startup) {
table1.getItem (0).setFont (itemFont);
}
/* Set the font item's image to match the font of the item. */
Font ft = itemFont;
if (ft == null) ft = table1.getItem (0).getFont ();
TableItem item = colorAndFontTable.getItem(ITEM_FONT);
Image oldImage = item.getImage();
if (oldImage != null) oldImage.dispose();
item.setImage (fontImage(ft));
item.setFont(ft);
colorAndFontTable.layout ();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Sets the font of the Row 0 TableItem in column 1.
*/
void setCellFont () {
if (!instance.startup) {
table1.getItem (0).setFont (1, cellFont);
}
/* Set the font item's image to match the font of the item. */
Font ft = cellFont;
if (ft == null) ft = table1.getItem (0).getFont (1);
TableItem item = colorAndFontTable.getItem(CELL_FONT);
Image oldImage = item.getImage();
if (oldImage != null) oldImage.dispose();
item.setImage (fontImage(ft));
item.setFont(ft);
colorAndFontTable.layout ();
}
代码示例来源:origin: org.eclipse/org.eclipse.ajdt.ui
table.getSelection()[0].setData(selection);
table.layout();
代码示例来源:origin: org.eclipse.platform/org.eclipse.swt.examples
/**
* Sets the font of CTabItem 0.
*/
void setItemFont () {
if (!instance.startup) {
tabFolder1.getItem (0).setFont (itemFont);
setExampleWidgetSize();
}
/* Set the font item's image to match the font of the item. */
Font ft = itemFont;
if (ft == null) ft = tabFolder1.getItem (0).getFont ();
TableItem item = colorAndFontTable.getItem(ITEM_FONT);
Image oldImage = item.getImage();
if (oldImage != null) oldImage.dispose();
item.setImage (fontImage(ft));
item.setFont(ft);
colorAndFontTable.layout ();
}
}
内容来源于网络,如有侵权,请联系作者删除!