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

# qwt_plot_item.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_ITEM
    00011 #define QWT_PLOT_ITEM
    00012
    00013 #include "qwt_global.h"
    00014
    00015 class QwtPlot;
    00016
    00021 class QWT_EXPORT QwtPlotItem
    00022 {
    00023 public:
    00024     QwtPlotItem(QwtPlot *parent, bool nbl = TRUE);
    00025     virtual ~QwtPlotItem();
    00026
    00027     void reparent(QwtPlot *plot);
    00028
    00030     QwtPlot *parentPlot() { return d_parent; }
    00031
    00033     const QwtPlot *parentPlot() const { return d_parent; }
    00034
    00035     virtual void setEnabled(bool);
    00036     bool enabled() const;
    00037
    00038     virtual void itemChanged();
    00039
    00040 private:
    00041     bool d_enabled;
    00042     QwtPlot *d_parent;
    00043 };
    00044
    00045
    00050 class QWT_EXPORT QwtPlotMappedItem : public QwtPlotItem
    00051 {
    00052 public:
    00053     QwtPlotMappedItem(QwtPlot *parent, bool nbl = TRUE);
    00054
    00055     void setAxis(int xAxis, int yAxis);
    00056
    00057     void setXAxis(int axis);
    00058     int xAxis() const;
    00059
    00060     void setYAxis(int axis);
    00061     int yAxis() const;
    00062
    00063 private:
    00064     int d_xAxis;
    00065     int d_yAxis;
    00066 };
    00067
    00068 #endif