⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 thermometerplot.html

📁 jfreechart最新源代码
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<FONT color="green">602</FONT>        }<a name="line.602"></a><FONT color="green">603</FONT>    <a name="line.603"></a><FONT color="green">604</FONT>        /**<a name="line.604"></a><FONT color="green">605</FONT>         * Sets the location at which the axis is displayed with reference to the<a name="line.605"></a><FONT color="green">606</FONT>         * bulb.<a name="line.606"></a><FONT color="green">607</FONT>         * &lt;P&gt;<a name="line.607"></a><FONT color="green">608</FONT>         * The location can be one of the constants:<a name="line.608"></a><FONT color="green">609</FONT>         *   &lt;code&gt;NONE&lt;/code&gt;,<a name="line.609"></a><FONT color="green">610</FONT>         *   &lt;code&gt;RIGHT&lt;/code&gt; and<a name="line.610"></a><FONT color="green">611</FONT>         *   &lt;code&gt;LEFT&lt;/code&gt;.<a name="line.611"></a><FONT color="green">612</FONT>         *<a name="line.612"></a><FONT color="green">613</FONT>         * @param location  the location.<a name="line.613"></a><FONT color="green">614</FONT>         */<a name="line.614"></a><FONT color="green">615</FONT>        public void setAxisLocation(int location) {<a name="line.615"></a><FONT color="green">616</FONT>            if ((location &gt;= 0) &amp;&amp; (location &lt; 3)) {<a name="line.616"></a><FONT color="green">617</FONT>                this.axisLocation = location;<a name="line.617"></a><FONT color="green">618</FONT>                notifyListeners(new PlotChangeEvent(this));<a name="line.618"></a><FONT color="green">619</FONT>            }<a name="line.619"></a><FONT color="green">620</FONT>            else {<a name="line.620"></a><FONT color="green">621</FONT>                throw new IllegalArgumentException("Location not recognised.");<a name="line.621"></a><FONT color="green">622</FONT>            }<a name="line.622"></a><FONT color="green">623</FONT>        }<a name="line.623"></a><FONT color="green">624</FONT>    <a name="line.624"></a><FONT color="green">625</FONT>        /**<a name="line.625"></a><FONT color="green">626</FONT>         * Returns the axis location.<a name="line.626"></a><FONT color="green">627</FONT>         *<a name="line.627"></a><FONT color="green">628</FONT>         * @return The location.<a name="line.628"></a><FONT color="green">629</FONT>         */<a name="line.629"></a><FONT color="green">630</FONT>        public int getAxisLocation() {<a name="line.630"></a><FONT color="green">631</FONT>            return this.axisLocation;<a name="line.631"></a><FONT color="green">632</FONT>        }<a name="line.632"></a><FONT color="green">633</FONT>    <a name="line.633"></a><FONT color="green">634</FONT>        /**<a name="line.634"></a><FONT color="green">635</FONT>         * Gets the font used to display the current value.<a name="line.635"></a><FONT color="green">636</FONT>         *<a name="line.636"></a><FONT color="green">637</FONT>         * @return The font.<a name="line.637"></a><FONT color="green">638</FONT>         */<a name="line.638"></a><FONT color="green">639</FONT>        public Font getValueFont() {<a name="line.639"></a><FONT color="green">640</FONT>            return this.valueFont;<a name="line.640"></a><FONT color="green">641</FONT>        }<a name="line.641"></a><FONT color="green">642</FONT>    <a name="line.642"></a><FONT color="green">643</FONT>        /**<a name="line.643"></a><FONT color="green">644</FONT>         * Sets the font used to display the current value.<a name="line.644"></a><FONT color="green">645</FONT>         *<a name="line.645"></a><FONT color="green">646</FONT>         * @param f  the new font.<a name="line.646"></a><FONT color="green">647</FONT>         */<a name="line.647"></a><FONT color="green">648</FONT>        public void setValueFont(Font f) {<a name="line.648"></a><FONT color="green">649</FONT>            if ((f != null) &amp;&amp; (!this.valueFont.equals(f))) {<a name="line.649"></a><FONT color="green">650</FONT>                this.valueFont = f;<a name="line.650"></a><FONT color="green">651</FONT>                notifyListeners(new PlotChangeEvent(this));<a name="line.651"></a><FONT color="green">652</FONT>            }<a name="line.652"></a><FONT color="green">653</FONT>        }<a name="line.653"></a><FONT color="green">654</FONT>    <a name="line.654"></a><FONT color="green">655</FONT>        /**<a name="line.655"></a><FONT color="green">656</FONT>         * Gets the paint used to display the current value.<a name="line.656"></a><FONT color="green">657</FONT>        *<a name="line.657"></a><FONT color="green">658</FONT>         * @return The paint.<a name="line.658"></a><FONT color="green">659</FONT>         */<a name="line.659"></a><FONT color="green">660</FONT>        public Paint getValuePaint() {<a name="line.660"></a><FONT color="green">661</FONT>            return this.valuePaint;<a name="line.661"></a><FONT color="green">662</FONT>        }<a name="line.662"></a><FONT color="green">663</FONT>    <a name="line.663"></a><FONT color="green">664</FONT>        /**<a name="line.664"></a><FONT color="green">665</FONT>         * Sets the paint used to display the current value.<a name="line.665"></a><FONT color="green">666</FONT>         *<a name="line.666"></a><FONT color="green">667</FONT>         * @param p  the new paint.<a name="line.667"></a><FONT color="green">668</FONT>         */<a name="line.668"></a><FONT color="green">669</FONT>        public void setValuePaint(Paint p) {<a name="line.669"></a><FONT color="green">670</FONT>            if ((p != null) &amp;&amp; (!this.valuePaint.equals(p))) {<a name="line.670"></a><FONT color="green">671</FONT>                this.valuePaint = p;<a name="line.671"></a><FONT color="green">672</FONT>                notifyListeners(new PlotChangeEvent(this));<a name="line.672"></a><FONT color="green">673</FONT>            }<a name="line.673"></a><FONT color="green">674</FONT>        }<a name="line.674"></a><FONT color="green">675</FONT>    <a name="line.675"></a><FONT color="green">676</FONT>        /**<a name="line.676"></a><FONT color="green">677</FONT>         * Sets the formatter for the value label.<a name="line.677"></a><FONT color="green">678</FONT>         *<a name="line.678"></a><FONT color="green">679</FONT>         * @param formatter  the new formatter.<a name="line.679"></a><FONT color="green">680</FONT>         */<a name="line.680"></a><FONT color="green">681</FONT>        public void setValueFormat(NumberFormat formatter) {<a name="line.681"></a><FONT color="green">682</FONT>            if (formatter != null) {<a name="line.682"></a><FONT color="green">683</FONT>                this.valueFormat = formatter;<a name="line.683"></a><FONT color="green">684</FONT>                notifyListeners(new PlotChangeEvent(this));<a name="line.684"></a><FONT color="green">685</FONT>            }<a name="line.685"></a><FONT color="green">686</FONT>        }<a name="line.686"></a><FONT color="green">687</FONT>    <a name="line.687"></a><FONT color="green">688</FONT>        /**<a name="line.688"></a><FONT color="green">689</FONT>         * Returns the default mercury paint.<a name="line.689"></a><FONT color="green">690</FONT>         *<a name="line.690"></a><FONT color="green">691</FONT>         * @return The paint.<a name="line.691"></a><FONT color="green">692</FONT>         */<a name="line.692"></a><FONT color="green">693</FONT>        public Paint getMercuryPaint() {<a name="line.693"></a><FONT color="green">694</FONT>            return this.mercuryPaint;<a name="line.694"></a><FONT color="green">695</FONT>        }<a name="line.695"></a><FONT color="green">696</FONT>    <a name="line.696"></a><FONT color="green">697</FONT>        /**<a name="line.697"></a><FONT color="green">698</FONT>         * Sets the default mercury paint.<a name="line.698"></a><FONT color="green">699</FONT>         *<a name="line.699"></a><FONT color="green">700</FONT>         * @param paint  the new paint.<a name="line.700"></a><FONT color="green">701</FONT>         */<a name="line.701"></a><FONT color="green">702</FONT>        public void setMercuryPaint(Paint paint) {<a name="line.702"></a><FONT color="green">703</FONT>            this.mercuryPaint = paint;<a name="line.703"></a><FONT color="green">704</FONT>            notifyListeners(new PlotChangeEvent(this));<a name="line.704"></a><FONT color="green">705</FONT>        }<a name="line.705"></a><FONT color="green">706</FONT>    <a name="line.706"></a><FONT color="green">707</FONT>        /**<a name="line.707"></a><FONT color="green">708</FONT>         * Returns the flag that controls whether not value lines are displayed.<a name="line.708"></a><FONT color="green">709</FONT>         *<a name="line.709"></a><FONT color="green">710</FONT>         * @return The flag.<a name="line.710"></a><FONT color="green">711</FONT>         */<a name="line.711"></a><FONT color="green">712</FONT>        public boolean getShowValueLines() {<a name="line.712"></a><FONT color="green">713</FONT>            return this.showValueLines;<a name="line.713"></a><FONT color="green">714</FONT>        }<a name="line.714"></a><FONT color="green">715</FONT>    <a name="line.715"></a><FONT color="green">716</FONT>        /**<a name="line.716"></a><FONT color="green">717</FONT>         * Sets the display as to whether to show value lines in the output.<a name="line.717"></a><FONT color="green">718</FONT>         *<a name="line.718"></a><FONT color="green">719</FONT>         * @param b Whether to show value lines in the thermometer<a name="line.719"></a><FONT color="green">720</FONT>         */<a name="line.720"></a><FONT color="green">721</FONT>        public void setShowValueLines(boolean b) {<a name="line.721"></a><FONT color="green">722</FONT>            this.showValueLines = b;<a name="line.722"></a><FONT color="green">723</FONT>            notifyListeners(new PlotChangeEvent(this));<a name="line.723"></a><FONT color="green">724</FONT>        }<a name="line.724"></a><FONT color="green">725</FONT>    <a name="line.725"></a><FONT color="green">726</FONT>        /**<a name="line.726"></a><FONT color="green">727</FONT>         * Sets information for a particular range.<a name="line.727"></a><FONT color="green">728</FONT>         *<a name="line.728"></a><FONT color="green">729</FONT>         * @param range  the range to specify information about.<a name="line.729"></a><FONT color="green">730</FONT>         * @param low  the low value for the range<a name="line.730"></a><FONT color="green">731</FONT>         * @param hi  the high value for the range<a name="line.731"></a><FONT color="green">732</FONT>         */<a name="line.732"></a><FONT color="green">733</FONT>        public void setSubrangeInfo(int range, double low, double hi) {<a name="line.733"></a><FONT color="green">734</FONT>            setSubrangeInfo(range, low, hi, low, hi);<a name="line.734"></a><FONT color="green">735</FONT>        }<a name="line.735"></a><FONT color="green">736</FONT>    <a name="line.736"></a><FONT color="green">737</FONT>        /**<a name="line.737"></a><FONT color="green">738</FONT>         * Sets the subrangeInfo attribute of the ThermometerPlot object<a name="line.738"></a><FONT color="green">739</FONT>         *<a name="line.739"></a><FONT color="green">740</FONT>         * @param range  the new rangeInfo value.<a name="line.740"></a><FONT color="green">741</FONT>         * @param rangeLow  the new rangeInfo value<a name="line.741"></a><FONT color="green">742</FONT>         * @param rangeHigh  the new rangeInfo value<a name="line.742"></a><FONT color="green">743</FONT>         * @param displayLow  the new rangeInfo value<a name="line.743"></a><FONT color="green">744</FONT>         * @param displayHigh  the new rangeInfo value<a name="line.744"></a><FONT color="green">745</FONT>         */<a name="line.745"></a><FONT color="green">746</FONT>        public void setSubrangeInfo(int range,<a name="line.746"></a><FONT color="green">747</FONT>                                    double rangeLow, double rangeHigh,<a name="line.747"></a><FONT color="green">748</FONT>                                    double displayLow, double displayHigh) {<a name="line.748"></a><FONT color="green">749</FONT>    <a name="line.749"></a><FONT color="green">750</FONT>            if ((range &gt;= 0) &amp;&amp; (range &lt; 3)) {<a name="line.750"></a><FONT color="green">751</FONT>                setSubrange(rang

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -