DLS  1.6
DLS::Graph Class Reference

Graph widget. More...

Inherits QFrame.

Public Types

enum  RenderFlag { Plain = 0, MeasuringLine = 1, All = MeasuringLine }
 
enum  Interaction { Zoom, Pan, Measure }
 
enum  NamedRange {
  Today, Yesterday, ThisWeek, LastWeek,
  ThisMonth, LastMonth, ThisYear, LastYear
}
 

Public Slots

void previousView ()
 
void nextView ()
 
void loadData ()
 
void zoomIn ()
 
void zoomOut ()
 
void zoomReset ()
 
void setInteraction (Interaction)
 
void setNamedRange (NamedRange)
 
void pan (double)
 
void print ()
 
void setShowMessages (bool)
 
void setMessageFilter (const QString &)
 
void clearSections ()
 
void showExport ()
 

Signals

void logMessage (const QString &)
 
void asyncUpdate ()
 QWidget::update() does not trigger a repaint event, if the widget is not visible. More...
 

Public Member Functions

 Graph (QWidget *parent=0)
 
void setDropModel (QtDls::Model *)
 
virtual QSize sizeHint () const
 
bool load (const QString &, QtDls::Model *)
 
bool save (const QString &)
 
bool renderPage (QPainter &, const QRect &, unsigned int=0, RenderFlags=All)
 
void connectChannels (QtDls::Model *)
 
bool dirInUse (const LibDLS::Directory *)
 
SectionappendSection ()
 
SectioninsertSectionBefore (Section *)
 
void removeSection (Section *)
 
void updateRange ()
 
void setRange (const LibDLS::Time &, const LibDLS::Time &)
 
const LibDLS::TimegetStart () const
 
const LibDLS::TimegetEnd () const
 
QSet< QUrl > urls ()
 
const QList< LibDLS::Job::Message > & getMessages () const
 
const QString & getMessageFilter () const
 
QList< ChannelInfo > channelInfo ()
 
LibDLS::Time getMeasureTime () const
 
QMenu * getMenu ()
 

Protected Member Functions

bool event (QEvent *)
 
void mousePressEvent (QMouseEvent *)
 
void mouseReleaseEvent (QMouseEvent *)
 
void mouseMoveEvent (QMouseEvent *)
 
void leaveEvent (QEvent *)
 
void keyPressEvent (QKeyEvent *event)
 
void resizeEvent (QResizeEvent *)
 
void paintEvent (QPaintEvent *)
 
void contextMenuEvent (QContextMenuEvent *)
 
void dragEnterEvent (QDragEnterEvent *)
 
void dragLeaveEvent (QDragLeaveEvent *)
 
void dragMoveEvent (QDragMoveEvent *)
 
void dropEvent (QDropEvent *)
 
void wheelEvent (QWheelEvent *)
 
void retranslate ()
 

Friends

class GraphWorker
 
class Section
 

Detailed Description

Graph widget.

Definition at line 104 of file Graph.h.

Member Function Documentation

◆ asyncUpdate

void DLS::Graph::asyncUpdate ( )
signal

QWidget::update() does not trigger a repaint event, if the widget is not visible.

If this widget is used with qml it's render() function is used for painting thus no repaint trigger. The parent which captures events from Graph with an eventFilter does not get informed about the update. So we need this signal here.