【发布时间】:2009-11-26 14:54:35
【问题描述】:
我正在尝试让 jfreechart PieChart3D 隐藏标签。我在文档中找不到任何内容。
有人知道怎么做吗?
<% response.setContentType("image/png"); %><%@page import="org.jfree.data.general.*"%><%@page import="org.jfree.chart.*"%><%@page import="org.jfree.chart.plot.*"%><%@page import="java.awt.Color" %><%
DefaultPieDataset ds = (DefaultPieDataset)session.getAttribute("usagePieOutputDataset");
JFreeChart chart = ChartFactory.createPieChart3D
(
null, // Title
ds, // Dataset
false, // Show legend
false, // Use tooltips
false // Configure chart to generate URLs?
);
chart.setBackgroundPaint(Color.WHITE);
chart.setBorderVisible(false);
PiePlot3D plot = ( PiePlot3D )chart.getPlot();
plot.setDepthFactor(0.0);
plot.setLabelOutlinePaint(Color.LIGHT_GRAY);
plot.setLabelFont(new java.awt.Font("Arial", java.awt.Font.BOLD, 10));
ChartUtilities.writeChartAsPNG(response.getOutputStream(), chart, 150, 144);
%>
http://www.jfree.org/jfreechart/api/javadoc/org/jfree/chart/plot/PiePlot3D.html
【问题讨论】:
-
你检查我的答案了吗?对此不予置评,也不接受。这对你不起作用吗?还是不是你想要的?
标签: java jfreechart