From 816780e80943ef0ae6e645c1f912a5575fca9770 Mon Sep 17 00:00:00 2001 From: Georg Gadinger Date: Sun, 9 May 2021 21:08:04 +0200 Subject: skinned: use bitmap font if we really have all the characters available MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This makes tracks from e.g. "Turmion Kätilöt" or "Die Ärzte" display using the bitmap font. Since the characters seem to be UTF-8 anyway, it seems to be fine in my initial tests... --- src/plugins/Ui/skinned/skin.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/plugins/Ui/skinned/skin.h') diff --git a/src/plugins/Ui/skinned/skin.h b/src/plugins/Ui/skinned/skin.h index d342c1e5a..42f63946c 100644 --- a/src/plugins/Ui/skinned/skin.h +++ b/src/plugins/Ui/skinned/skin.h @@ -66,6 +66,11 @@ public: const QColor getMainColor(int n) const; const QColor &getVisColor(int n) const; const QRegion getRegion(uint r) const; + /*! + * Returns whether s only contains characters which have a bitmapped + * equivalent. + */ + const bool canUseBitmapFont(const QString& s) const; enum Button { @@ -297,6 +302,7 @@ private: QMap m_ms_parts; QMap m_parts; QMap m_letters; + QRegExp m_bitmapLetters; QMap m_pledit_txt; QMap m_regions; QPixmap m_main; -- cgit v1.2.3-13-gbd6f