Examples of ColorDialog


Examples of net.sf.soundcomp.ide.dialog.ColorDialog

        }
}//GEN-LAST:event_setFontMenuItemActionPerformed

    private void setColorsMenuItemActionPerformed(ActionEvent evt) {//GEN-FIRST:event_setColorsMenuItemActionPerformed
        if (activePanel instanceof TextPanel) {
            ColorDialog dlg = new ColorDialog(((SingleFrameApplication) getApplication()).getMainFrame(), true);
            dlg.setLocationRelativeTo(dlg.getParent());
            ((TextPanel)activePanel).showColorDialog(dlg);
        }
}//GEN-LAST:event_setColorsMenuItemActionPerformed
View Full Code Here

Examples of nodebox.ui.ColorDialog

        while (!(component instanceof NodeBoxDocument)) {
            component = component.getParent();
        }

        if (colorDialog == null) {
            colorDialog = new ColorDialog((Frame) SwingUtilities.getWindowAncestor(this));
            colorDialog.setColor(port.colorValue().getAwtColor());
            int height = colorDialog.getHeight();
            colorDialog.setMinimumSize(new Dimension(400, height));
            colorDialog.setPreferredSize(new Dimension(540, height));
            colorDialog.setMaximumSize(new Dimension(Integer.MAX_VALUE, height));
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

          if (iIndex == null)
            return;
          int index = iIndex.intValue();

          if (e.button == 1) {
            ColorDialog cd = new ColorDialog(panel.getShell());
            cd.setRGB(blockColors[index].getRGB());
           
            RGB rgb = cd.open();
            if (rgb != null)
              config.setRGBParameter(keys[index], rgb.red, rgb.green, rgb.blue);
          } else {
            config.removeRGBParameter(keys[index]);
          }
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

      }
    });

    colorChooser.addListener(SWT.Selection, new Listener() {
      public void handleEvent(Event e) {
        ColorDialog cd = new ColorDialog(composite.getShell());
        cd.setRGB(new RGB(r,g,b));
        RGB newColor = cd.open();
        if (newColor == null)
          return;
        newColorChosen();
        COConfigurationManager.setRGBParameter(name, newColor.red, newColor.green, newColor.blue);
        newColorSet();
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

      fColorItem.setImage(fColorImage);
    }

    private void onSelectColor() {
      ColorDialog dialog = new ColorDialog(getShell());
      dialog.setRGB(fSelectedColor);
      RGB color = dialog.open();
      if (color != null) {
        fSelectedColor = color;
        updateColorItem();
      }
    }
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

    return img;
  }

  private void onSelectOtherColor() {
    ColorDialog dialog = new ColorDialog(fParent.getShell());
    dialog.setRGB(fSelectedColor);
    RGB color = dialog.open();
    if (color != null)
      onColorSelected(color);
  }
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

    gc.dispose();
   
    fButton.setImage(fImage);
    fButton.addSelectionListener(new SelectionAdapter() {
      public void widgetSelected(SelectionEvent event) {
        ColorDialog colorDialog= new ColorDialog(fButton.getShell());
        colorDialog.setRGB(fColorValue);
        RGB newColor = colorDialog.open();
        if (newColor != null) {
          fColorValue= newColor;
          updateColorImage();
        }
      }
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

        fButton.setImage(fImage);
        fButton.addSelectionListener(new SelectionAdapter() {

            @Override
            public void widgetSelected(final SelectionEvent event) {
                final ColorDialog colorDialog = new ColorDialog(fButton.getShell());
                colorDialog.setRGB(fColorValue);
                final RGB newColor = colorDialog.open();
                if (newColor != null) {
                    fColorValue = newColor;
                    updateColorImage();
                }
            }
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

   * dialog to appear and wait for user input.
   *
   * @since 3.2
   */
  public void open() {
    ColorDialog colorDialog = new ColorDialog(fButton.getShell());
    colorDialog.setRGB(fColorValue);
    RGB newColor = colorDialog.open();
    if (newColor != null) {
        RGB oldValue = fColorValue;
        fColorValue = newColor;
        final Object[] finalListeners = getListeners();
        if (finalListeners.length > 0) {
View Full Code Here

Examples of org.eclipse.swt.widgets.ColorDialog

    /* (non-Javadoc)
     * Method declared on DialogCellEditor.
     */
    protected Object openDialogBox(Control cellEditorWindow) {
        ColorDialog dialog = new ColorDialog(cellEditorWindow.getShell());
        Object value = getValue();
        if (value != null) {
      dialog.setRGB((RGB) value);
    }
        value = dialog.open();
        return dialog.getRGB();
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.