Examples of AlphaComposite


Examples of java.awt.AlphaComposite

            if(numVertex == 0) {
                return;
            }

            if(comp instanceof AlphaComposite){
                AlphaComposite ac = (AlphaComposite) comp;
                int compType = ac.getRule();
                float alpha = ac.getAlpha();
                if(srcSurf instanceof ImageSurface){
                    if(bgcolor == null || srcSurf.getTransparency() == Transparency.OPAQUE){
                        bltImage(srcX, srcY, srcSurfStruct, srcSurf.getData(),
                                dstX, dstY, dstSurfStruct,
                                width, height, compType, alpha,
View Full Code Here

Examples of java.awt.AlphaComposite

            return;
        }

        if ((composite != null) &&
            (composite instanceof AlphaComposite)) {
            AlphaComposite ac = (AlphaComposite)composite;
            if (ac.getAlpha() < 0.001)
                return;         // No point in drawing
        }

        // Set up graphic context. It is important to setup the transform first,
        // because the clip is defined in this node's user space.
View Full Code Here

Examples of java.awt.AlphaComposite

            return;
        }

        if ((composite != null) &&
            (composite instanceof AlphaComposite)) {
            AlphaComposite ac = (AlphaComposite)composite;
            if (ac.getAlpha() < 0.001)
                return;         // No point in drawing
        }

        // Set up graphic context. It is important to setup the transform first,
        // because the clip is defined in this node's user space.
View Full Code Here

Examples of java.awt.AlphaComposite

    }

    private void paintBackground(Graphics g) {
      Graphics2D g2d = (Graphics2D) g;
      java.awt.Composite old = g2d.getComposite();
      AlphaComposite pha = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.2f);
      g2d.setComposite(pha);
      g2d.setColor(designFieldBackground);
      int width = getWidth();
      int height = getHeight();
      g2d.fillRect(0, 0, width, height);
View Full Code Here

Examples of java.awt.AlphaComposite

    }

    private void paintBackground(Graphics g) {
      Graphics2D g2d = (Graphics2D) g;
      java.awt.Composite old = g2d.getComposite();
      AlphaComposite pha = AlphaComposite.getInstance(
          AlphaComposite.SRC_OVER, 0.2f);
      g2d.setComposite(pha);
      g2d.setColor(designFieldBackground);
      int width = getWidth();
      int height = getHeight();
View Full Code Here

Examples of java.awt.AlphaComposite

    }

    private void paintBackground(Graphics g) {
      Graphics2D g2d = (Graphics2D) g;
      java.awt.Composite old = g2d.getComposite();
      AlphaComposite pha = AlphaComposite.getInstance(
          AlphaComposite.SRC_OVER, 0.2f);
      g2d.setComposite(pha);
      g2d.setColor(designFieldBackground);
      int width = getWidth();
      int height = getHeight();
View Full Code Here

Examples of java.awt.AlphaComposite

      int w = adaptable.getWidget().getWidth();
      int h = adaptable.getWidget().getHeight();
      Graphics2D g2d = (Graphics2D) clipg;
      g2d.setColor(GREEN_COLOR);
      Composite oldComposite = g2d.getComposite();
      AlphaComposite composite = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.5f);
      g2d.setComposite(composite);
      g2d.fillRect(0, 0, w, h);
      Stroke oldStroke = g2d.getStroke();
      g2d.setColor(RED_COLOR);
      g2d.setStroke(STROKE);
View Full Code Here

Examples of java.awt.AlphaComposite

      int w = adaptable.getWidget().getWidth();
      int h = adaptable.getWidget().getHeight();
      Graphics2D g2d = (Graphics2D) clipg;
      g2d.setColor(RED_COLOR);
      Composite oldComposite = g2d.getComposite();
      AlphaComposite composite = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.5f);
      g2d.setComposite(composite);
      g2d.fillRect(0, 0, w, h);
      Stroke oldStroke = g2d.getStroke();
      g2d.setColor(GREEN_COLOR);
      g2d.setStroke(STROKE);
View Full Code Here

Examples of java.awt.AlphaComposite

    Rectangle bounds = ((JSplitPaneDesignOperation)getOperation()).getHotspotBounds();
    if (bounds != null) {
      Graphics2D g2d = (Graphics2D) clipg;
      g2d.setColor(((JSplitPaneDesignOperation)getOperation()).isForbid() ? RED_COLOR : GREEN_COLOR);
      Composite oldComposite = g2d.getComposite();
      AlphaComposite composite = AlphaComposite.getInstance(
          AlphaComposite.SRC_OVER, 0.5f);
      g2d.setComposite(composite);
      g2d.fillRect(bounds.x, bounds.y, bounds.width, bounds.height);
      Stroke oldStroke = g2d.getStroke();
      g2d.setColor(((JSplitPaneDesignOperation)getOperation()).isForbid() ? GREEN_COLOR : RED_COLOR);
View Full Code Here

Examples of java.awt.AlphaComposite

   *
   * @param harness  the test harness (<code>null</code> not permitted).
   */
  public void test(TestHarness harness
  {
    AlphaComposite a1 = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.3f);
    AlphaComposite a2 = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.4f);
    harness.check(!a1.equals(a2));
    harness.check(!a1.equals(null));
    a2 = AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.3f);
    harness.check(a1.equals(a2));
  }
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.