Package org.eclipse.swt.graphics

Examples of org.eclipse.swt.graphics.Pattern.dispose()


        gc.fillRectangle(rect);
        GraphicsTab tab = getTab();
        if (tab != null)
          tab.paint(gc, rect.width, rect.height);
        if (pattern != null)
          pattern.dispose();
      }
    });
  }

  /**
 
View Full Code Here


    gc.drawString(text, (width - textWidth) / 2, (height - textHeight) / 2, true);

    font.dispose();
    if (pattern != null)
      pattern.dispose();
  }

}
View Full Code Here

    gc.drawLine(3 * width / 16, 3 * height / 6, 13 * width / 16, 3 * height / 6);
    gc.setLineCap(SWT.CAP_ROUND);
    gc.drawLine(3 * width / 16, 4 * height / 6, 13 * width / 16, 4 * height / 6);

    if (pattern != null)
      pattern.dispose();
  }
}
View Full Code Here

      gc.drawArc(0, 0, width / 3, height / 6, 0, 180);
      transform.dispose();
    }

    if (pattern != null)
      pattern.dispose();
  }
}
View Full Code Here

    gc.fillPath(path);
    path.dispose();

    if (pattern != null)
      pattern.dispose();
  }
}
View Full Code Here

    Image image = createImage(device, colorGB1.getBgColor1(), colorGB2.getBgColor1(), width, height);
    Pattern p = new Pattern(device, image);
    gc.setBackgroundPattern(p);
    gc.fillRectangle(0, 0, width, height);

    p.dispose();
    image.dispose();
  }

  /**
   * Creates and returns an image made up of gradient patterns. The image takes up a quarter of the area of the total
View Full Code Here

    gc.fillPath(path);
    path.dispose();

    gc.dispose();
    pattern1.dispose();
    pattern2.dispose();
    return image;
  }

}
View Full Code Here

    gc.setLineWidth(2);
    gc.fillRectangle((width - rectWidth) / 2, (height - rectHeight) / 2, rectWidth, rectHeight);
    gc.drawPath(path);

    if (pattern != null)
      pattern.dispose();

    path9.dispose();
    path8.dispose();
    path7.dispose();
    path6.dispose();
View Full Code Here

    if (drawButton.getSelection())
      gc.drawPath(path);
    path.dispose();

    if (pattern != null)
      pattern.dispose();
  }
}
View Full Code Here

    gc.setTransform(transform);
    transform.dispose();

    path = new Path(device);
    path.addRectangle(0, 0, 50, height);
    pattern.dispose();
    pattern = new Pattern(device, 0, 0, 50, height, device.getSystemColor(SWT.COLOR_DARK_CYAN), 0x7f, device
        .getSystemColor(SWT.COLOR_WHITE), 0x7f);
    gc.setBackgroundPattern(pattern);
    gc.fillPath(path);
    gc.drawPath(path);
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.