Examples of DialPointer


Examples of org.jfree.chart.plot.dial.DialPointer

        dialAnnotation.setAnchor(TextAnchor.CENTER);
        dialPlot.addLayer(dialAnnotation);
      }
    }

    DialPointer needle = new DialPointer.Pointer();

    needle.setVisible(true);
    needle.setRadius(0.91);
    dialPlot.addLayer(needle);

    DialCap cap = new DialCap();
    cap.setRadius(0.05);
    cap.setFillPaint(Color.DARK_GRAY);
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

        dialAnnotation.setAnchor(TextAnchor.CENTER);
        dialPlot.addLayer(dialAnnotation);
      }
    }

    DialPointer needle = new ScaledDialPointer(dialUnitScale, 0.047);

    needle.setVisible(true);
    needle.setRadius(0.7);
    dialPlot.addLayer(needle);

    DialCap cap = new DialCap();
    cap.setRadius(0.05);
    cap.setFillPaint(Color.BLACK);
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

        dialAnnotation.setAnchor(TextAnchor.CENTER);
        dialPlot.addLayer(dialAnnotation);
      }
    }

    DialPointer needle = new DialPointer.Pointer();

    needle.setVisible(true);
    needle.setRadius(0.91);
    dialPlot.addLayer(needle);

    DialCap cap = new DialCap();
    cap.setRadius(0.05);
    cap.setFillPaint(Color.DARK_GRAY);
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

        dialAnnotation.setAnchor(TextAnchor.CENTER);
        dialPlot.addLayer(dialAnnotation);
      }
    }

    DialPointer needle = new DialPointer.Pointer();

    needle.setVisible(true);
    needle.setRadius(0.91);
    dialPlot.addLayer(needle);

    DialCap cap = new DialCap();
    cap.setRadius(0.05);
    cap.setFillPaint(Color.DARK_GRAY);
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

      }
    }

    //DialPointer needle = new DialPointer.Pointer();
    Paint paint = new Color(191, 48, 0);
    DialPointer needle = new ScaledDialPointer(dialUnitScale, paint, paint);

    needle.setVisible(true);
    needle.setRadius(0.91);
    dialPlot.addLayer(needle);

    DialCap cap = new DialCap();
    cap.setRadius(0.05);
    cap.setFillPaint(Color.DARK_GRAY);
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

    /**
     * Confirm that the equals method can distinguish all the required fields.
     */
    public void testEquals() {
        DialPointer i1 = new DialPointer.Pin(1);
        DialPointer i2 = new DialPointer.Pin(1);
        assertTrue(i1.equals(i2));

        // dataset index
        i1 = new DialPointer.Pin(2);
        assertFalse(i1.equals(i2));
        i2 = new DialPointer.Pin(2);
        assertTrue(i1.equals(i2));

        // check an inherited attribute
        i1.setVisible(false);
        assertFalse(i1.equals(i2));
        i2.setVisible(false);
        assertTrue(i1.equals(i2));
    }
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

    /**
     * Two objects that are equal are required to return the same hashCode.
     */
    public void testHashCode() {
        DialPointer i1 = new DialPointer.Pin(1);
        DialPointer i2 = new DialPointer.Pin(1);
        assertTrue(i1.equals(i2));
        int h1 = i1.hashCode();
        int h2 = i2.hashCode();
        assertEquals(h1, h2);
    }
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

    /**
     * Confirm that cloning works.
     */
    public void testCloning() {
        DialPointer i1 = new DialPointer.Pin(1);
        DialPointer i2 = null;
        try {
            i2 = (DialPointer) i1.clone();
        }
        catch (CloneNotSupportedException e) {
            e.printStackTrace();
        }
        assertTrue(i1 != i2);
        assertTrue(i1.getClass() == i2.getClass());
        assertTrue(i1.equals(i2));

        // check that the listener lists are independent
        MyDialLayerChangeListener l1 = new MyDialLayerChangeListener();
        i1.addChangeListener(l1);
        assertTrue(i1.hasListener(l1));
        assertFalse(i2.hasListener(l1));
    }
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

    /**
     * Serialize an instance, restore it, and check for equality.
     */
    public void testSerialization() {
        // test a default instance
        DialPointer i1 = new DialPointer.Pin(1);
        DialPointer i2 = null;

        try {
            ByteArrayOutputStream buffer = new ByteArrayOutputStream();
            ObjectOutput out = new ObjectOutputStream(buffer);
            out.writeObject(i1);
View Full Code Here

Examples of org.jfree.chart.plot.dial.DialPointer

    /**
     * Serialize an instance, restore it, and check for equality.
     */
    public void testSerialization2() {
        // test a default instance
        DialPointer i1 = new DialPointer.Pointer(1);
        DialPointer i2 = null;

        try {
            ByteArrayOutputStream buffer = new ByteArrayOutputStream();
            ObjectOutput out = new ObjectOutputStream(buffer);
            out.writeObject(i1);
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.