Package org.eclipse.jface.fieldassist

Examples of org.eclipse.jface.fieldassist.ComboContentAdapter


        Arrays.sort( allAtNames );

        // attribute combo with field decoration and content proposal
        attributeTypeCombo = BaseWidgetUtils.createCombo( composite, allAtNames, -1, 1 );
        attributeTypeCombo.setText( initialValue );
        new ExtendedContentAssistCommandAdapter( attributeTypeCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( attributeTypeCombo.getItems() ), null, null, true );

        applyDialogFont( composite );
        return composite;
    }
View Full Code Here


    UIUtils
        .addBulbDecorator(combo,
            UIText.CommitCombo_showSuggestedCommits);

    ContentProposalAdapter adapter = new ContentProposalAdapter(combo,
        new ComboContentAdapter(), new CommitContentProposalProvider(),
        null, null);
    adapter.setPropagateKeys(true);
    adapter
        .setProposalAcceptanceStyle(ContentProposalAdapter.PROPOSAL_REPLACE);
  }
View Full Code Here

    // 3.4)
    final Combo combo = new Combo(parent, SWT.DROP_DOWN);
    final ControlDecoration decoration = new ControlDecoration(combo,
        SWT.BOTTOM | SWT.LEFT);
    final ContentAssistCommandAdapter proposal = new ContentAssistCommandAdapter(
        combo, new ComboContentAdapter(), proposalProvider, null, null,
        true);
    proposal
        .setProposalAcceptanceStyle(ContentProposalAdapter.PROPOSAL_REPLACE);
    if (listener != null)
      proposal.addContentProposalListener(listener);
View Full Code Here

    GridData data = new GridData(GridData.FILL, GridData.FILL, true, false,
        1, 1);
    data.widthHint = convertWidthInCharsToPixels(50);
    patternCombo.setLayoutData(data);

    ComboContentAdapter contentAdapter = new ComboContentAdapter();
    FindReplaceDocumentAdapterContentProposalProvider findProposer = new FindReplaceDocumentAdapterContentProposalProvider(
        true);
    patternFieldContentAssist = new ContentAssistCommandAdapter(
        patternCombo, contentAdapter, findProposer,
        ITextEditorActionDefinitionIds.CONTENT_ASSIST_PROPOSALS,
View Full Code Here

      };
    }

    /* Combo */
    else if (control instanceof Combo) {
      fComboAdapter = new ComboContentAdapter() {
        @Override
        public Rectangle getInsertionBounds(Control control) {
          Rectangle bounds = super.getInsertionBounds(control);

          /* Bug on Mac: Insertion Bounds off by some pixels */
 
View Full Code Here

    fPattern.setFont(group.getFont());
    GridData data = new GridData(GridData.FILL, GridData.FILL, true, false, 1, 1);
    data.widthHint = convertWidthInCharsToPixels(50);
    fPattern.setLayoutData(data);

    ComboContentAdapter contentAdapter = new ComboContentAdapter();
    FindReplaceDocumentAdapterContentProposalProvider findProposer = new FindReplaceDocumentAdapterContentProposalProvider(
        true);
    fPatterFieldContentAssist = new ContentAssistCommandAdapter(fPattern, contentAdapter,
        findProposer, ITextEditorActionDefinitionIds.CONTENT_ASSIST_PROPOSALS, new char[0], true);
    fPatterFieldContentAssist.setEnabled(fIsRegExSearch);
View Full Code Here

                fTextField.setItems(previousReplaceWith);
                fTextField.select(0);
            }
        }

        ComboContentAdapter contentAdapter = new ComboContentAdapter();
        IContentProposalProvider replaceProposer = null;

        //the code below is so that this works in Eclipse 3.3.
        try {
            //new FindReplaceDocumentAdapterContentProposalProvider(false);
View Full Code Here

        attributeTypeCombo = ( Combo ) attributeTypeComboField.getControl();
        attributeTypeCombo.setItems( possibleAttributeTypes );
        attributeTypeCombo.setText( parsedAttributeType );

        // content proposal adapter
        attributeTypeCPA = new ContentProposalAdapter (attributeTypeCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( attributeTypeCombo.getItems() ), null, null );
        attributeTypeCPA.setFilterStyle( ContentProposalAdapter.FILTER_NONE );
        attributeTypeCPA.setProposalAcceptanceStyle( ContentProposalAdapter.PROPOSAL_REPLACE )

        BaseWidgetUtils.createSpacer( composite, 1 );
View Full Code Here

        GridData gd = new GridData();
        gd.widthHint = 180;
        rdnLine.rdnNameComboField.getLayoutControl().setLayoutData( gd );
        rdnLine.rdnNameCombo = ( Combo ) rdnLine.rdnNameComboField.getControl();

        rdnLine.rdnNameCPA = new ContentProposalAdapter( rdnLine.rdnNameCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( attributeNames ), null, null );
        rdnLine.rdnNameCPA.setFilterStyle( ContentProposalAdapter.FILTER_NONE );
        rdnLine.rdnNameCPA.setProposalAcceptanceStyle( ContentProposalAdapter.PROPOSAL_REPLACE );

        rdnLine.rdnEqualsLabel = new Label( rdnComposite, SWT.NONE );
View Full Code Here

        modSpec.modAttributeCombo = ( Combo ) modSpec.modAttributeComboField.getControl();
        modSpec.modAttributeCombo.setItems( attributeDescriptions );
        modSpec.modAttributeCombo.addModifyListener( this );

        // content proposal adapter
        modSpec.modAttributeCPA = new ContentProposalAdapter( modSpec.modAttributeCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( attributeDescriptions ), null, null );
        modSpec.modAttributeCPA.setFilterStyle( ContentProposalAdapter.FILTER_NONE );
        modSpec.modAttributeCPA.setProposalAcceptanceStyle( ContentProposalAdapter.PROPOSAL_REPLACE );

        // add button with listener
View Full Code Here

TOP

Related Classes of org.eclipse.jface.fieldassist.ComboContentAdapter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.