chartPanel.restoreAutoBounds();
@Override public void actionPerformed(ActionEvent e) { chartPanel.restoreAutoBounds(); chartPanel.repaint(); } });
ChartPanel DCP=new ChartPanel(DailyChart){ @Override public void restoreAutoBounds(){ super.restoreAutoDomainBounds(); super.restoreAutoRangeBounds(); XYPlot plot=(XYPlot)getChart().getPlot(); Calendar Cal=Calendar.getInstance(); String dayName=Cal.getDisplayName(Calendar.DAY_OF_WEEK,Calendar.SHORT,new Locale("en", "us")).toLowerCase(); String tmp[]=((String)Configurations.getWeeklyWorkingSchedule().get(dayName).get("start")).split(":"); Cal.set(Calendar.HOUR_OF_DAY, Integer.parseInt(tmp[0])); Cal.set(Calendar.MINUTE, Integer.parseInt(tmp[1])); Cal.set(Calendar.SECOND, 0); long start=Cal.getTimeInMillis(); tmp=((String)Configurations.getWeeklyWorkingSchedule().get(dayName).get("end")).split(":"); Cal.set(Calendar.HOUR_OF_DAY, Integer.parseInt(tmp[0])); Cal.set(Calendar.MINUTE, Integer.parseInt(tmp[1])); Cal.set(Calendar.SECOND, 0); long end=Cal.getTimeInMillis(); plot.getDomainAxis().setAutoRange(false); plot.getDomainAxis().setRange(start,end); } }; DCP.restoreAutoBounds();
if ((hZoom && (e.getX() < this.zoomPoint.getX())) || (vZoom && (e.getY() < this.zoomPoint.getY()))) { restoreAutoBounds();
if ((hZoom && (e.getX() < this.zoomPoint.getX())) || (vZoom && (e.getY() < this.zoomPoint.getY()))) { restoreAutoBounds();
chartPanel.restoreAutoBounds(); range.setLowerBound(0); range.setUpperBound(1);
zoomAllButton.setName("zoomAllButton."); zoomAllButton.addActionListener(e -> { chartPanel.restoreAutoBounds(); chartPanel.repaint(); });
profilePlotDisplay.restoreAutoBounds(); xAxisRangeControl.getBindingContext().setComponentsEnabled(PROPERTY_NAME_MARK_SEGMENTS, profileData.getShapeVertices().length > 2);
profilePlotDisplay.restoreAutoBounds(); xAxisRangeControl.getBindingContext().setComponentsEnabled(PROPERTY_NAME_MARK_SEGMENTS, profileData.getShapeVertices().length > 2);