OELegendLayoutOptions¶

class OELegendLayoutOptions


This class represents the OELegendLayoutOptions class that encapsulates properties that determine how an legend layout is depicted.

The OELegendLayoutOptions class stores the following properties:

Property

Get method

Set method

Corresponding namespace / class / type

legend layout style

GetLayoutStyle

(set by the constructor)

OELegendLayoutStyle namespace

legend color style

GetColorStyle

(set by the constructor)

OELegendColorStyle namespace

legend interactive style

GetInteractiveStyle

(set by the constructor)

OELegendInteractiveStyle namespace

button label font

GetButtonFont

SetButtonFont

OEFont

button pen(s)

GetButtonPen

SetButtonPen

OEPen

button height scale

GetButtonHeightScale

SetButtonHeightScale

positive floating point number in the range of $$[0.5, 3.0]$$

button width scale

GetButtonWidthScale

SetButtonWidthScale

positive floating point number in the range of $$[0.5, 5.0]$$

legend box pen

GetLegendBoxPen

SetLegendBoxPen

OEPen

layout margins

GetMargin

positive floating point number in the range of $$[0.0, 90.0]$$

Constructors¶

OELegendLayoutOptions(unsigned int layout=OELegendLayoutStyle::Default,
unsigned int color=OELegendColorStyle::Default,
unsigned int inter=OELegendInteractiveStyle::Default)

OELegendLayoutOptions(const OELegendLayoutOptions &rhs)


Copy constructor.

operator=¶

OELegendLayoutOptions &operator=(const OELegendLayoutOptions &rhs)


Assignment operator.

GetButtonFont¶

const OEFont& GetButtonFont() const


GetButtonHeightScale¶

double GetButtonHeightScale() const


GetButtonPen¶

const OEPen& GetButtonPen(bool on) const


GetButtonWidthScale¶

double GetButtonWidthScale() const


GetColorStyle¶

unsigned int GetColorStyle() const


GetInteractiveStyle¶

unsigned int GetInteractiveStyle() const


GetLayoutStyle¶

unsigned int GetLayoutStyle() const


GetLegendBoxPen¶

const OEPen& GetLegendBoxPen() const


GetMargin¶

double GetMargin(unsigned int percent) const


Returns the ratio of a specific margin of the legend layout.

margin

This value has to be from the OEMargin namespace.

SetButtonFont¶

void SetButtonFont(const OEFont &font)


SetButtonHeightScale¶

void SetButtonHeightScale(double scale)


SetButtonPen¶

void SetButtonPen(const OEPen &pen, bool on)


SetButtonWidthScale¶

void SetButtonWidthScale(double s)


SetLegendBoxPen¶

void SetLegendBoxPen(const OEPen &pen)


SetMargin¶

bool SetMargin(unsigned int margin, double percent)


Sets the size of a specific margin of the legend layout.

marginloc

This value has to be from the OEMargin namespace.

margin

This number is considered as a percentage of either the width or the height of image on which the legend layout will be drawn and has to be in the range of $$[0.0, 90.0]$$. For example, 10.0% means, that the left and right margin are 10% of the total width of the image, and the top and bottom margins are 10% of the total height of the image.

bool SetMargins(double margin)

This number is considered as a percentage of either the width or the height of image on which the legend layout will be drawn and has to be in the range of $$[0.0, 90.0]$$. For example, 10.0% means, that the left and right margin are 10% of the total width of the image, and the top and bottom margins are 10% of the total height of the image.