![]() |
Mapper
0.9.0
API documentation
|
A utility for displaying azimuth and distance while drawing. More...
#include <tool_helpers.h>
Public Member Functions | |
AzimuthInfoHelper (const QWidget *widget, QColor color) | |
bool | isActive () const |
void | setActive (bool active) |
QRectF | dirtyRect (MapWidget *widget, const MapCoordF &pos_map) const |
Returns this helper's drawing region. More... | |
void | draw (QPainter *painter, const MapWidget *widget, const Map *map, const MapCoordF &start_pos, const MapCoordF &end_pos) |
Draws the azimuth and distance info text. More... | |
Protected Attributes | |
QColor | text_color |
QFont | text_font |
QString | azimuth_template |
QString | distance_template |
QRectF | display_rect |
int | line_0_offset |
int | line_1_offset |
bool | active = false |
Static Protected Attributes | |
static constexpr int | text_offset = 25 |
A utility for displaying azimuth and distance while drawing.
QRectF OpenOrienteering::AzimuthInfoHelper::dirtyRect | ( | MapWidget * | widget, |
const MapCoordF & | pos_map | ||
) | const |
Returns this helper's drawing region.
void OpenOrienteering::AzimuthInfoHelper::draw | ( | QPainter * | painter, |
const MapWidget * | widget, | ||
const Map * | map, | ||
const MapCoordF & | start_pos, | ||
const MapCoordF & | end_pos | ||
) |
Draws the azimuth and distance info text.
|
inline |
void OpenOrienteering::AzimuthInfoHelper::setActive | ( | bool | active | ) |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
staticprotected |