2020-08-12 Fred Gleason <fredg@paravelsystems.com>

* Added 'RDFontEngine::bigLabelFont()' and
	'RDFontEngine::bigLabelFontMetrics()' methods.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason
2020-08-12 12:22:35 -04:00
parent 88e0544874
commit ad028fd7c5
7 changed files with 52 additions and 0 deletions

View File

@@ -54,6 +54,7 @@ RDFontEngine::~RDFontEngine()
delete font_big_button_font_metrics;
delete font_sub_button_font_metrics;
delete font_section_label_font_metrics;
delete font_big_label_font_metrics;
delete font_label_font_metrics;
delete font_sub_label_font_metrics;
delete font_progress_font_metrics;
@@ -124,6 +125,18 @@ QFontMetrics *RDFontEngine::sectionLabelFontMetrics() const
}
QFont RDFontEngine::bigLabelFont() const
{
return font_big_label_font;
}
QFontMetrics *RDFontEngine::bigLabelFontMetrics() const
{
return font_big_label_font_metrics;
}
QFont RDFontEngine::labelFont() const
{
return font_label_font;
@@ -264,6 +277,10 @@ void RDFontEngine::MakeFonts(const QFont &default_font)
font_section_label_font.setPixelSize(label_size+2);
font_section_label_font_metrics=new QFontMetrics(font_section_label_font);
font_big_label_font=QFont(family,label_size+4,QFont::Bold);
font_big_label_font.setPixelSize(label_size+4);
font_big_label_font_metrics=new QFontMetrics(font_label_font);
font_label_font=QFont(family,label_size,QFont::Bold);
font_label_font.setPixelSize(label_size);
font_label_font_metrics=new QFontMetrics(font_label_font);

View File

@@ -42,6 +42,8 @@ class RDFontEngine
QFontMetrics *subButtonFontMetrics() const;
QFont sectionLabelFont() const;
QFontMetrics *sectionLabelFontMetrics() const;
QFont bigLabelFont() const;
QFontMetrics *bigLabelFontMetrics() const;
QFont labelFont() const;
QFontMetrics *labelFontMetrics() const;
QFont subLabelFont() const;
@@ -69,6 +71,8 @@ class RDFontEngine
QFontMetrics *font_sub_button_font_metrics;
QFont font_section_label_font;
QFontMetrics *font_section_label_font_metrics;
QFont font_big_label_font;
QFontMetrics *font_big_label_font_metrics;
QFont font_label_font;
QFontMetrics *font_label_font_metrics;
QFont font_sub_label_font;