QtiPlot
0.9.8.2
|
#include <RectangleWidget.h>
Public Slots | |
void | closedLinkedLayer (QObject *) |
Public Member Functions | |
void | clone (RectangleWidget *t) |
RectangleWidget (Graph *) | |
virtual QString | saveToString () |
void | setLinkedLayer (int layerIndex) |
void | updateCoordinates () |
![]() | |
int | angle () |
AttachPolicy | attachPolicy () |
QColor | backgroundColor () |
double | bottom () |
QRectF | boundingRect () const |
Return bounding rectangle in plot coordinates. | |
QBrush | brush () |
QColor | frameColor () |
Qt::PenStyle | frameLineStyle () |
QPen | framePen () |
int | frameStyle () |
FrameWidget (Graph *) | |
double | frameWidth () |
bool | isOnTop () |
void | mousePressEvent (QMouseEvent *) |
void | move (const QPoint &pos) |
Graph * | plot () |
virtual void | print (QPainter *p, const QwtScaleMap map[QwtPlot::axisCnt]) |
void | resetCoordinates () |
void | resetOrigin () |
double | right () |
void | setAngle (int ang) |
void | setAttachPolicy (AttachPolicy attachTo) |
void | setBackgroundColor (const QColor &c) |
void | setBrush (const QBrush &b) |
void | setCoordinates (double left, double top, double right, double bottom) |
Set position (xValue() and yValue()), right and bottom values giving everything in plot coordinates. | |
void | setFrameColor (const QColor &c) |
void | setFrameLineStyle (const Qt::PenStyle &s) |
void | setFramePen (const QPen &p) |
void | setFrameStyle (int style) |
void | setFrameWidth (double w) |
void | setOnTop (bool on=true) |
void | setOrigin (int x, int y) |
Sets the position of the top left corner in paint coordinates. | |
void | setOriginCoord (double x, double y) |
Sets the position of the top left corner in axis coordinates. | |
void | setRect (int x, int y, int w, int h) |
Set geometry, giving everything in paint coordinates. | |
void | setSize (int w, int h) |
Set size in paint coordinates (pixels). | |
void | setSize (const QSize &newSize) |
Set size in paint coordinates. | |
void | showContextMenu () |
void | showPropertiesDialog () |
double | xValue () |
Returns the x axis coordiante of the top left corner. | |
double | yValue () |
Returns the y axis coordiante of the top left corner. |
Static Public Member Functions | |
static void | restore (Graph *g, const QStringList &lst) |
![]() | |
static double | heightIn (QWidget *w, Unit unit) |
static void | setRect (QWidget *, double x, double y, double w, double h, Unit unit=Pixel) |
Set geometry of a widget in arbitrary units. | |
static double | widthIn (QWidget *w, Unit unit) |
static double | xIn (QWidget *w, Unit unit) |
static double | yIn (QWidget *w, Unit unit) |
Private Attributes | |
int | d_linked_layer |
Index of the linked layer using the rectangle coordinates as a zoom region. |
Additional Inherited Members | |
![]() | |
enum | AttachPolicy { Page, Scales } |
The attach to policy. More... | |
enum | FrameStyle { None = 0, Line = 1, Shadow = 2 } |
The kinds of frame a FrameWidget can draw around. More... | |
enum | Unit { Inch, Millimeter, Centimeter, Point, Pixel, Scale } |
Length units. More... | |
![]() | |
void | changedCoordinates (const QRectF &) |
void | showDialog () |
void | showMenu () |
![]() | |
double | calculateBottomValue () |
Returns the y axis coordinate of the bottom right corner based on the pixel value. | |
double | calculateRightValue () |
Returns the x axis coordinate of the bottom right corner based on the pixel value. | |
double | calculateXValue () |
Returns the x axis coordinate of the top left corner based on the pixel value. | |
double | calculateYValue () |
Returns the y axis coordinate of the top left corner based on the pixel value. | |
void | contextMenuEvent (QContextMenuEvent *) |
virtual void | drawFrame (QPainter *p, const QRect &rect) |
virtual void | paintEvent (QPaintEvent *e) |
![]() | |
int | d_angle |
Rotation angle: not implemented yet. | |
AttachPolicy | d_attach_policy |
The attach to policy. | |
QBrush | d_brush |
Background brush. | |
int | d_frame |
Frame type. | |
QPen | d_frame_pen |
Pen used to draw the frame. | |
bool | d_on_top |
Graph * | d_plot |
Parent plot. | |
int | d_shadow_width |
Frame width in pixels. | |
double | d_x |
X axis coordinate of the top left corner. | |
double | d_x_right |
The right side position in scale coordinates. | |
double | d_y |
Y axis coordinate of the top left corner. | |
double | d_y_bottom |
The bottom side position in scale coordinates. |
RectangleWidget::RectangleWidget | ( | Graph * | plot | ) |
References FrameWidget::Line, FrameWidget::setFrameStyle(), and FrameWidget::setSize().
Referenced by restore().
void RectangleWidget::clone | ( | RectangleWidget * | t | ) |
References FrameWidget::backgroundColor(), FrameWidget::bottom(), FrameWidget::brush(), FrameWidget::d_frame, FrameWidget::framePen(), FrameWidget::frameStyle(), FrameWidget::right(), FrameWidget::setBackgroundColor(), FrameWidget::setBrush(), FrameWidget::setCoordinates(), FrameWidget::setFramePen(), FrameWidget::xValue(), and FrameWidget::yValue().
|
slot |
References d_linked_layer.
Referenced by setLinkedLayer().
|
static |
References Graph::add(), FrameWidget::backgroundColor(), FrameWidget::bottom(), FrameWidget::brush(), PatternBox::brushStyle(), PenStyleBox::penStyle(), RectangleWidget(), FrameWidget::right(), FrameWidget::setAttachPolicy(), FrameWidget::setBackgroundColor(), FrameWidget::setBrush(), FrameWidget::setCoordinates(), FrameWidget::setFrameColor(), FrameWidget::setFrameLineStyle(), FrameWidget::setFrameStyle(), FrameWidget::setFrameWidth(), setLinkedLayer(), and FrameWidget::setOnTop().
Referenced by ApplicationWindow::openGraph().
|
virtual |
Reimplemented from FrameWidget.
References FrameWidget::backgroundColor(), FrameWidget::d_brush, d_linked_layer, and PatternBox::patternIndex().
void RectangleWidget::setLinkedLayer | ( | int | layerIndex | ) |
References FrameWidget::changedCoordinates(), closedLinkedLayer(), d_linked_layer, MultiLayer::layer(), Graph::multiLayer(), and FrameWidget::plot().
Referenced by restore(), updateCoordinates(), and ApplicationWindow::zoomRectanglePlot().
|
virtual |
Reimplemented from FrameWidget.
References FrameWidget::boundingRect(), FrameWidget::changedCoordinates(), d_linked_layer, and setLinkedLayer().
|
private |
Index of the linked layer using the rectangle coordinates as a zoom region.
Referenced by closedLinkedLayer(), saveToString(), setLinkedLayer(), and updateCoordinates().