Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members | File Members

Style.h

Go to the documentation of this file.
00001 //LabPlot : Style.h
00002 
00003 #ifndef STYLE_H
00004 #define STYLE_H
00005 
00006 #include <qcolor.h>
00007 
00008 class Style
00009 {
00010 public:
00011         Style(int t=0, QColor c="blue", bool f=0, QColor fc="green", int w=1,int p=1, int b=1 );
00012         void save(QTextStream *t);
00013         int open(QTextStream *t,int version);           // returns graph type
00014         int Type() { return type; }
00015         void setType(int t) { type = t; }
00016         QColor Color() { return color; }
00017         void setColor(QString c) { color = QColor(c); }
00018         void setColor(QColor c) { color = c; }
00019         int Width() { return width; }
00020         void setWidth(int w) { width = w; }
00021         int PenStyle() { return penStyle; }
00022         void setPenStyle(int p) { penStyle = p; }
00023         int Brush() { return brush; }
00024         void setBrush (int b) { brush = b; }
00025         bool isFilled() { return fill; }
00026         void setFilled(int f) { fill = f; }
00027         QColor FillColor() { return fillcolor; }
00028         void setFillColor(QString c) { fillcolor = QColor(c); }
00029         void setFillColor(QColor c) { fillcolor = c; }
00030         int BoxWidth() { return boxwidth; }
00031         void setBoxWidth(int b) { boxwidth = b; }
00032         bool AutoBoxWidth() { return autoboxwidth; }
00033         void setAutoBoxWidth(bool b=true) { autoboxwidth = b; }
00034 private:
00035         int type;               // type : line,noline,steps,boxes,impulses,yboxes
00036         QColor color;           // line color
00037         int width;              // line width
00038         bool fill;              // filled to baseline
00039         QColor fillcolor;       // fill color
00040         int penStyle;           // pen style :NoPen, SolidLine, DashLine, DotLine, DashDotLine, DashDotDotLine
00041         int brush;              // fill brush : NoBrush, Solid, Dense1, Dense2, Dense3, Dense4, Dense5,
00042                                 //       Dense6, Dense7, Horizontal, Vertical, Cross, BDiag, FDiag, DiagCross
00043         int boxwidth;           // width for type boxes
00044         bool autoboxwidth;      // automatic box width
00045 };
00046 
00047 #endif // STYLE_H

Generated on Fri Aug 19 21:34:45 2005 for LabPlot by doxygen 1.3.6