[poppler] qt5/src qt6/src
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Mar 2 16:01:28 UTC 2022
qt5/src/poppler-annotation.cc | 6 ++++++
qt6/src/poppler-annotation.cc | 6 ++++++
2 files changed, 12 insertions(+)
New commits:
commit 4e8d336cc5b7bc848afd50bbe8211e5837f298a4
Author: Albert Astals Cid <aacid at kde.org>
Date: Wed Mar 2 16:53:33 2022 +0100
qt: Add a few "don't do anything if you're setting the same value we already have"
diff --git a/qt5/src/poppler-annotation.cc b/qt5/src/poppler-annotation.cc
index ddb773d8..d25b3a00 100644
--- a/qt5/src/poppler-annotation.cc
+++ b/qt5/src/poppler-annotation.cc
@@ -2089,6 +2089,9 @@ QFont TextAnnotation::textFont() const
void TextAnnotation::setTextFont(const QFont &font)
{
Q_D(TextAnnotation);
+ if (font == d->textFont) {
+ return;
+ }
d->textFont = font;
d->setDefaultAppearanceToNative();
@@ -2111,6 +2114,9 @@ QColor TextAnnotation::textColor() const
void TextAnnotation::setTextColor(const QColor &color)
{
Q_D(TextAnnotation);
+ if (color == d->textColor) {
+ return;
+ }
d->textColor = color;
d->setDefaultAppearanceToNative();
diff --git a/qt6/src/poppler-annotation.cc b/qt6/src/poppler-annotation.cc
index c1c61259..3ee4a83c 100644
--- a/qt6/src/poppler-annotation.cc
+++ b/qt6/src/poppler-annotation.cc
@@ -1660,6 +1660,9 @@ QFont TextAnnotation::textFont() const
void TextAnnotation::setTextFont(const QFont &font)
{
Q_D(TextAnnotation);
+ if (font == d->textFont) {
+ return;
+ }
d->textFont = font;
d->setDefaultAppearanceToNative();
@@ -1682,6 +1685,9 @@ QColor TextAnnotation::textColor() const
void TextAnnotation::setTextColor(const QColor &color)
{
Q_D(TextAnnotation);
+ if (color == d->textColor) {
+ return;
+ }
d->textColor = color;
d->setDefaultAppearanceToNative();
More information about the poppler
mailing list