Examples of RGBColor


Examples of org.eclipse.swt.internal.carbon.RGBColor

  queue = OS.GetCurrentEventQueue ();
  OS.TXNInitTextension (0, 0, 0);
 
  /* Save the current highlight color */
  OS.RegisterAppearanceClient ();
  highlightColor = new RGBColor ();
  OS.GetThemeBrushAsColor ((short) OS.kThemeBrushPrimaryHighlightColor, (short) getDepth(), true, highlightColor);
}
View Full Code Here

Examples of org.eclipse.swt.internal.carbon.RGBColor

*
* @see SWT
*/
public Color getSystemColor (int id) {
  checkDevice ();
  RGBColor rgb = new RGBColor ();
  switch (id) {
    case SWT.COLOR_INFO_FOREGROUND: return super.getSystemColor (SWT.COLOR_BLACK);
    case SWT.COLOR_INFO_BACKGROUND: return Color.carbon_new (this, new float [] {0xFF / 255f, 0xFF / 255f, 0xE1 / 255f, 1});
    case SWT.COLOR_TITLE_FOREGROUND: OS.GetThemeTextColor((short)OS.kThemeTextColorDocumentWindowTitleActive, (short)getDepth(), true, rgb); break;
    case SWT.COLOR_TITLE_BACKGROUND: OS.GetThemeBrushAsColor((short)-5/*undocumented darker highlight color*/, (short)getDepth(), true, rgb); break;
View Full Code Here

Examples of org.eclipse.swt.internal.carbon.RGBColor

public boolean sleep () {
  checkDevice ();
  if (getMessageCount () != 0) return true;
  disposeWindows ();
  if (eventTable != null && eventTable.hooks (SWT.Settings)) {
    RGBColor color = new RGBColor ();
    int status = OS.noErr, depth = getDepth ();
    do {
      allowTimers = false;
      status = OS.ReceiveNextEvent (0, null, 0.5, false, null);
      allowTimers = true;
View Full Code Here

Examples of org.jwildfire.create.tina.meshgen.sunflow.base.RGBColor

    type = pType;
    return this;
  }

  public LightBuilder withColor(double pR, double pG, double pB) {
    color = new RGBColor(pR, pG, pB);
    return this;
  }
View Full Code Here

Examples of org.jwildfire.create.tina.palette.RGBColor

    private static final long serialVersionUID = 1L;

    public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) {
      Component c = super.getTableCellRendererComponent(table, value, isSelected, hasFocus, row, column);
      if (data.paletteKeyFrames != null && data.paletteKeyFrames.size() > row) {
        RGBColor color = data.paletteKeyFrames.get(row);
        c.setBackground(new java.awt.Color(color.getRed(), color.getGreen(), color.getBlue()));
      }
      return c;
    }
View Full Code Here

Examples of org.jwildfire.create.tina.palette.RGBColor

      }
      else if (token.startsWith("index=") && tokenizer.hasMoreElements() && (nextToken = tokenizer.nextToken()).startsWith("color=")) {
        int index = Integer.parseInt(token.substring(6, token.length()));
        int colorValue = Integer.parseInt(nextToken.substring(6, nextToken.length()));
        pixel.setARGBValue(colorValue);
        RGBColor color = new RGBColor(pixel.b, pixel.g, pixel.r);
        colors.put(index, color);
      }
    }
    boolean doInterpolate = pUgr.contains("numnodes=");
    boolean doFade = pUgr.contains("smooth=yes");
    final int maxIdx = 399;
    if (doInterpolate) {
      if (colors.get(0) == null) {
        colors.put(0, new RGBColor(0, 0, 0));
      }
      if (colors.get(maxIdx) == null) {
        colors.put(maxIdx, new RGBColor(0, 0, 0));
      }
    }
    else {
      RGBColor lastColor = new RGBColor(0, 0, 0);
      for (int i = 0; i <= maxIdx; i++) {
        RGBColor color = colors.get(i);
        if (color == null) {
          colors.put(i, lastColor);
        }
        else {
          lastColor = color;
View Full Code Here

Examples of org.jwildfire.create.tina.palette.RGBColor

      markerColorSelYMax = yOff + 3 * size2;

      markerXMin[pMarkerIdx] = x - size2;
      markerXMax[pMarkerIdx] = x + size2;

      RGBColor color = pGradient.getColor(mPos);
      g.setColor(new Color(color.getRed(), color.getGreen(), color.getBlue()));
      g.fillOval(x - size2 + 2, yOff + size2 + 2, 2 * size2 - 4, 2 * size2 - 4);
    }

  }
View Full Code Here

Examples of org.jwildfire.create.tina.palette.RGBColor

  private void drawGradient(Graphics2D g, RGBPalette pGradient) {
    g.setColor(FlamePanelConfig.XFORM_COLOR);
    g.drawRect(xMin - 1, yMin - 1, xMax - xMin + 1, yMax - yMin + 2);
    for (int i = 0; i < GRADIENT_SIZE; i++) {
      int cxMin = xPos[i], cxMax = xPos[i + 1] - 1;
      RGBColor color = pGradient.getColor(i);
      g.setColor(new Color(color.getRed(), color.getGreen(), color.getBlue()));
      for (int cx = cxMin; cx <= cxMax && cx >= xMin && cx <= xMax; cx++) {
        g.drawLine(cx, yMin, cx, yMax);
      }
    }
  }
View Full Code Here

Examples of org.jwildfire.create.tina.palette.RGBColor

  public boolean gradientMarker_selectColor(int marker, RGBPalette pGradient) {
    if (marker >= 0) {
      ResourceManager rm = ResourceManager.all(FilePropertyEditor.class);
      String title = rm.getString("ColorPropertyEditor.title");

      RGBColor color = pGradient.getColor(markerPos[marker]);

      Color selectedColor = JColorChooser.showDialog(parent, title, new Color(color.getRed(), color.getGreen(), color.getBlue()));
      if (selectedColor != null) {

        pGradient.setColor(markerPos[marker], selectedColor.getRed(), selectedColor.getGreen(), selectedColor.getBlue());
        return true;
      }
View Full Code Here

Examples of org.jwildfire.create.tina.palette.RGBColor

  }

  public void pasteRange(RGBPalette pGradient) {
    if (currClipboard != null && currClipboard.length > 0) {
      for (int i = getFrom(); (i <= getTo()) && ((i - getFrom()) < currClipboard.length); i++) {
        RGBColor color = currClipboard[i - getFrom()];
        pGradient.setColor(i, color.getRed(), color.getGreen(), color.getBlue());
      }
    }
  }
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.