From dd1d051b9f5aeda0b6c99d334f28d5fef201b3d1 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Fri, 24 Nov 2023 10:47:27 +0900 Subject: [PATCH] Replaced various '#define' with actual strings - part 3 Signed-off-by: Michele Calgaro --- src/linklabel.cpp | 2 +- src/regiongrabber.cpp | 2 +- src/tag.cpp | 10 +++++----- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/linklabel.cpp b/src/linklabel.cpp index 96c78e5..6663f97 100644 --- a/src/linklabel.cpp +++ b/src/linklabel.cpp @@ -453,7 +453,7 @@ void LinkDisplay::paint(TQPainter *painter, int x, int y, int width, int height, int pixmapY = (height - pixmap.height()) / 2; // Draw the button (if any) and the icon: if (isHovered) - kapp->style().tqdrawPrimitive(TQStyle::PE_ButtonCommand, painter, TQRect(-1, -1, iconPreviewWidth + 2*BUTTON_MARGIN, height + 2), + kapp->style().drawPrimitive(TQStyle::PE_ButtonCommand, painter, TQRect(-1, -1, iconPreviewWidth + 2*BUTTON_MARGIN, height + 2), colorGroup, TQStyle::Style_Enabled | (isIconButtonHovered ? TQStyle::Style_MouseOver : 0)); painter->drawPixmap(x + BUTTON_MARGIN - 1 + pixmapX, y + pixmapY, pixmap); diff --git a/src/regiongrabber.cpp b/src/regiongrabber.cpp index f519399..de7a19a 100644 --- a/src/regiongrabber.cpp +++ b/src/regiongrabber.cpp @@ -171,7 +171,7 @@ void RegionGrabber::drawRubber() p.setPen( TQPen( color0, 1 ) ); p.setBrush( NoBrush ); - style().tqdrawPrimitive( TQStyle::PE_FocusRect, &p, grabRect, colorGroup(), + style().drawPrimitive( TQStyle::PE_FocusRect, &p, grabRect, colorGroup(), TQStyle::Style_Default, TQStyleOption( colorGroup().base() ) ); p.end(); diff --git a/src/tag.cpp b/src/tag.cpp index b128bb7..c98cd87 100644 --- a/src/tag.cpp +++ b/src/tag.cpp @@ -867,7 +867,7 @@ TQIconSet StateMenuItem::checkBoxIconSet(bool checked, TQColorGroup cg) TQPainter painter(&pixmap); int style = TQStyle::Style_Enabled | TQStyle::Style_Active | (checked ? TQStyle::Style_On : TQStyle::Style_Off); TQColor background = cg.color(TQColorGroup::Background); - kapp->style().tqdrawPrimitive(TQStyle::PE_Indicator, &painter, rect, cg, style); + kapp->style().drawPrimitive(TQStyle::PE_Indicator, &painter, rect, cg, style); painter.end(); // Enabled, Hovering @@ -876,7 +876,7 @@ TQIconSet StateMenuItem::checkBoxIconSet(bool checked, TQColorGroup cg) painter.begin(&pixmapHover); style |= TQStyle::Style_MouseOver; cg.setColor(TQColorGroup::Background, TDEGlobalSettings::highlightColor()); - kapp->style().tqdrawPrimitive(TQStyle::PE_Indicator, &painter, rect, cg, style); + kapp->style().drawPrimitive(TQStyle::PE_Indicator, &painter, rect, cg, style); painter.end(); // Disabled @@ -885,7 +885,7 @@ TQIconSet StateMenuItem::checkBoxIconSet(bool checked, TQColorGroup cg) painter.begin(&pixmapDisabled); style = /*TQStyle::Style_Enabled | */TQStyle::Style_Active | (checked ? TQStyle::Style_On : TQStyle::Style_Off); cg.setColor(TQColorGroup::Background, background); - kapp->style().tqdrawPrimitive(TQStyle::PE_Indicator, &painter, rect, cg, style); + kapp->style().drawPrimitive(TQStyle::PE_Indicator, &painter, rect, cg, style); painter.end(); TQIconSet iconSet(pixmap); @@ -906,7 +906,7 @@ TQIconSet StateMenuItem::radioButtonIconSet(bool checked, TQColorGroup cg) pixmap.fill(TQt::red); TQPainter painter(&pixmap); /* We can't use that line of code (like for checkboxes): - * //kapp->style().tqdrawPrimitive(TQStyle::PE_ExclusiveIndicator, &painter, rect, cg, style); + * //kapp->style().drawPrimitive(TQStyle::PE_ExclusiveIndicator, &painter, rect, cg, style); * because Plastik (and derived styles) don't care of the TQStyle::Style_On flag and will ALWAYS draw an unchecked radiobutton. * So, we use another method: */ @@ -925,7 +925,7 @@ TQIconSet StateMenuItem::radioButtonIconSet(bool checked, TQColorGroup cg) TQPixmap pixmapHover(width, height); pixmapHover.fill(TQt::red); painter.begin(&pixmapHover); - //kapp->style().tqdrawPrimitive(TQStyle::PE_ExclusiveIndicator, &painter, rect, cg, style); + //kapp->style().drawPrimitive(TQStyle::PE_ExclusiveIndicator, &painter, rect, cg, style); style |= TQStyle::Style_MouseOver; cg.setColor(TQColorGroup::Background, TDEGlobalSettings::highlightColor()); kapp->style().drawControl(TQStyle::CE_RadioButton, &painter, &rb, rect, cg, style);