Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

qwt_plot_printfilter.h

00001 /* -*- mode: C++ ; c-file-style: "stroustrup" -*- *****************************
00002  * Qwt Widget Library
00003  * Copyright (C) 1997   Josef Wilgen
00004  * Copyright (C) 2002   Uwe Rathmann
00005  * 
00006  * This library is free software; you can redistribute it and/or
00007  * modify it under the terms of the Qwt License, Version 1.0
00008  *****************************************************************************/
00009 
00010 #ifndef QWT_PLOT_PRINTFILTER_H
00011 #define QWT_PLOT_PRINTFILTER_H
00012 
00013 #include <qcolor.h>
00014 #include <qfont.h>
00015 #include <qintdict.h>
00016 #include <qvaluelist.h>
00017 #include "qwt_global.h"
00018 
00019 class QwtPlot;
00020 class QwtPlotPrintFilterCache;
00021 
00028 class QWT_EXPORT QwtPlotPrintFilter
00029 {
00030 public:
00032     enum Options 
00033     {
00034         PrintMargin = 1,
00035         PrintTitle = 2,
00036         PrintLegend = 4,
00037         PrintGrid = 8,
00038         PrintCanvasBackground = 16,
00039         PrintWidgetBackground = 32,
00040 
00041         PrintAll = ~PrintWidgetBackground
00042     }; 
00043 
00045     enum Item
00046     {
00047         Title,
00048         Legend,
00049         Curve,
00050         CurveSymbol,
00051         Marker,
00052         MarkerSymbol,
00053         MajorGrid,
00054         MinorGrid,
00055         CanvasBackground,
00056         AxisScale,
00057         AxisTitle,
00058         WidgetBackground
00059     };
00060 
00061     QwtPlotPrintFilter();
00062     virtual ~QwtPlotPrintFilter(); 
00063 
00064     virtual QColor color(const QColor &, Item item, int id = -1) const;
00065     virtual QFont font(const QFont &, Item item, int id = -1) const;
00066 
00074     void setOptions(int options) { d_options = options; }
00075 
00081     int options() const { return d_options; }
00082 
00083     virtual void apply(QwtPlot *) const;
00084     virtual void reset(QwtPlot *) const;
00085 
00086 private:
00087     int d_options;
00088     QwtPlotPrintFilterCache *d_cache;
00089 };
00090 
00091 #endif

Generated on Sun Nov 21 11:12:44 2004 for Qwt User's Guide by doxygen 1.3.5