/hg/gfx-test: Added new tests, updated (c) year, improved javado...

ptisnovs at icedtea.classpath.org ptisnovs at icedtea.classpath.org
Tue Feb 4 03:23:30 PST 2014


changeset 1d17438ec9cb in /hg/gfx-test
details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=1d17438ec9cb
author: Pavel Tisnovsky <ptisnovs at redhat.com>
date: Tue Feb 04 12:27:47 2014 +0100

	Added new tests, updated (c) year, improved javadoc etc.


diffstat:

 ChangeLog                                                               |   7 +
 src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java    |  82 +++++-----
 src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java |   5 +-
 src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java       |  25 +++
 4 files changed, 75 insertions(+), 44 deletions(-)

diffs (450 lines):

diff -r 21d3f15459c9 -r 1d17438ec9cb ChangeLog
--- a/ChangeLog	Mon Feb 03 13:49:34 2014 +0100
+++ b/ChangeLog	Tue Feb 04 12:27:47 2014 +0100
@@ -1,3 +1,10 @@
+2014-02-04  Pavel Tisnovsky  <ptisnovs at redhat.com>
+
+	* src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java:
+	* src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java:
+	* src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java:
+	Added new tests, updated (c) year, improved javadoc etc.
+
 2014-02-03  Pavel Tisnovsky  <ptisnovs at redhat.com>
 
 	* src/org/gfxtest/framework/CommonCAGOperations.java:
diff -r 21d3f15459c9 -r 1d17438ec9cb src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java
--- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java	Mon Feb 03 13:49:34 2014 +0100
+++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingCircles.java	Tue Feb 04 12:27:47 2014 +0100
@@ -1,7 +1,7 @@
 /*
   Java gfx-test framework
 
-   Copyright (C) 2010, 2011  Red Hat
+   Copyright (C) 2010, 2011, 2012, 2013, 2014  Red Hat
 
 This file is part of IcedTea.
 
@@ -69,7 +69,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using stroke.
      * 
      * @param image
@@ -92,7 +92,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is
+     * constructed from two overlapping circles using subtract operator. The shape is
      * rendered using stroke.
      * 
      * @param image
@@ -115,7 +115,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using inverse subtract operator. The shape
+     * constructed from two overlapping circles using inverse subtract operator. The shape
      * is rendered using stroke.
      * 
      * @param image
@@ -138,7 +138,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is
+     * constructed from two overlapping circles using intersect operator. The shape is
      * rendered using stroke.
      * 
      * @param image
@@ -161,7 +161,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using stroke.
      * 
      * @param image
@@ -184,7 +184,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using wide stroke.
      * 
      * @param image
@@ -209,7 +209,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is
+     * constructed from two overlapping circles using subtract operator. The shape is
      * rendered using wide stroke.
      * 
      * @param image
@@ -234,7 +234,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using inverse subtract operator. The shape
+     * constructed from two overlapping circles using inverse subtract operator. The shape
      * is rendered using wide stroke.
      * 
      * @param image
@@ -259,7 +259,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is
+     * constructed from two overlapping circles using intersect operator. The shape is
      * rendered using wide stroke.
      * 
      * @param image
@@ -284,7 +284,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using wide stroke.
      * 
      * @param image
@@ -309,7 +309,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using extra wide stroke.
      * 
      * @param image
@@ -334,7 +334,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is
+     * constructed from two overlapping circles using subtract operator. The shape is
      * rendered using extra wide stroke.
      * 
      * @param image
@@ -359,7 +359,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using inverse subtract operator. The shape
+     * constructed from two overlapping circles using inverse subtract operator. The shape
      * is rendered using extra wide stroke.
      * 
      * @param image
@@ -384,7 +384,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is
+     * constructed from two overlapping circles using intersect operator. The shape is
      * rendered using extra wide stroke.
      * 
      * @param image
@@ -409,7 +409,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using extra wide stroke.
      * 
      * @param image
@@ -434,7 +434,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using color paint (fill).
      * 
      * @param image
@@ -459,7 +459,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is
+     * constructed from two overlapping circles using subtract operator. The shape is
      * rendered using color paint (fill).
      * 
      * @param image
@@ -484,7 +484,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is
+     * constructed from two overlapping circles using subtract operator. The shape is
      * rendered using color paint (fill).
      * 
      * @param image
@@ -509,7 +509,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is
+     * constructed from two overlapping circles using intersect operator. The shape is
      * rendered using color paint (fill).
      * 
      * @param image
@@ -534,7 +534,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using color paint (fill).
      * 
      * @param image
@@ -559,7 +559,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using horizontal gradient paint (fill).
      * 
      * @param image
@@ -584,7 +584,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is rendered
+     * constructed from two overlapping circles using subtract operator. The shape is rendered
      * using horizontal gradient paint (fill).
      * 
      * @param image
@@ -609,7 +609,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is rendered
+     * constructed from two overlapping circles using subtract operator. The shape is rendered
      * using horizontal gradient paint (fill).
      * 
      * @param image
@@ -634,7 +634,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is rendered
+     * constructed from two overlapping circles using intersect operator. The shape is rendered
      * using horizontal gradient paint (fill).
      * 
      * @param image
@@ -659,7 +659,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using horizontal gradient paint (fill).
      * 
      * @param image
@@ -684,7 +684,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using vertical gradient paint (fill).
      * 
      * @param image
@@ -709,7 +709,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is
+     * constructed from two overlapping circles using subtract operator. The shape is
      * rendered using vertical gradient paint (fill).
      * 
      * @param image
@@ -734,7 +734,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using inverse subtract operator. The shape
+     * constructed from two overlapping circles using inverse subtract operator. The shape
      * is rendered using vertical gradient paint (fill).
      * 
      * @param image
@@ -759,7 +759,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is rendered
+     * constructed from two overlapping circles using intersect operator. The shape is rendered
      * using vertical gradient paint (fill).
      * 
      * @param image
@@ -784,7 +784,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using vertical gradient paint (fill).
      * 
      * @param image
@@ -809,7 +809,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is rendered
+     * constructed from two overlapping circles using subtract operator. The shape is rendered
      * using diagonal gradient paint (fill).
      * 
      * @param image
@@ -834,7 +834,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using subtract operator. The shape is
+     * constructed from two overlapping circles using subtract operator. The shape is
      * rendered using diagonal gradient paint (fill).
      * 
      * @param image
@@ -859,7 +859,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is
+     * constructed from two overlapping circles using intersect operator. The shape is
      * rendered using diagonal gradient paint (fill).
      * 
      * @param image
@@ -884,7 +884,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using diagonal gradient paint (fill).
      * 
      * @param image
@@ -909,7 +909,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using diagonal gradient paint (fill).
      * 
      * @param image
@@ -934,7 +934,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using radial gradient paint (fill).
      * 
      * @param image
@@ -959,7 +959,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using union operator. The shape is rendered
+     * constructed from two overlapping circles using union operator. The shape is rendered
      * using radial gradient paint (fill).
      * 
      * @param image
@@ -984,7 +984,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using inverse subtract operator. The shape
+     * constructed from two overlapping circles using inverse subtract operator. The shape
      * is rendered using radial gradient paint (fill).
      * 
      * @param image
@@ -1009,7 +1009,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using intersect operator. The shape is
+     * constructed from two overlapping circles using intersect operator. The shape is
      * rendered using radial gradient paint (fill).
      * 
      * @param image
@@ -1034,7 +1034,7 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
-     * constructed from two circles using XOR operator. The shape is rendered
+     * constructed from two overlapping circles using XOR operator. The shape is rendered
      * using radial gradient paint (fill).
      * 
      * @param image
diff -r 21d3f15459c9 -r 1d17438ec9cb src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java
--- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java	Mon Feb 03 13:49:34 2014 +0100
+++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoOverlappingRectangles.java	Tue Feb 04 12:27:47 2014 +0100
@@ -1,7 +1,7 @@
 /*
   Java gfx-test framework
 
-   Copyright (C) 2010, 2011  Red Hat
+   Copyright (C) 2010, 2011, 2012, 2013, 2014  Red Hat
 
 This file is part of IcedTea.
 
@@ -36,7 +36,7 @@
 this exception to your version of the library, but you are not
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version.
- */
+*/
 
 package org.gfxtest.testsuites;
 
@@ -55,7 +55,6 @@
  * by performing boolean operations on existing ones. This process is often
  * called Constructive area geometry (CAG). All CAG operations - union,
  * intersection, subtraction and XOR - is processed on two overlapping Rectangles.
- * Rectangles which are the basis of the areas are overlapping.
  * 
  * @author Pavel Tisnovsky
  */
diff -r 21d3f15459c9 -r 1d17438ec9cb src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java
--- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java	Mon Feb 03 13:49:34 2014 +0100
+++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java	Tue Feb 04 12:27:47 2014 +0100
@@ -934,6 +934,31 @@
 
     /**
      * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using union operator. The shape is rendered
+     * using diagonal gradient paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testUnionDiagonalGradientPaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setDiagonalGradientFill(image, graphics2d);
+        // create area using union operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingUnionOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
      * constructed from two touching circles using subtract operator. The shape is rendered
      * using diagonal gradient paint (fill).
      * 


More information about the distro-pkg-dev mailing list