libosmscout 0.1
Loading...
Searching...
No Matches
osmscout::LabelMeasurementKey Class Reference

Key of a label measurement: the arguments a backend's Layout() call receives and the parameters that backend's Layout() reads on top of them. More...

#include <LabelLayouter.h>

Public Member Functions

bool operator== (const LabelMeasurementKey &other) const
 

Public Attributes

bool contourLabel {false}
 
bool enableWrapping {false}
 
double fontSize {0.0}
 
bool labelLineFitToArea {false}
 
double labelLineFitToWidth {0.0}
 
size_t labelLineMaxCharCount {0}
 
size_t labelLineMinCharCount {0}
 
double objectWidth {0.0}
 
std::string text
 

Detailed Description

Key of a label measurement: the arguments a backend's Layout() call receives and the parameters that backend's Layout() reads on top of them.

Two labels with the same key measure the same, so the second one can reuse the first measurement.

The parameters of the line wrapping (LabelLineMinCharCount, LabelLineMaxCharCount, LabelLineFitToArea, LabelLineFitToWidth) are no argument of Layout(), but the backends that wrap a label ask MapPainter::GetProposedLabelWidth for the width they wrap with, and that call reads them. A frame that sees them changed therefore measures again.

Member Function Documentation

◆ operator==()

bool osmscout::LabelMeasurementKey::operator== ( const LabelMeasurementKey &  other) const
inline

Member Data Documentation

◆ contourLabel

bool osmscout::LabelMeasurementKey::contourLabel {false}

◆ enableWrapping

bool osmscout::LabelMeasurementKey::enableWrapping {false}

◆ fontSize

double osmscout::LabelMeasurementKey::fontSize {0.0}

◆ labelLineFitToArea

bool osmscout::LabelMeasurementKey::labelLineFitToArea {false}

◆ labelLineFitToWidth

double osmscout::LabelMeasurementKey::labelLineFitToWidth {0.0}

◆ labelLineMaxCharCount

size_t osmscout::LabelMeasurementKey::labelLineMaxCharCount {0}

◆ labelLineMinCharCount

size_t osmscout::LabelMeasurementKey::labelLineMinCharCount {0}

◆ objectWidth

double osmscout::LabelMeasurementKey::objectWidth {0.0}

◆ text

std::string osmscout::LabelMeasurementKey::text

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