Search for usage in LXR

#include <KChartTextLabelCache.h>

Inheritance diagram for PrerenderedLabel:

Public Member Functions

qreal angle () const
const QBrushbrush () const
const QFontfont () const
const QPenpen () const
const QPixmappixmap () const override
QPointF referencePointLocation () const
QPointF referencePointLocation (KChartEnums::PositionValue position) const override
void setAngle (qreal angle)
void setBrush (const QBrush &brush)
void setFont (const QFont &font)
void setPen (const QPen &)
void setText (const QString &text)
const QStringtext () const
- Public Member Functions inherited from PrerenderedElement
const QPointFposition () const
KChartEnums::PositionValue referencePoint () const
void setPosition (const QPointF &position)
void setReferencePoint (KChartEnums::PositionValue)

Protected Member Functions

void invalidate () const override

Detailed Description

PrerenderedLabel is an internal KChart class that simplifies creation and caching of cached text labels.

It provides referenze points to anchor the text to other elements. Reference points use the positions defined in KChartEnums.


qreal angle = 90.0;
CachedLabel label;
label.paint( font, tr("Label"), angle );

Definition at line 83 of file KChartTextLabelCache.h.

Member Function Documentation

◆ angle()

qreal PrerenderedLabel::angle ( ) const
the label's angle in degrees

Definition at line 122 of file KChartTextLabelCache.cpp.

◆ brush()

const QBrush & PrerenderedLabel::brush ( ) const
the label's brush

Definition at line 111 of file KChartTextLabelCache.cpp.

◆ font()

const QFont & PrerenderedLabel::font ( ) const
the label's font.

Definition at line 89 of file KChartTextLabelCache.cpp.

◆ invalidate()

void PrerenderedLabel::invalidate ( ) const

Invalidates the preredendered data, forces re-rendering.

Implements PrerenderedElement.

Definition at line 78 of file KChartTextLabelCache.cpp.

◆ pixmap()

const QPixmap & PrerenderedLabel::pixmap ( ) const

Returns the rendered element.

If any of the properties have change, the element will be regenerated.

Implements PrerenderedElement.

Definition at line 127 of file KChartTextLabelCache.cpp.

◆ referencePointLocation()

QPointF PrerenderedLabel::referencePointLocation ( KChartEnums::PositionValue  ) const

Return the location of the reference point relatively to the pixmap's origin.

Implements PrerenderedElement.

Definition at line 245 of file KChartTextLabelCache.cpp.

◆ setAngle()

void PrerenderedLabel::setAngle ( qreal  angle)

Sets the angle of the label to angle degrees.

Definition at line 116 of file KChartTextLabelCache.cpp.

◆ setBrush()

void PrerenderedLabel::setBrush ( const QBrush brush)

Sets the label's brush to brush.

Definition at line 105 of file KChartTextLabelCache.cpp.

◆ setFont()

void PrerenderedLabel::setFont ( const QFont font)

Sets the label's font to font.

Definition at line 83 of file KChartTextLabelCache.cpp.

◆ setText()

void PrerenderedLabel::setText ( const QString text)

Sets the label's text to text.

Definition at line 94 of file KChartTextLabelCache.cpp.

◆ text()

const QString & PrerenderedLabel::text ( ) const
the label's text

Definition at line 100 of file KChartTextLabelCache.cpp.

The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sat May 21 2022 03:51:42 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.