Mouse Clicking On A Chart Causes Re-Rendering Of The Chart
Registered "Developer Guide" User, using JFreeChart 1.0.14 & JCommon 1.0.17, w/ NetBeans 7.0.1, & J2SE JDK 1.7.
Problem:
If a JPanel is used containing both a Table & Chart, as it would be the case w/ a TableChartViewPanel, such as
TableChartViewPanel extends javax.swing.JPanel
Whenever you do a "mouse click" on the "chart" area the response to the Jpanel's scroll bars becomes very sluggish - about 22 seconds are added to the response time w/ a "mouse click".
Setting up a "breakpoint" inside "ChartPanel.java" in the mouseClicked(MouseEvent event) handler, in "public void mouseClicked(MouseEvent event) {" is very hart to get it to stop there & then being able to continue to single step. What I also found out was that even if the code inside this "mouseClicked()" event handler is commented out, the app continues on to re-rendering of the chart, & this is what causes the sluggish performance w/ the Jpanel's scroll bars by (in my particular case) adding about a 22 second delay in its response time.
I was attempting to detect a "mouse click" & tried to "Consume()" the event, however after "pausing" the debugger, I found out that the app was running in re-rendering the chart, & it is my guess that is why this extra time is added to the response time.
I found out that is very hard to break (via breakpoint) & single step inside these event handler's, & thus it is hard to be able to "detect" the event, & somehow bypass it (by consuming it) & keep it from continuing onto re-rendering the chart you just clicked on.
Any information on these issues would be greatly appreciated.
Mouse Clicking On A Chart Causes Re-Rendering Of The Chart
-
- Posts: 4
- Joined: Tue Jan 10, 2012 5:21 pm
- antibot: No, of course not.