ddt 1.1.0
Loading...
Searching...
No Matches
Public Member Functions | List of all members
DdtGraphicsViewDraw Class Reference

#include <ddtGraphicsViewDraw.hpp>

Public Member Functions

 DdtGraphicsViewDraw ()=default
 
void DrawMeasurements (QPainter &painter, const QPointF start, const QPointF end) const
 
void CreateRefLine (DdtGraphicalElementRefLine *&ref_line_element, QGraphicsScene *const scene, const QPointF start, const QPointF end) const
 
void DrawRefLine (DdtGraphicalElementRefLine *&ref_line_element, QGraphicsScene *const scene, QPainter &painter, const QPointF start, const QPointF end) const
 
void CreateStatisticRect (DdtGraphicalElementStatRectangle *&statistic_rect, QGraphicsScene *const scene, const double x1, const double y1, const double x2, const double y2) const
 
void DrawStatisticRectangle (DdtGraphicalElementStatRectangle *&statistic_rect, QGraphicsScene *const scene, QPainter &painter, const QPointF start, const QPointF end) const
 
void DrawGraphicalElement (QGraphicsScene *const scene, QPainter &painter, const QPointF start, const QPointF end, const QString draw_mode, const DdtGraphicalElementProperties &overlay_properties, const QString overlay_image_file) const
 
void SetConvertPixelToDegrees (const double conv_pixel_degrees)
 

Detailed Description

Class to support drawing inside the graphic view.

Constructor & Destructor Documentation

◆ DdtGraphicsViewDraw()

DdtGraphicsViewDraw::DdtGraphicsViewDraw ( )
default

Constructor

Member Function Documentation

◆ CreateRefLine()

void DdtGraphicsViewDraw::CreateRefLine ( DdtGraphicalElementRefLine *&  ref_line_element,
QGraphicsScene *const  scene,
const QPointF  start,
const QPointF  end 
) const

Create the reference line graphic item and add it to the scene

◆ CreateStatisticRect()

void DdtGraphicsViewDraw::CreateStatisticRect ( DdtGraphicalElementStatRectangle *&  statistic_rect,
QGraphicsScene *const  scene,
const double  x1,
const double  y1,
const double  x2,
const double  y2 
) const

Create the statistic rectangle graphic item and add it to the scene

◆ DrawGraphicalElement()

void DdtGraphicsViewDraw::DrawGraphicalElement ( QGraphicsScene *const  scene,
QPainter &  painter,
const QPointF  start,
const QPointF  end,
const QString  draw_mode,
const DdtGraphicalElementProperties overlay_properties,
const QString  overlay_image_file 
) const

Draw a graphical element

Parameters
scenethe QGraphicsScene to add the element to
painterthe painter to be used for drawing
startthe first point to be used for the graphical element
endthe second point to be used for the graphical element
draw_modethe draw mode (which element to draw)
overlay_propertiesthe element properties to use for drawing
overlay_image_filethe path to the overlay image file (draw mode: image)

◆ DrawMeasurements()

void DdtGraphicsViewDraw::DrawMeasurements ( QPainter &  painter,
const QPointF  start,
const QPointF  end 
) const

Draw the measurement lines and texts

Parameters
painterthe painter to be used for drawing
startthe start point of the measurement
endthe end point of the measurement

◆ DrawRefLine()

void DdtGraphicsViewDraw::DrawRefLine ( DdtGraphicalElementRefLine *&  ref_line_element,
QGraphicsScene *const  scene,
QPainter &  painter,
const QPointF  start,
const QPointF  end 
) const

Draw a line for the reference line dialog

Parameters
ref_line_elementthe reference line element to draw, will be created if necessary
scenethe QGraphicsScene to add the element to
painterthe painter to be used for drawing
startfirst point of the line
endsecond point of the line

◆ DrawStatisticRectangle()

void DdtGraphicsViewDraw::DrawStatisticRectangle ( DdtGraphicalElementStatRectangle *&  statistic_rect,
QGraphicsScene *const  scene,
QPainter &  painter,
const QPointF  start,
const QPointF  end 
) const

Draw a rectangle for the statistic dialog

Parameters
statistic_rectthe statistic rectangle element to draw, will be created if necessary
scenethe QGraphicsScene to add the element to
painterthe painter to be used for drawing
startthe topLeft corner point
endthe bottomRight corner point

◆ SetConvertPixelToDegrees()

void DdtGraphicsViewDraw::SetConvertPixelToDegrees ( const double  conv_pixel_degrees)

Set the value for the factor to convert pixel distances to degrees

Parameters
conv_pixel_degreesthe factor to be used to convert pixel distances to degrees

The documentation for this class was generated from the following files: