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


Java Combo.setVisibleItemCount方法代碼示例

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


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

示例1: ComboBox

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
public ComboBox(Composite composite, String message, String [] options,
        String[] commentTemplates) {
    
    fMessage= message;
    fComments= options;
    fCommentTemplates = commentTemplates;
    
    fCombo = new Combo(composite, SWT.READ_ONLY);
    fCombo.setLayoutData(SWTUtils.createHFillGridData());
    fCombo.setVisibleItemCount(20);
    
    // populate the previous comment list
    populateList();
    
    // We don't want to have an initial selection
    // (see bug 32078: http://bugs.eclipse.org/bugs/show_bug.cgi?id=32078)
    fCombo.addFocusListener(this);
    fCombo.addSelectionListener(this);
}
 
開發者ID:subclipse,項目名稱:subclipse,代碼行數:20,代碼來源:CommitCommentArea.java

示例2: createParentMandatoryGroup

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void createParentMandatoryGroup(final Group parent) {
    final GridLayout gridLayout = new GridLayout();
    gridLayout.marginHeight = 10;

    final GridData gridData = new GridData();
    gridData.horizontalAlignment = GridData.FILL;
    gridData.grabExcessHorizontalSpace = true;

    final Group group = new Group(parent, SWT.NONE);
    group.setLayout(gridLayout);
    group.setLayoutData(gridData);
    group.setText(ResourceString.getResourceString("label.mandatory"));

    parentCardinalityCombo = new Combo(group, SWT.NONE);
    parentCardinalityCombo.setLayoutData(gridData);

    parentCardinalityCombo.setVisibleItemCount(5);

    parentCardinalityCombo.add(Relation.PARENT_CARDINALITY_1);

    if (!relation.getForeignKeyColumns().get(0).isPrimaryKey()) {
        parentCardinalityCombo.add(Relation.PARENT_CARDINALITY_0_OR_1);
    }
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:25,代碼來源:RelationDialog.java

示例3: createChildMandatoryGroup

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void createChildMandatoryGroup(final Group parent) {
    final GridLayout gridLayout = new GridLayout();
    gridLayout.marginHeight = 10;

    final GridData gridData = new GridData();
    gridData.grabExcessHorizontalSpace = true;
    gridData.horizontalAlignment = GridData.FILL;

    final Group group = new Group(parent, SWT.NONE);
    group.setLayout(gridLayout);
    group.setLayoutData(gridData);
    group.setText(ResourceString.getResourceString("label.mandatory"));

    childCardinalityCombo = new Combo(group, SWT.NONE);
    childCardinalityCombo.setLayoutData(gridData);

    childCardinalityCombo.setVisibleItemCount(5);

    childCardinalityCombo.add("1..n");
    childCardinalityCombo.add("0..n");
    childCardinalityCombo.add(Relation.CHILD_CARDINALITY_1);
    childCardinalityCombo.add("0..1");
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:24,代碼來源:RelationDialog.java

示例4: createParentMandatoryGroup

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void createParentMandatoryGroup(Group parent) {
	GridLayout gridLayout = new GridLayout();
	gridLayout.marginHeight = 10;

	GridData gridData = new GridData();
	gridData.horizontalAlignment = GridData.FILL;
	gridData.grabExcessHorizontalSpace = true;

	Group group = new Group(parent, SWT.NONE);
	group.setLayout(gridLayout);
	group.setLayoutData(gridData);
	group.setText(ResourceString.getResourceString("label.mandatory"));

	parentCardinalityCombo = new Combo(group, SWT.NONE);
	parentCardinalityCombo.setLayoutData(gridData);

	parentCardinalityCombo.setVisibleItemCount(5);

	parentCardinalityCombo.add(Relation.PARENT_CARDINALITY_1);

	if (!this.relation.getForeignKeyColumns().get(0).isPrimaryKey()) {
		parentCardinalityCombo.add(Relation.PARENT_CARDINALITY_0_OR_1);
	}
}
 
開發者ID:kozake,項目名稱:ermaster-k,代碼行數:25,代碼來源:RelationDialog.java

示例5: createChildMandatoryGroup

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void createChildMandatoryGroup(Group parent) {
	GridLayout gridLayout = new GridLayout();
	gridLayout.marginHeight = 10;

	GridData gridData = new GridData();
	gridData.grabExcessHorizontalSpace = true;
	gridData.horizontalAlignment = GridData.FILL;

	Group group = new Group(parent, SWT.NONE);
	group.setLayout(gridLayout);
	group.setLayoutData(gridData);
	group.setText(ResourceString.getResourceString("label.mandatory"));

	childCardinalityCombo = new Combo(group, SWT.NONE);
	childCardinalityCombo.setLayoutData(gridData);

	childCardinalityCombo.setVisibleItemCount(5);

	childCardinalityCombo.add("1..n");
	childCardinalityCombo.add("0..n");
	childCardinalityCombo.add(Relation.CHILD_CARDINALITY_1);
	childCardinalityCombo.add("0..1");
}
 
開發者ID:kozake,項目名稱:ermaster-k,代碼行數:24,代碼來源:RelationDialog.java

示例6: createControl

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
@Override
public void createControl(final Composite parent) {
    final Composite composite = new Composite(parent, SWT.NULL);

    final GridLayout layout = new GridLayout();
    layout.numColumns = 2;
    composite.setLayout(layout);

    final Label label = new Label(composite, SWT.NULL);
    label.setText(ResourceString.getResourceString("label.database"));

    databaseCombo = new Combo(composite, SWT.BORDER | SWT.READ_ONLY);
    final GridData dbData = new GridData(GridData.FILL_HORIZONTAL);
    dbData.widthHint = 200;
    databaseCombo.setLayoutData(dbData);
    databaseCombo.setVisibleItemCount(10);

    for (final String db : DBManagerFactory.getAllDBList()) {
        databaseCombo.add(db);
    }

    databaseCombo.addModifyListener(new ModifyListener() {
        @Override
        public void modifyText(final ModifyEvent e) {
            validatePage();
        }
    });

    databaseCombo.setFocus();

    validatePage();

    setControl(composite);
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:35,代碼來源:NewDiagramWizardPage2.java

示例7: createEngineCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
public static Combo createEngineCombo(final Composite parent, final AbstractDialog dialog) {
    final Combo combo = CompositeFactory.createCombo(dialog, parent, "label.storage.engine", 1);
    combo.setVisibleItemCount(20);

    initEngineCombo(combo);

    return combo;
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:9,代碼來源:MySQLAdvancedComposite.java

示例8: initializeTypeCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void initializeTypeCombo(final Combo combo) {
    combo.setVisibleItemCount(20);

    combo.add("");

    final String database = diagram.getDatabase();

    for (final String alias : SqlType.getAliasList(database)) {
        combo.add(alias);
    }
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:12,代碼來源:EditAllAttributesDialog.java

示例9: initializeWordCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void initializeWordCombo(final Combo combo) {
    combo.setVisibleItemCount(20);

    combo.add("");

    wordList = copyContents.getDictionary().getWordList();
    Collections.sort(wordList);

    for (final Word word : wordList) {
        combo.add(Format.null2blank(word.getLogicalName()));
    }
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:13,代碼來源:EditAllAttributesDialog.java

示例10: createColumnCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void createColumnCombo(final Composite parent) {
    final GridData gridData = new GridData();
    gridData.horizontalAlignment = GridData.FILL;
    gridData.grabExcessHorizontalSpace = true;

    columnCombo = new Combo(parent, SWT.READ_ONLY);
    columnCombo.setLayoutData(gridData);

    columnCombo.setVisibleItemCount(20);

    columnComboInfo = setReferencedColumnComboData(columnCombo, (ERTable) relation.getSourceTableView());
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:13,代碼來源:RelationDialog.java

示例11: initCategoryCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
protected void initCategoryCombo(final Combo categoryCombo) {
    categoryCombo.add(ResourceString.getResourceString("label.all"));

    for (final Category category : categoryList) {
        categoryCombo.add(category.getName());
    }

    categoryCombo.setVisibleItemCount(20);
}
 
開發者ID:roundrop,項目名稱:ermasterr,代碼行數:10,代碼來源:AbstractExportDialog.java

示例12: createEngineCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
public static Combo createEngineCombo(Composite parent,
		AbstractDialog dialog) {
	Combo combo = CompositeFactory.createCombo(dialog, parent,
			"label.storage.engine", 1);
	combo.setVisibleItemCount(20);

	initEngineCombo(combo);

	return combo;
}
 
開發者ID:kozake,項目名稱:ermaster-k,代碼行數:11,代碼來源:MySQLAdvancedComposite.java

示例13: initializeTypeCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void initializeTypeCombo(Combo combo) {
	combo.setVisibleItemCount(20);

	combo.add("");

	String database = this.diagram.getDatabase();

	for (String alias : SqlType.getAliasList(database)) {
		combo.add(alias);
	}
}
 
開發者ID:kozake,項目名稱:ermaster-k,代碼行數:12,代碼來源:EditAllAttributesDialog.java

示例14: initializeWordCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
private void initializeWordCombo(Combo combo) {
	combo.setVisibleItemCount(20);

	combo.add("");

	this.wordList = this.copyContents.getDictionary().getWordList();
	Collections.sort(this.wordList);

	for (Word word : this.wordList) {
		combo.add(Format.null2blank(word.getLogicalName()));
	}
}
 
開發者ID:kozake,項目名稱:ermaster-k,代碼行數:13,代碼來源:EditAllAttributesDialog.java

示例15: initCategoryCombo

import org.eclipse.swt.widgets.Combo; //導入方法依賴的package包/類
protected void initCategoryCombo(Combo categoryCombo) {
	categoryCombo.add(ResourceString.getResourceString("label.all"));

	for (Category category : this.categoryList) {
		categoryCombo.add(category.getName());
	}

	categoryCombo.setVisibleItemCount(20);
}
 
開發者ID:kozake,項目名稱:ermaster-k,代碼行數:10,代碼來源:AbstractExportDialog.java


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