Package org.zkforge.timeplot.geometry

Examples of org.zkforge.timeplot.geometry.DefaultTimeGeometry


        // TODO Auto-generated method stub
        timeplot = new Timeplot();
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("#000000");
        vg.setAxisLabelsPlacement("left");
        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setGridStep(2 * 60 * 60 * 1000);
        tg.setAxisLabelsPlacement("bottom");
        tg.setGridStepRange(30 * 60 * 1000);
        timeplot.setWidth("100%");
        timeplot.setHeight("300px");
        plotinfo = new Plotinfo();
        plotinfo.setShowValues(true);
        ListModelList dataModel = new ListModelList(initDataMode());
View Full Code Here


        // TODO Auto-generated method stub
        timeplot = new Timeplot();
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("#000000");
        vg.setAxisLabelsPlacement("left");
        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setAxisLabelsPlacement("bottom");
        timeplot.setWidth("100%");
        timeplot.setHeight("300px");
        plotinfo = new Plotinfo();
        plotinfo.setShowValues(true);
        ListModelList dataModel = new ListModelList(initDataMode());
View Full Code Here

        databuff = initDataMode();
        ListModelList dataModel1 = new ListModelList(databuff.get(0));
        ListModelList dataModel2 = new ListModelList(databuff.get(1));
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("#000000");
        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setGridStep(2 * 60 * 60 * 1000);
        tg.setAxisLabelsPlacement("bottom");
        tg.setGridStepRange(30 * 60 * 1000);
        PlotDataSource pds = new PlotDataSource();
        pds.setSeparator(" ");
        dfPlot1.setPlotDataSource(pds);
        dfPlot1.setValueGeometry(vg);
        dfPlot1.setTimeGeometry(tg);
View Full Code Here

        ListModelList dataModel2 = new ListModelList(databuff.get(1));
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("#000000");
        vg.setMin(8);
        vg.setMax(23);
        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setGridStep(2 * 60 * 60 * 1000);
        bugBtn.addEventListener("onClick", new EventListener()
        {

            @Override
            public void onEvent(Event event) throws Exception
            {
                Date begin = format.parse("2009/01/01 13:00:00");
                Date end = format.parse("2009/01/01 18:00:00");
                timeplot.invalidate();
                // new date reference
                dfPlot1.setDataModel(generateData(new Date(begin.getTime()), end));
                dfPlot2.setDataModel(generateData(new Date(begin.getTime()), end));

            }
        });
//        ValueGeometry vg2 = new DefaultValueGeometry();
//        vg2.setGridColor("#000000");
//        vg2.setMin(8);
//        vg2.setMax(23);
        // tg.setMax((int) (new Date().getTime()+2*60*60*1000));
        tg.setAxisLabelsPlacement("bottom");
        tg.setGridStepRange(30 * 60 * 1000);
        PlotDataSource pds = new PlotDataSource();
        pds.setSeparator(" ");
        dfPlot1.setRoundValues(false);
        dfPlot1.setPlotDataSource(pds);
        dfPlot1.setValueGeometry(vg);
View Full Code Here

        ListModelList dataModel1 = new ListModelList(databuff.get(0));
        ListModelList dataModel2 = new ListModelList(databuff.get(1));
        ListModelList dataModel3 = new ListModelList(databuff.get(2));
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("#000000");
        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setGridStep(2 * 60 * 60 * 1000);
        tg.setAxisLabelsPlacement("bottom");
        tg.setGridStepRange(30 * 60 * 1000);
        PlotDataSource pds = new PlotDataSource();
        pds.setSeparator(" ");
        dfPlot1.setPlotDataSource(pds);
        dfPlot1.setValueGeometry(vg);
        dfPlot1.setTimeGeometry(tg);
View Full Code Here

    {
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("red");
        vg.setAxisLabelsPlacement("left");

        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setAxisLabelsPlacement("bottom");
        tg.setFormat(TimeGeometry.FORMAT_YEAR, "YYYY");
        tg.setGridColor("red");
        tg.setFormat(TimeGeometry.FORMAT_HOUR,"HH:mm ");
        plot1.setValueGeometry(vg);
        plot1.setTimeGeometry(tg);
        plot1.setShowValues(true);
        plot1.setHideValueFlag(true);
        plot1.setRoundValues(false);
View Full Code Here

    {
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("red");
        vg.setAxisLabelsPlacement("left");

        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setAxisLabelsPlacement("bottom");
        tg.setFormat(TimeGeometry.FORMAT_YEAR, "YYYY");
        tg.setGridColor("red");
        tg.setFormat(TimeGeometry.FORMAT_HOUR,"HH:mm ");
        plot1.setValueGeometry(vg);
        plot1.setTimeGeometry(tg);
        plot1.setShowValues(true);
        plot1.setHideValueFlag(true);
        plot1.setRoundValues(false);
View Full Code Here

        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("red");
        vg.setAxisLabelsPlacement("left");


        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setAxisLabelsPlacement("bottom");
        tg.setFormat(TimeGeometry.FORMAT_DAY, "yyyy-MM-dd hh:mm:ss");
        tg.setGridColor("red");
    
        plot1.setValueGeometry(vg);
        plot1.setTimeGeometry(tg);
        plot1.setShowValues(true);
//        plot1.setHideValueFlag(true);
View Full Code Here

        Plotinfo plot1 = new Plotinfo();
        ValueGeometry vg = new DefaultValueGeometry();
        vg.setGridColor("red");
        vg.setAxisLabelsPlacement("left");

        TimeGeometry tg = new DefaultTimeGeometry();
        tg.setAxisLabelsPlacement("bottom");
        tg.setGridColor("red");
        plot1.setValueGeometry(vg);
        plot1.setTimeGeometry(tg);
        plot1.setShowValues(true);
       
        plot1.addEventListener(OverPlotEvent.ON_OVER_PLOTDATA, new EventListener() {
View Full Code Here

    protected TimeGeometry getTimeGeometry(Interval interval) {
        LocalDate start = new LocalDate(interval.getStart());
        LocalDate finish = new LocalDate(interval.getFinish());

        TimeGeometry timeGeometry = new DefaultTimeGeometry();

        if (!isZoomByDayOrWeek()) {
            start = getThursdayOfThisWeek(start);
            finish = getThursdayOfThisWeek(finish);
        }

        timeGeometry.setMin(start.toDateTimeAtStartOfDay().toDate());
        timeGeometry.setMax(finish.toDateTimeAtStartOfDay().toDate());
        timeGeometry.setAxisLabelsPlacement("bottom");
        // Remove year separators
        timeGeometry.setGridColor("#FFFFFF");

        return timeGeometry;
    }
View Full Code Here

TOP

Related Classes of org.zkforge.timeplot.geometry.DefaultTimeGeometry

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.