亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? categoryaxis.java

?? jfreechart1.0.1 jsp繪制圖表的開發包
?? JAVA
?? 第 1 頁 / 共 3 頁
字號:
/* ===========================================================
 * JFreeChart : a free chart library for the Java(tm) platform
 * ===========================================================
 *
 * (C) Copyright 2000-2006, by Object Refinery Limited and Contributors.
 *
 * Project Info:  http://www.jfree.org/jfreechart/index.html
 *
 * This library is free software; you can redistribute it and/or modify it 
 * under the terms of the GNU Lesser General Public License as published by 
 * the Free Software Foundation; either version 2.1 of the License, or 
 * (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful, but 
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 
 * License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, 
 * USA.  
 *
 * [Java is a trademark or registered trademark of Sun Microsystems, Inc. 
 * in the United States and other countries.]
 *
 * -----------------
 * CategoryAxis.java
 * -----------------
 * (C) Copyright 2000-2006, by Object Refinery Limited and Contributors.
 *
 * Original Author:  David Gilbert;
 * Contributor(s):   Pady Srinivasan (patch 1217634);
 *
 * $Id: CategoryAxis.java,v 1.18.2.6 2006/01/11 16:17:29 mungady Exp $
 *
 * Changes (from 21-Aug-2001)
 * --------------------------
 * 21-Aug-2001 : Added standard header. Fixed DOS encoding problem (DG);
 * 18-Sep-2001 : Updated header (DG);
 * 04-Dec-2001 : Changed constructors to protected, and tidied up default 
 *               values (DG);
 * 19-Apr-2002 : Updated import statements (DG);
 * 05-Sep-2002 : Updated constructor for changes in Axis class (DG);
 * 06-Nov-2002 : Moved margins from the CategoryPlot class (DG);
 * 08-Nov-2002 : Moved to new package com.jrefinery.chart.axis (DG);
 * 22-Jan-2002 : Removed monolithic constructor (DG);
 * 26-Mar-2003 : Implemented Serializable (DG);
 * 09-May-2003 : Merged HorizontalCategoryAxis and VerticalCategoryAxis into 
 *               this class (DG);
 * 13-Aug-2003 : Implemented Cloneable (DG);
 * 29-Oct-2003 : Added workaround for font alignment in PDF output (DG);
 * 05-Nov-2003 : Fixed serialization bug (DG);
 * 26-Nov-2003 : Added category label offset (DG);
 * 06-Jan-2004 : Moved axis line attributes to Axis class, rationalised 
 *               category label position attributes (DG);
 * 07-Jan-2004 : Added new implementation for linewrapping of category 
 *               labels (DG);
 * 17-Feb-2004 : Moved deprecated code to bottom of source file (DG);
 * 10-Mar-2004 : Changed Dimension --> Dimension2D in text classes (DG);
 * 16-Mar-2004 : Added support for tooltips on category labels (DG);
 * 01-Apr-2004 : Changed java.awt.geom.Dimension2D to org.jfree.ui.Size2D 
 *               because of JDK bug 4976448 which persists on JDK 1.3.1 (DG);
 * 03-Sep-2004 : Added 'maxCategoryLabelLines' attribute (DG);
 * 04-Oct-2004 : Renamed ShapeUtils --> ShapeUtilities (DG);
 * 11-Jan-2005 : Removed deprecated methods in preparation for 1.0.0 
 *               release (DG);
 * 21-Jan-2005 : Modified return type for RectangleAnchor.coordinates() 
 *               method (DG);
 * 21-Apr-2005 : Replaced Insets with RectangleInsets (DG);
 * 26-Apr-2005 : Removed LOGGER (DG);
 * 08-Jun-2005 : Fixed bug in axis layout (DG);
 * 22-Nov-2005 : Added a method to access the tool tip text for a category
 *               label (DG);
 * 23-Nov-2005 : Added per-category font and paint options - see patch 
 *               1217634 (DG);
 * ------------- JFreeChart 1.0.0 ---------------------------------------------
 * 11-Jan-2006 : Fixed null pointer exception in drawCategoryLabels - see bug
 *               1403043 (DG);
 *
 */

package org.jfree.chart.axis;

import java.awt.Font;
import java.awt.Graphics2D;
import java.awt.Paint;
import java.awt.Shape;
import java.awt.geom.Point2D;
import java.awt.geom.Rectangle2D;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.io.Serializable;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Set;

import org.jfree.chart.entity.EntityCollection;
import org.jfree.chart.entity.TickLabelEntity;
import org.jfree.chart.event.AxisChangeEvent;
import org.jfree.chart.plot.CategoryPlot;
import org.jfree.chart.plot.Plot;
import org.jfree.chart.plot.PlotRenderingInfo;
import org.jfree.io.SerialUtilities;
import org.jfree.text.G2TextMeasurer;
import org.jfree.text.TextBlock;
import org.jfree.text.TextUtilities;
import org.jfree.ui.RectangleAnchor;
import org.jfree.ui.RectangleEdge;
import org.jfree.ui.RectangleInsets;
import org.jfree.ui.Size2D;
import org.jfree.util.ObjectUtilities;
import org.jfree.util.PaintUtilities;
import org.jfree.util.ShapeUtilities;

/**
 * An axis that displays categories.
 */
public class CategoryAxis extends Axis implements Cloneable, Serializable {

    /** For serialization. */
    private static final long serialVersionUID = 5886554608114265863L;
    
    /** 
     * The default margin for the axis (used for both lower and upper margins).
     */
    public static final double DEFAULT_AXIS_MARGIN = 0.05;

    /** 
     * The default margin between categories (a percentage of the overall axis
     * length). 
     */
    public static final double DEFAULT_CATEGORY_MARGIN = 0.20;

    /** The amount of space reserved at the start of the axis. */
    private double lowerMargin;

    /** The amount of space reserved at the end of the axis. */
    private double upperMargin;

    /** The amount of space reserved between categories. */
    private double categoryMargin;
    
    /** The maximum number of lines for category labels. */
    private int maximumCategoryLabelLines;

    /** 
     * A ratio that is multiplied by the width of one category to determine the 
     * maximum label width. 
     */
    private float maximumCategoryLabelWidthRatio;
    
    /** The category label offset. */
    private int categoryLabelPositionOffset; 
    
    /** 
     * A structure defining the category label positions for each axis 
     * location. 
     */
    private CategoryLabelPositions categoryLabelPositions;
    
    /** Storage for tick label font overrides (if any). */
    private Map tickLabelFontMap;
    
    /** Storage for tick label paint overrides (if any). */
    private transient Map tickLabelPaintMap;
    
    /** Storage for the category label tooltips (if any). */
    private Map categoryLabelToolTips;

    /**
     * Creates a new category axis with no label.
     */
    public CategoryAxis() {
        this(null);    
    }
    
    /**
     * Constructs a category axis, using default values where necessary.
     *
     * @param label  the axis label (<code>null</code> permitted).
     */
    public CategoryAxis(String label) {

        super(label);

        this.lowerMargin = DEFAULT_AXIS_MARGIN;
        this.upperMargin = DEFAULT_AXIS_MARGIN;
        this.categoryMargin = DEFAULT_CATEGORY_MARGIN;
        this.maximumCategoryLabelLines = 1;
        this.maximumCategoryLabelWidthRatio = 0.0f;
        
        setTickMarksVisible(false);  // not supported by this axis type yet
        
        this.categoryLabelPositionOffset = 4;
        this.categoryLabelPositions = CategoryLabelPositions.STANDARD;
        this.tickLabelFontMap = new HashMap();
        this.tickLabelPaintMap = new HashMap();
        this.categoryLabelToolTips = new HashMap();
        
    }

    /**
     * Returns the lower margin for the axis.
     *
     * @return The margin.
     */
    public double getLowerMargin() {
        return this.lowerMargin;
    }

    /**
     * Sets the lower margin for the axis and sends an {@link AxisChangeEvent} 
     * to all registered listeners.
     *
     * @param margin  the margin as a percentage of the axis length (for 
     *                example, 0.05 is five percent).
     */
    public void setLowerMargin(double margin) {
        this.lowerMargin = margin;
        notifyListeners(new AxisChangeEvent(this));
    }

    /**
     * Returns the upper margin for the axis.
     *
     * @return The margin.
     */
    public double getUpperMargin() {
        return this.upperMargin;
    }

    /**
     * Sets the upper margin for the axis and sends an {@link AxisChangeEvent}
     * to all registered listeners.
     *
     * @param margin  the margin as a percentage of the axis length (for 
     *                example, 0.05 is five percent).
     */
    public void setUpperMargin(double margin) {
        this.upperMargin = margin;
        notifyListeners(new AxisChangeEvent(this));
    }

    /**
     * Returns the category margin.
     *
     * @return The margin.
     */
    public double getCategoryMargin() {
        return this.categoryMargin;
    }

    /**
     * Sets the category margin and sends an {@link AxisChangeEvent} to all 
     * registered listeners.  The overall category margin is distributed over 
     * N-1 gaps, where N is the number of categories on the axis.
     *
     * @param margin  the margin as a percentage of the axis length (for 
     *                example, 0.05 is five percent).
     */
    public void setCategoryMargin(double margin) {
        this.categoryMargin = margin;
        notifyListeners(new AxisChangeEvent(this));
    }

    /**
     * Returns the maximum number of lines to use for each category label.
     * 
     * @return The maximum number of lines.
     */
    public int getMaximumCategoryLabelLines() {
        return this.maximumCategoryLabelLines;
    }
    
    /**
     * Sets the maximum number of lines to use for each category label and
     * sends an {@link AxisChangeEvent} to all registered listeners.
     * 
     * @param lines  the maximum number of lines.
     */
    public void setMaximumCategoryLabelLines(int lines) {
        this.maximumCategoryLabelLines = lines;
        notifyListeners(new AxisChangeEvent(this));
    }
    
    /**
     * Returns the category label width ratio.
     * 
     * @return The ratio.
     */
    public float getMaximumCategoryLabelWidthRatio() {
        return this.maximumCategoryLabelWidthRatio;
    }
    
    /**
     * Sets the maximum category label width ratio and sends an 
     * {@link AxisChangeEvent} to all registered listeners.
     * 
     * @param ratio  the ratio.
     */
    public void setMaximumCategoryLabelWidthRatio(float ratio) {
        this.maximumCategoryLabelWidthRatio = ratio;
        notifyListeners(new AxisChangeEvent(this));
    }
    
    /**
     * Returns the offset between the axis and the category labels (before 
     * label positioning is taken into account).
     * 
     * @return The offset (in Java2D units).
     */
    public int getCategoryLabelPositionOffset() {
        return this.categoryLabelPositionOffset;
    }
    
    /**
     * Sets the offset between the axis and the category labels (before label 
     * positioning is taken into account).
     * 
     * @param offset  the offset (in Java2D units).
     */
    public void setCategoryLabelPositionOffset(int offset) {
        this.categoryLabelPositionOffset = offset;
        notifyListeners(new AxisChangeEvent(this));
    }
    
    /**
     * Returns the category label position specification (this contains label 
     * positioning info for all four possible axis locations).
     * 
     * @return The positions (never <code>null</code>).
     */
    public CategoryLabelPositions getCategoryLabelPositions() {
        return this.categoryLabelPositions;
    }
    
    /**
     * Sets the category label position specification for the axis and sends an 
     * {@link AxisChangeEvent} to all registered listeners.
     * 
     * @param positions  the positions (<code>null</code> not permitted).
     */
    public void setCategoryLabelPositions(CategoryLabelPositions positions) {
        if (positions == null) {
            throw new IllegalArgumentException("Null 'positions' argument.");   
        }
        this.categoryLabelPositions = positions;
        notifyListeners(new AxisChangeEvent(this));
    }
    
    /**
     * Returns the font for the tick label for the given category.
     * 
     * @param category  the category (<code>null</code> not permitted).
     * 
     * @return The font (never <code>null</code>).
     */
    public Font getTickLabelFont(Comparable category) {
        if (category == null) {
            throw new IllegalArgumentException("Null 'category' argument.");
        }
        Font result = (Font) this.tickLabelFontMap.get(category);
        // if there is no specific font, use the general one...
        if (result == null) {
            result = getTickLabelFont();
        }
        return result;
    }
    
    /**
     * Sets the font for the tick label for the specified category and sends
     * an {@link AxisChangeEvent} to all registered listeners.
     * 
     * @param category  the category (<code>null</code> not permitted).
     * @param font  the font (<code>null</code> permitted).
     */
    public void setTickLabelFont(Comparable category, Font font) {
        if (category == null) {
            throw new IllegalArgumentException("Null 'category' argument.");
        }
        if (font == null) {
            this.tickLabelFontMap.remove(category);
        }
        else {
            this.tickLabelFontMap.put(category, font);
        }
        notifyListeners(new AxisChangeEvent(this));
    }
    
    /**
     * Returns the paint for the tick label for the given category.
     * 
     * @param category  the category (<code>null</code> not permitted).
     * 
     * @return The paint (never <code>null</code>).
     */
    public Paint getTickLabelPaint(Comparable category) {
        if (category == null) {
            throw new IllegalArgumentException("Null 'category' argument.");
        }
        Paint result = (Paint) this.tickLabelPaintMap.get(category);
        // if there is no specific paint, use the general one...
        if (result == null) {
            result = getTickLabelPaint();
        }
        return result;
    }

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品久久久一区麻豆最新章节| 日本女人一区二区三区| 国产欧美日本一区二区三区| 欧美一级二级三级乱码| 欧美久久免费观看| 777午夜精品免费视频| 制服丝袜一区二区三区| 欧美一级理论片| 日韩精品在线看片z| 久久综合色天天久久综合图片| 日韩精品一区二区三区老鸭窝 | 91精彩视频在线观看| av动漫一区二区| 99re在线精品| 欧美日韩一区高清| 91精品在线麻豆| 精品久久久久久久久久久院品网 | 51久久夜色精品国产麻豆| 欧美男女性生活在线直播观看| 欧美日韩国产天堂| 欧美一区二区黄| 2014亚洲片线观看视频免费| 国产精品乱人伦中文| 亚洲视频你懂的| 亚洲国产精品久久人人爱蜜臀| 亚洲高清在线精品| 久久国产精品99久久久久久老狼 | 成人av资源网站| 欧美午夜电影网| 日韩欧美一卡二卡| 国产精品久久久久久久久久久免费看 | 精品久久久久久久久久久久久久久久久| 精品国产乱码久久久久久老虎| 久久九九99视频| 亚洲少妇最新在线视频| 视频一区欧美日韩| 国产精品一区免费视频| 91日韩精品一区| 欧美一区二区私人影院日本| 久久久av毛片精品| 一区二区三区在线观看国产| 免费人成网站在线观看欧美高清| 国产一区激情在线| 日本韩国精品在线| 精品国产乱码久久久久久牛牛| 国产精品久久久久久久久免费樱桃| 午夜久久久影院| 成人精品一区二区三区四区| 精品婷婷伊人一区三区三| 久久综合九色综合欧美98| 亚洲欧美成人一区二区三区| 美女视频免费一区| 色悠悠亚洲一区二区| 精品国产凹凸成av人导航| 亚洲少妇最新在线视频| 极品销魂美女一区二区三区| 在线观看国产日韩| 国产欧美日韩三级| 日韩成人精品视频| 91丨porny丨最新| 久久奇米777| 五月综合激情婷婷六月色窝| 成人黄页毛片网站| 日韩精品一区二区在线观看| 亚洲精品日韩综合观看成人91| 精品制服美女久久| 欧美日韩午夜精品| 亚洲欧美偷拍卡通变态| 国产麻豆精品95视频| 91麻豆精品国产91久久久资源速度 | 亚洲欧美aⅴ...| 国产一区欧美二区| 日韩午夜精品电影| 亚洲第一激情av| 97国产一区二区| 国产欧美精品一区| 极品少妇xxxx偷拍精品少妇| 欧美色区777第一页| 中文字幕中文字幕一区二区| 精品一区二区综合| 91精品国产一区二区| 亚洲精品高清在线| 99re热这里只有精品免费视频 | 久久精品国产免费看久久精品| 在线观看网站黄不卡| 中文字幕不卡三区| 国产一区二区三区久久悠悠色av | 亚洲高清视频在线| 色8久久人人97超碰香蕉987| 国产精品视频在线看| 国产一区二区三区不卡在线观看| 制服丝袜中文字幕一区| 日韩精品一二三区| 欧美日本一道本| 日韩一区欧美二区| 3751色影院一区二区三区| 日日夜夜精品免费视频| 欧美色成人综合| 亚洲高清免费视频| 欧美日韩一区在线| 亚洲线精品一区二区三区| 色噜噜狠狠色综合中国| 亚洲精品国产视频| 色香蕉成人二区免费| 亚洲欧美日韩一区| 色哟哟国产精品| 亚洲国产精品久久人人爱蜜臀| 欧美三级视频在线观看| 亚洲国产综合在线| 欧美精选一区二区| 日本不卡在线视频| 欧美大肚乱孕交hd孕妇| 国产中文字幕一区| 国产欧美日韩在线| av电影天堂一区二区在线| 18成人在线视频| 在线观看视频一区二区欧美日韩| 亚洲国产一区二区在线播放| 欧美日韩久久久一区| 麻豆精品久久精品色综合| 精品国产免费一区二区三区四区 | 久久99国产精品尤物| 久久久精品综合| 99久久免费精品| 五月婷婷久久综合| 精品久久久久一区二区国产| 粉嫩蜜臀av国产精品网站| 中文字幕亚洲欧美在线不卡| 日本道色综合久久| 偷偷要91色婷婷| 久久毛片高清国产| 97se狠狠狠综合亚洲狠狠| 亚洲午夜久久久久久久久电影网| 欧美福利视频导航| 国产乱人伦偷精品视频免下载| 国产精品美女久久久久久久网站| 色欲综合视频天天天| 秋霞影院一区二区| 国产免费成人在线视频| 色噜噜久久综合| 捆绑紧缚一区二区三区视频| 欧美国产日韩亚洲一区| 91福利在线导航| 久久精品国产澳门| 亚洲日本欧美天堂| 欧美一区二区三级| 国产91精品一区二区麻豆网站 | 天天操天天色综合| 久久亚洲欧美国产精品乐播| 一本一本大道香蕉久在线精品 | 蜜桃视频一区二区| 日韩一区在线免费观看| 欧美一区二区在线视频| av爱爱亚洲一区| 青青草成人在线观看| 国产精品盗摄一区二区三区| 91精品国产色综合久久久蜜香臀| 成人av电影在线| 麻豆视频一区二区| 亚洲一区欧美一区| 欧美国产乱子伦 | 国产精品丝袜在线| 日韩一级片在线播放| 色又黄又爽网站www久久| 国产精品一区二区果冻传媒| 亚洲高清免费视频| 最新热久久免费视频| 精品国产91洋老外米糕| 欧美中文字幕一区二区三区亚洲| 国产一区二区福利视频| 丝袜脚交一区二区| 亚洲欧美一区二区在线观看| 精品国产91洋老外米糕| 欧美酷刑日本凌虐凌虐| 91在线免费视频观看| 国产一区二区视频在线播放| 日本美女一区二区| 一区二区激情视频| 国产精品看片你懂得| 精品欧美一区二区久久| 欧美四级电影网| 91麻豆免费视频| 国产成人精品免费看| 九九**精品视频免费播放| 婷婷开心激情综合| 亚洲一区二区在线观看视频| 中文字幕中文字幕在线一区 | 欧美亚洲丝袜传媒另类| jiyouzz国产精品久久| 国产麻豆日韩欧美久久| 久久成人免费电影| 视频在线观看国产精品| 午夜精品久久久久久久久| 亚洲一区二区在线免费观看视频 | 国产成人av在线影院| 久久99国产精品免费网站| 蜜臀国产一区二区三区在线播放| 五月婷婷久久丁香| 日韩一区精品视频| 青草国产精品久久久久久|