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

📄 defaultpolaritemrenderer.html

📁 jfreechart1。0。2的api。
💻 HTML
📖 第 1 页 / 共 3 页
字号:
<FONT color="green">274</FONT>                Point p = plot.translateValueThetaRadiusToJava2D(<a name="line.274"></a><FONT color="green">275</FONT>                    90.0, tick.getNumber().doubleValue(), dataArea<a name="line.275"></a><FONT color="green">276</FONT>                );<a name="line.276"></a><FONT color="green">277</FONT>                int r = p.x - center.x;<a name="line.277"></a><FONT color="green">278</FONT>                int upperLeftX = center.x - r;<a name="line.278"></a><FONT color="green">279</FONT>                int upperLeftY = center.y - r;<a name="line.279"></a><FONT color="green">280</FONT>                int d = 2 * r;<a name="line.280"></a><FONT color="green">281</FONT>                Ellipse2D ring = new Ellipse2D.Double(upperLeftX, upperLeftY, d, d);<a name="line.281"></a><FONT color="green">282</FONT>                g2.setPaint(plot.getRadiusGridlinePaint());<a name="line.282"></a><FONT color="green">283</FONT>                g2.draw(ring);<a name="line.283"></a><FONT color="green">284</FONT>            }<a name="line.284"></a><FONT color="green">285</FONT>        }<a name="line.285"></a><FONT color="green">286</FONT>    <a name="line.286"></a><FONT color="green">287</FONT>        /**<a name="line.287"></a><FONT color="green">288</FONT>         * Return the legend for the given series.<a name="line.288"></a><FONT color="green">289</FONT>         * <a name="line.289"></a><FONT color="green">290</FONT>         * @param series  the series index.<a name="line.290"></a><FONT color="green">291</FONT>         * <a name="line.291"></a><FONT color="green">292</FONT>         * @return The legend item.<a name="line.292"></a><FONT color="green">293</FONT>         */<a name="line.293"></a><FONT color="green">294</FONT>        public LegendItem getLegendItem(int series) {<a name="line.294"></a><FONT color="green">295</FONT>            LegendItem result = null;<a name="line.295"></a><FONT color="green">296</FONT>            PolarPlot polarPlot = getPlot();<a name="line.296"></a><FONT color="green">297</FONT>            if (polarPlot != null) {<a name="line.297"></a><FONT color="green">298</FONT>                XYDataset dataset;<a name="line.298"></a><FONT color="green">299</FONT>                dataset = polarPlot.getDataset();<a name="line.299"></a><FONT color="green">300</FONT>                if (dataset != null) {<a name="line.300"></a><FONT color="green">301</FONT>                    String label = dataset.getSeriesKey(series).toString();<a name="line.301"></a><FONT color="green">302</FONT>                    String description = label;<a name="line.302"></a><FONT color="green">303</FONT>                    Shape shape = getSeriesShape(series);<a name="line.303"></a><FONT color="green">304</FONT>                    Paint paint = getSeriesPaint(series);<a name="line.304"></a><FONT color="green">305</FONT>                    Paint outlinePaint = getSeriesOutlinePaint(series);<a name="line.305"></a><FONT color="green">306</FONT>                    Stroke outlineStroke = getSeriesOutlineStroke(series);<a name="line.306"></a><FONT color="green">307</FONT>                    result = new LegendItem(label, description, null, null, <a name="line.307"></a><FONT color="green">308</FONT>                            shape, paint, outlineStroke, outlinePaint);<a name="line.308"></a><FONT color="green">309</FONT>                }<a name="line.309"></a><FONT color="green">310</FONT>            }<a name="line.310"></a><FONT color="green">311</FONT>            return result;<a name="line.311"></a><FONT color="green">312</FONT>        }<a name="line.312"></a><FONT color="green">313</FONT>    <a name="line.313"></a><FONT color="green">314</FONT>        /**<a name="line.314"></a><FONT color="green">315</FONT>         * Tests this renderer for equality with an arbitrary object.<a name="line.315"></a><FONT color="green">316</FONT>         * <a name="line.316"></a><FONT color="green">317</FONT>         * @param obj  the object (&lt;code&gt;null&lt;/code&gt; not permitted).<a name="line.317"></a><FONT color="green">318</FONT>         * <a name="line.318"></a><FONT color="green">319</FONT>         * @return &lt;code&gt;true&lt;/code&gt; if this renderer is equal to &lt;code&gt;obj&lt;/code&gt;,<a name="line.319"></a><FONT color="green">320</FONT>         *     and &lt;code&gt;false&lt;/code&gt; otherwise.<a name="line.320"></a><FONT color="green">321</FONT>         */<a name="line.321"></a><FONT color="green">322</FONT>        public boolean equals(Object obj) {<a name="line.322"></a><FONT color="green">323</FONT>            if (obj == null) {<a name="line.323"></a><FONT color="green">324</FONT>                return false;<a name="line.324"></a><FONT color="green">325</FONT>            }<a name="line.325"></a><FONT color="green">326</FONT>            if (!(obj instanceof DefaultPolarItemRenderer)) {<a name="line.326"></a><FONT color="green">327</FONT>                return false;<a name="line.327"></a><FONT color="green">328</FONT>            }<a name="line.328"></a><FONT color="green">329</FONT>            DefaultPolarItemRenderer that = (DefaultPolarItemRenderer) obj;<a name="line.329"></a><FONT color="green">330</FONT>            if (!this.seriesFilled.equals(that.seriesFilled)) {<a name="line.330"></a><FONT color="green">331</FONT>                return false;<a name="line.331"></a><FONT color="green">332</FONT>            }<a name="line.332"></a><FONT color="green">333</FONT>            return super.equals(obj);<a name="line.333"></a><FONT color="green">334</FONT>        }<a name="line.334"></a><FONT color="green">335</FONT>        <a name="line.335"></a><FONT color="green">336</FONT>        /**<a name="line.336"></a><FONT color="green">337</FONT>         * Returns a clone of the renderer.<a name="line.337"></a><FONT color="green">338</FONT>         *<a name="line.338"></a><FONT color="green">339</FONT>         * @return A clone.<a name="line.339"></a><FONT color="green">340</FONT>         *<a name="line.340"></a><FONT color="green">341</FONT>         * @throws CloneNotSupportedException if the renderer cannot be cloned.<a name="line.341"></a><FONT color="green">342</FONT>         */<a name="line.342"></a><FONT color="green">343</FONT>        public Object clone() throws CloneNotSupportedException {<a name="line.343"></a><FONT color="green">344</FONT>            return super.clone();<a name="line.344"></a><FONT color="green">345</FONT>        }<a name="line.345"></a><FONT color="green">346</FONT>    <a name="line.346"></a><FONT color="green">347</FONT>    }<a name="line.347"></a></PRE></BODY></HTML>

⌨️ 快捷键说明

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