Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 784
  • Last Modified:

JFreeChart: Time Series Chart - Set plot line invsible

Can we make the plot line go invisible?

If yes, please provide some sample code. Thanks!
0
dshrenik
Asked:
dshrenik
  • 4
1 Solution
 
for_yanCommented:
If you want to have just the lines in the plot to be invisible set them to samwe color as the background
0
 
for_yanCommented:
just get
plot.getBackgroundPaint()

and assign this paint to the series which you want to be invisible, as you assigned color to them before
0
 
dshrenikAuthor Commented:
But, can I explicitly set the visible=false?
This way, I don't have make changes when I change the background color.
0
 
for_yanCommented:

maybe even one method for all series:

 public void setBaseSeriesVisible(boolean visible);
Calls setBaseSeriesVisible(visible, true). See the next method description for details.

But this may not work, as:

The base  flag, which defaults to true, applies when there is no override
flag set and no series level flag set

(see page 468 of the manual).
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now