當前位置: 首頁>>代碼示例>>Java>>正文


Java Text.setSize方法代碼示例

本文整理匯總了Java中org.eclipse.swt.widgets.Text.setSize方法的典型用法代碼示例。如果您正苦於以下問題:Java Text.setSize方法的具體用法?Java Text.setSize怎麽用?Java Text.setSize使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在org.eclipse.swt.widgets.Text的用法示例。


在下文中一共展示了Text.setSize方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: initialize

import org.eclipse.swt.widgets.Text; //導入方法依賴的package包/類
/**
 * This method initializes this
 * 
 */
private void initialize() {
	XpathTrigger trigger = (parent.getTrigger() instanceof XpathTrigger)?(XpathTrigger)parent.getTrigger():null;
       GridData gridData2 = new GridData();
       gridData2.horizontalAlignment = GridData.FILL;
       gridData2.grabExcessHorizontalSpace = true;
       gridData2.verticalAlignment = GridData.CENTER;
       GridLayout gridLayout = new GridLayout();
       gridLayout.numColumns = 2;
       this.setLayout(gridLayout);
       xpath_label = new Label(this, SWT.NONE);
       xpath_label.setText("Waiting for Xpath");
       xpath_txt = new Text(this, SWT.BORDER);
       xpath_txt.setText( (trigger!=null)? trigger.getXPath():"");
       xpath_txt.setLayoutData(gridData2);
       xpath_txt.setSize(600, 50);
}
 
開發者ID:convertigo,項目名稱:convertigo-eclipse,代碼行數:21,代碼來源:HttpTriggerXpathEditorComposite.java

示例2: createAssitTextBox

import org.eclipse.swt.widgets.Text; //導入方法依賴的package包/類
private void createAssitTextBox(Point cursorRelativePosition) {
	assistText = new Text((Composite) graphicControl, SWT.BORDER);
	assistText.setLocation(cursorRelativePosition.x, cursorRelativePosition.y - assistText.getLineHeight());
	assistText.setSize(200, assistText.computeSize(SWT.DEFAULT, SWT.DEFAULT).y);
	assistText.setTextLimit(51);
	assistText.setFocus();
}
 
開發者ID:capitalone,項目名稱:Hydrograph,代碼行數:8,代碼來源:ComponentSearchUtility.java

示例3: relocate

import org.eclipse.swt.widgets.Text; //導入方法依賴的package包/類
@Override
public void relocate(CellEditor celleditor) {
	Text text=(Text)celleditor.getControl();
	Rectangle box=this.transitionLabelEditPart.getFigure().getBounds();
	text.setLocation(box.x,box.y);	
	text.setSize(box.width,box.height);
}
 
開發者ID:bsteker,項目名稱:bdf2,代碼行數:8,代碼來源:TransitionLabelCellEditorLocator.java


注:本文中的org.eclipse.swt.widgets.Text.setSize方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。