KD Reports API Documentation  2.2
Public Member Functions | List of all members
KDReports::FontScaler Class Reference

#include <KDReportsFontScaler_p.h>

Public Member Functions

 FontScaler (const QFont &initialFont)
 
void applyAdditionalScalingFactor (qreal factor)
 
QFont font () const
 
QFontMetricsF fontMetrics () const
 
QFontMetricsF initialFontMetrics () const
 
qreal scalingFactor () const
 
void setFactorForHeight (qreal wantedHeight)
 
void setFactorForWidth (qreal wantedFactor, const QString &sampleText)
 
void setFontAndScalingFactor (const QFont &font, qreal scalingFactor)
 
qreal textWidth (const QString &text) const
 

Detailed Description

Definition at line 36 of file KDReportsFontScaler_p.h.

Constructor & Destructor Documentation

◆ FontScaler()

FontScaler::FontScaler ( const QFont &  initialFont)
explicit

Definition at line 18 of file KDReportsFontScaler.cpp.

Member Function Documentation

◆ applyAdditionalScalingFactor()

void FontScaler::applyAdditionalScalingFactor ( qreal  factor)

◆ font()

QFont KDReports::FontScaler::font ( ) const
inline

◆ fontMetrics()

QFontMetricsF KDReports::FontScaler::fontMetrics ( ) const
inline

◆ initialFontMetrics()

QFontMetricsF KDReports::FontScaler::initialFontMetrics ( ) const
inline

Definition at line 59 of file KDReportsFontScaler_p.h.

◆ scalingFactor()

qreal KDReports::FontScaler::scalingFactor ( ) const
inline

◆ setFactorForHeight()

void FontScaler::setFactorForHeight ( qreal  wantedHeight)

◆ setFactorForWidth()

void FontScaler::setFactorForWidth ( qreal  wantedFactor,
const QString &  sampleText 
)

◆ setFontAndScalingFactor()

void FontScaler::setFontAndScalingFactor ( const QFont &  font,
qreal  scalingFactor 
)

Definition at line 26 of file KDReportsFontScaler.cpp.

References font(), and scalingFactor().

Referenced by KDReports::TableLayout::setInitialFontScalingFactor().

◆ textWidth()

qreal FontScaler::textWidth ( const QString &  text) const

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

© Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/
https://www.kdab.com/development-resources/qt-tools/kd-reports/
Generated by doxygen 1.9.1