Package org.eclipse.jface.preference

Examples of org.eclipse.jface.preference.ColorSelector


        fColorEditorLabel.setText(PreferencesMessages.ErlEditorPreferencePage_color);
        gd = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);
        gd.horizontalIndent = 20;
        fColorEditorLabel.setLayoutData(gd);

        fSyntaxForegroundColorEditor = new ColorSelector(stylesComposite);
        final Button foregroundColorButton = fSyntaxForegroundColorEditor.getButton();
        gd = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);
        foregroundColorButton.setLayoutData(gd);
        new Label(stylesComposite, SWT.NONE);
View Full Code Here


    // text color label
    Label colorText = new Label(settingsComposite, SWT.NONE);
    colorText.setText("Color:");

    mColorSelector = new ColorSelector(settingsComposite);
    mColorSelector.setEnabled(false);
    mColorSelector.addListener(new IPropertyChangeListener() {
      public void propertyChange(PropertyChangeEvent event) {
        if (mCurrentSelectedAnnotation == null) {
          mCurrentSelectedAnnotation = getDefaultAnnotation();
View Full Code Here

        Composite stylesComposite = BaseWidgetUtils.createColumnContainer( editorComposite, 1, 1 );
        stylesComposite.setLayoutData( new GridData( GridData.FILL_BOTH ) );
        Composite colorComposite = BaseWidgetUtils.createColumnContainer( stylesComposite, 2, 1 );
        BaseWidgetUtils.createLabel( colorComposite, Messages
            .getString( "LdifEditorSyntaxColoringPreferencePage.Color" ), 1 ); //$NON-NLS-1$
        colorSelector = new ColorSelector( colorComposite );
        boldCheckBox = BaseWidgetUtils.createCheckbox( stylesComposite, Messages
            .getString( "LdifEditorSyntaxColoringPreferencePage.Bold" ), 1 ); //$NON-NLS-1$
        italicCheckBox = BaseWidgetUtils.createCheckbox( stylesComposite, Messages
            .getString( "LdifEditorSyntaxColoringPreferencePage.Italic" ), 1 ); //$NON-NLS-1$
        strikethroughCheckBox = BaseWidgetUtils.createCheckbox( stylesComposite, Messages
View Full Code Here

        consoleGroup.setLayoutData( new GridData( SWT.FILL, SWT.NONE, true, false ) );

        // Debug
        Label debugLabel = new Label( consoleGroup, SWT.NONE );
        debugLabel.setText( Messages.getString( "ColorsAndFontsPage.Debug" ) ); //$NON-NLS-1$
        debugColorButton = new ColorSelector( consoleGroup );
        debugColorButton.getButton().setLayoutData( new GridData( SWT.RIGHT, SWT.NONE, true, false ) );
        debugBoldCheckbox = new Button( consoleGroup, SWT.CHECK );
        debugBoldCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Bold" ) ); //$NON-NLS-1$
        debugItalicCheckbox = new Button( consoleGroup, SWT.CHECK );
        debugItalicCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Italic" ) ); //$NON-NLS-1$

        // Info
        Label infoLabel = new Label( consoleGroup, SWT.NONE );
        infoLabel.setText( Messages.getString( "ColorsAndFontsPage.Info" ) ); //$NON-NLS-1$
        infoColorButton = new ColorSelector( consoleGroup );
        infoColorButton.getButton().setLayoutData( new GridData( SWT.RIGHT, SWT.NONE, true, false ) );
        infoBoldCheckbox = new Button( consoleGroup, SWT.CHECK );
        infoBoldCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Bold" ) ); //$NON-NLS-1$
        infoItalicCheckbox = new Button( consoleGroup, SWT.CHECK );
        infoItalicCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Italic" ) ); //$NON-NLS-1$

        // Warn
        Label warnLabel = new Label( consoleGroup, SWT.NONE );
        warnLabel.setText( Messages.getString( "ColorsAndFontsPage.Warn" ) ); //$NON-NLS-1$
        warnColorButton = new ColorSelector( consoleGroup );
        warnColorButton.getButton().setLayoutData( new GridData( SWT.RIGHT, SWT.NONE, true, false ) );
        warnBoldCheckbox = new Button( consoleGroup, SWT.CHECK );
        warnBoldCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Bold" ) ); //$NON-NLS-1$
        warnItalicCheckbox = new Button( consoleGroup, SWT.CHECK );
        warnItalicCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Italic" ) ); //$NON-NLS-1$

        // Error
        Label errorLabel = new Label( consoleGroup, SWT.NONE );
        errorLabel.setText( Messages.getString( "ColorsAndFontsPage.Error" ) ); //$NON-NLS-1$
        errorColorButton = new ColorSelector( consoleGroup );
        errorColorButton.getButton().setLayoutData( new GridData( SWT.RIGHT, SWT.NONE, true, false ) );
        errorBoldCheckbox = new Button( consoleGroup, SWT.CHECK );
        errorBoldCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Bold" ) ); //$NON-NLS-1$
        errorItalicCheckbox = new Button( consoleGroup, SWT.CHECK );
        errorItalicCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Italic" ) ); //$NON-NLS-1$

        // Fatal
        Label fatalLabel = new Label( consoleGroup, SWT.NONE );
        fatalLabel.setText( Messages.getString( "ColorsAndFontsPage.Fatal" ) ); //$NON-NLS-1$
        fatalColorButton = new ColorSelector( consoleGroup );
        fatalColorButton.getButton().setLayoutData( new GridData( SWT.RIGHT, SWT.NONE, true, false ) );
        fatalBoldCheckbox = new Button( consoleGroup, SWT.CHECK );
        fatalBoldCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Bold" ) ); //$NON-NLS-1$
        fatalItalicCheckbox = new Button( consoleGroup, SWT.CHECK );
        fatalItalicCheckbox.setText( Messages.getString( "ColorsAndFontsPage.Italic" ) ); //$NON-NLS-1$
View Full Code Here

        Composite colorsAndFontsComposite = BaseWidgetUtils.createColumnContainer( colorsAndFontsGroup, 4, 1 );
        for ( int i = 0; i < ATTRIBUTE_TYPES.length; i++ )
        {
            attributeTypeLabels[i] = BaseWidgetUtils.createLabel( colorsAndFontsComposite, ATTRIBUTE_TYPES[i], 1 );
            attributeTypeLabels[i].setLayoutData( new GridData( GridData.FILL_HORIZONTAL ) );
            attributeColorSelectors[i] = new ColorSelector( colorsAndFontsComposite );
            attributeBoldButtons[i] = BaseWidgetUtils.createCheckbox( colorsAndFontsComposite, Messages
                .getString( "AttributesPreferencePage.Bold" ), 1 ); //$NON-NLS-1$
            attributeItalicButtons[i] = BaseWidgetUtils.createCheckbox( colorsAndFontsComposite, Messages
                .getString( "AttributesPreferencePage.Italic" ), 1 ); //$NON-NLS-1$
View Full Code Here

    // text color label
    Label colorText = new Label(settingsComposite, SWT.NONE);
    colorText.setText("Color:");

    mColorSelector = new ColorSelector(settingsComposite);
    mColorSelector.setEnabled(false);
    mColorSelector.addListener(new IPropertyChangeListener() {
      public void propertyChange(PropertyChangeEvent event) {
        AnnotationStyle style = getWorkingCopyAnnotationStyle( getSelectedType());
View Full Code Here

    l.setText(TextEditorMessages.TextEditorPreferencePage_color);
    gd= new GridData();
    gd.horizontalAlignment= GridData.BEGINNING;
    l.setLayoutData(gd);

    fAppearanceColorEditor= new ColorSelector(stylesComposite);
    Button foregroundColorButton= fAppearanceColorEditor.getButton();
    gd= new GridData(GridData.FILL_HORIZONTAL);
    gd.horizontalAlignment= GridData.BEGINNING;
    foregroundColorButton.setLayoutData(gd);
View Full Code Here

    gd= new GridData();
    gd.horizontalAlignment= GridData.BEGINNING;
    gd.horizontalIndent= 20;
    label.setLayoutData(gd);

    fAnnotationForegroundColorEditor= new ColorSelector(optionsComposite);
    Button foregroundColorButton= fAnnotationForegroundColorEditor.getButton();
    gd= new GridData(GridData.FILL_HORIZONTAL);
    gd.horizontalAlignment= GridData.BEGINNING;
    foregroundColorButton.setLayoutData(gd);
View Full Code Here

    label.setText(TextEditorMessages.LinkedModeConfigurationBlock_color);
    gd= new GridData();
    gd.horizontalAlignment= GridData.BEGINNING;
    label.setLayoutData(gd);

    fAnnotationForegroundColorEditor= new ColorSelector(optionsComposite);
    Button foregroundColorButton= fAnnotationForegroundColorEditor.getButton();
    gd= new GridData(GridData.FILL_HORIZONTAL);
    gd.horizontalAlignment= GridData.BEGINNING;
    foregroundColorButton.setLayoutData(gd);
   
View Full Code Here

    fQuickDiffColorEditors= new ColorSelector[3];
    for (int i= 0; i < fQuickDiffModel.length; i++) {
      label= fQuickDiffModel[i][2];
      l= new Label(group, SWT.LEFT);
      l.setText(label);
      final ColorSelector editor= new ColorSelector(group);
      fQuickDiffColorEditors[i]= editor;
      Button changeColorButton= editor.getButton();
      gd= new GridData(GridData.FILL_HORIZONTAL);
      gd.horizontalAlignment= GridData.BEGINNING;
      changeColorButton.setLayoutData(gd);
      final int index= i;
      changeColorButton.addSelectionListener(new SelectionListener() {
        public void widgetDefaultSelected(SelectionEvent e) {
          // do nothing
        }

        public void widgetSelected(SelectionEvent e) {
          String key= fQuickDiffModel[index][0];
          PreferenceConverter.setValue(fStore, key, editor.getColorValue());
        }
      });
    }

    addFiller(composite);
View Full Code Here

TOP

Related Classes of org.eclipse.jface.preference.ColorSelector

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.