Java Code Examples for sun.awt.geom.Curve#getXBot()

The following examples show how to use sun.awt.geom.Curve#getXBot() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: Area.java    From jdk8u-jdk with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 2
Source File: Area.java    From jdk8u-dev-jdk with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 3
Source File: Area.java    From jdk-1.7-annotated with Apache License 2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 4
Source File: Area.java    From jdk8u-jdk with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 5
Source File: Area.java    From jdk8u_jdk with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 6
Source File: Area.java    From openjdk-8 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 7
Source File: Area.java    From openjdk-8-source with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 8
Source File: Area.java    From hottub with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 9
Source File: Area.java    From Java8CN with Apache License 2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 10
Source File: Area.java    From jdk1.8-source-analysis with Apache License 2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 11
Source File: Area.java    From openjdk-jdk9 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this {@code Area} is rectangular in shape.
 * @return    {@code true} if the geometry of this
 * {@code Area} is rectangular in shape; {@code false}
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = curves.get(1);
    Curve c2 = curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 12
Source File: Area.java    From Bytecoder with Apache License 2.0 6 votes vote down vote up
/**
 * Tests whether this {@code Area} is rectangular in shape.
 * @return    {@code true} if the geometry of this
 * {@code Area} is rectangular in shape; {@code false}
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = curves.get(1);
    Curve c2 = curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 13
Source File: Area.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 14
Source File: Area.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 15
Source File: Area.java    From JDKSourceCode1.8 with MIT License 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 16
Source File: Area.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 17
Source File: Area.java    From TencentKona-8 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}
 
Example 18
Source File: Area.java    From dragonwell8_jdk with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Tests whether this <code>Area</code> is rectangular in shape.
 * @return    <code>true</code> if the geometry of this
 * <code>Area</code> is rectangular in shape; <code>false</code>
 * otherwise.
 * @since 1.2
 */
public boolean isRectangular() {
    int size = curves.size();
    if (size == 0) {
        return true;
    }
    if (size > 3) {
        return false;
    }
    Curve c1 = (Curve) curves.get(1);
    Curve c2 = (Curve) curves.get(2);
    if (c1.getOrder() != 1 || c2.getOrder() != 1) {
        return false;
    }
    if (c1.getXTop() != c1.getXBot() || c2.getXTop() != c2.getXBot()) {
        return false;
    }
    if (c1.getYTop() != c2.getYTop() || c1.getYBot() != c2.getYBot()) {
        // One might be able to prove that this is impossible...
        return false;
    }
    return true;
}