diff options
Diffstat (limited to 'style/qtcurve.h')
-rw-r--r-- | style/qtcurve.h | 45 |
1 files changed, 24 insertions, 21 deletions
diff --git a/style/qtcurve.h b/style/qtcurve.h index 5bd78ca..453076a 100644 --- a/style/qtcurve.h +++ b/style/qtcurve.h @@ -78,10 +78,11 @@ class TQSlider; #define BASE_STYLE TDEStyle #endif +class ShortcutHandler; + class QtCurveStyle : public BASE_STYLE { Q_OBJECT - public: @@ -139,19 +140,20 @@ class QtCurveStyle : public BASE_STYLE virtual ~QtCurveStyle(); void applicationPolish(const TQStyleControlElementData &ceData, ControlElementFlags elementFlags, void *); + void applicationUnPolish(const TQStyleControlElementData &ceData, ControlElementFlags elementFlags, void *); void polish(TQPalette &pal); TQColorGroup setColorGroup(const TQColorGroup &old, const TQColorGroup &act, bool dis=false); void polish(const TQStyleControlElementData &ceData, ControlElementFlags elementFlags, void *); void unPolish(const TQStyleControlElementData &ceData, ControlElementFlags elementFlags, void *); void drawLightBevel(TQPainter *p, const TQRect &r, const TQColorGroup &cg, SFlags flags, int round, const TQColor &fill, const TQColor *custom=NULL, - bool doBorder=true, bool doCorners=true, EWidget w=WIDGET_OTHER) const - { drawLightBevel(cg.background(), p, r, cg, flags, round, fill, custom, doBorder, doCorners, w); } + bool doBorder=true, bool doCorners=true, EWidget w=WIDGET_OTHER, const TQWidget *widget=0L) const + { drawLightBevel(cg.background(), p, r, cg, flags, round, fill, custom, doBorder, doCorners, w, widget); } void drawLightBevel(const TQColor &bgnd, TQPainter *p, const TQRect &r, const TQColorGroup &cg, SFlags flags, int round, const TQColor &fill, const TQColor *custom=NULL, - bool doBorder=true, bool doCorners=true, EWidget w=WIDGET_OTHER) const; + bool doBorder=true, bool doCorners=true, EWidget w=WIDGET_OTHER, const QWidget *widget=0L) const; void drawGlow(TQPainter *p, const TQRect &r, const TQColorGroup &cg, EWidget w, const TQColor *cols=0) const; - void drawEtch(TQPainter *p, const TQRect &r, const TQColorGroup &cg, bool raised=false, bool square=false) const; + void drawEtch(TQPainter *p, const TQRect &r, const TQColorGroup &cg, bool raised=false, bool square=false, EWidget w=WIDGET_OTHER) const; void drawBorder(const TQColor &bgnd, TQPainter *p, const TQRect &r, const TQColorGroup &cg, SFlags flags, int round, const TQColor *custom=NULL, EWidget w=WIDGET_OTHER, bool doCorners=true, EBorder borderProfile=BORDER_FLAT, bool blendBorderColors=true, int borderVal=STD_BORDER) const; @@ -195,9 +197,9 @@ class QtCurveStyle : public BASE_STYLE bool mbi, int round, const TQColor &bgnd, const TQColor *cols) const; void drawProgress(TQPainter *p, const TQRect &r, const TQColorGroup &cg, SFlags flags, int round, const TQWidget *widget) const; - void drawBevelGradient(const TQColor &base, TQPainter *p, TQRect const &r, + void drawBevelGradient(const TQColor &base, const TQColor &bgnd, TQPainter *p, TQRect const &r, bool horiz, bool sel, EAppearance bevApp, EWidget w=WIDGET_OTHER) const; - void drawBevelGradientReal(const TQColor &base, TQPainter *p, TQRect const &r, + void drawBevelGradientReal(const TQColor &base, const TQColor &bgnd, TQPainter *p, TQRect const &r, bool horiz, bool sel, EAppearance bevApp, EWidget w=WIDGET_OTHER) const; void drawGradient(const TQColor &top, const TQColor &bot, TQPainter *p, const TQRect &r, bool horiz=true) const; void drawSbSliderHandle(TQPainter *p, const TQRect &r, const TQColorGroup &cg, SFlags flags, bool slider=false) const; @@ -215,7 +217,7 @@ class QtCurveStyle : public BASE_STYLE return tqGray(col.rgb()) < 100 ? TQColor(255, 255, 255) : TQColor(0, 0, 0); } - void shadeColors(const TQColor &base, TQColor *vals) const; + void shadeColors(const TQColor &base, TQColor *vals) const; const TQColor * buttonColors(const TQColorGroup &cg) const; const TQColor * popupMenuCols(const TQColorGroup &cg) const; const TQColor & popupMenuCol(const TQColorGroup &cg, int shade=ORIGINAL_SHADE) const; @@ -226,31 +228,31 @@ class QtCurveStyle : public BASE_STYLE { return backgroundColors(cg.background()); } const TQColor * borderColors(SFlags flags, const TQColor *use) const; const TQColor * getSidebarButtons() const; - void setMenuColors(const TQColorGroup &cg); - void setMenuTextColors(TQWidget *widget, bool isMenuBar) const; + void setMenuColors(const TQColorGroup &cg); + void setMenuTextColors(TQWidget *widget, bool isMenuBar) const; const TQColor * menuColors(const TQColorGroup &cg, bool active) const; - void setDecorationColors(bool init=false); + void setDecorationColors(bool init=false); const TQColor * getMdiColors(const TQColorGroup &cg, bool active) const; #ifdef SET_MDI_WINDOW_BUTTON_POSITIONS void readMdiPositions() const; #endif - bool redrawHoverWidget(const TQPoint &pos); + bool redrawHoverWidget(const TQPoint &pos); const TQColor & getFill(SFlags flags, const TQColor *use, bool cr=false, bool darker=false) const; const TQColor & getListViewFill(SFlags flags, const TQColor *use) const; const TQColor & getTabFill(bool current, bool highlight, const TQColor *use) const; const TQColor & menuStripeCol(const TQColorGroup &cg) const; const TQColor & checkRadioCol(SFlags flags, const TQColorGroup &cg) const; TQColor shade(const TQColor &a, float k) const; - void shade(const color &ca, color *cb, double k) const; - void drawDot(TQPainter *p, const TQRect &r, const TQColor *cols) const; + void shade(const color &ca, color *cb, double k) const; + void drawDot(TQPainter *p, const TQRect &r, const TQColor *cols) const; TQPixmap * getPixelPixmap(const TQColor col) const; TQPixmap * getPixmap(const TQColor col, EPixmap pix, double shade=1.0) const; TQPixmap * createStripePixmap(const TQColor &col, bool forWindow) const; - void setSbType(); - bool isFormWidget(const TQWidget *w) const { return itsKhtmlWidgets.contains(w); } - void resetHover(); - bool isWindowDragWidget(TQObject *o, const TQPoint &pos=TQPoint()); - void adjustScrollbarRects(bool &itsFormMode, bool &horiz, bool &useThreeButtonScrollBar, TQRect &subline, TQRect &addline, TQRect &subpage, TQRect &addpage, TQRect &slider, TQRect &first, TQRect &last, TQRect &subline2, TQRect &sbRect, Options& opts, const TQWidget* widget) const; + void setSbType(); + bool isFormWidget(const TQWidget *w) const { return itsKhtmlWidgets.contains(w); } + void resetHover(); + bool isWindowDragWidget(TQObject *o, const TQPoint &pos=TQPoint()); + void adjustScrollbarRects(bool &itsFormMode, bool &horiz, bool &useThreeButtonScrollBar, TQRect &subline, TQRect &addline, TQRect &subpage, TQRect &addpage, TQRect &slider, TQRect &first, TQRect &last, TQRect &subline2, TQRect &sbRect, Options& opts, const TQWidget* widget) const; private slots: @@ -263,10 +265,11 @@ class QtCurveStyle : public BASE_STYLE private: mutable Options opts; - TQColor itsHighlightCols[TOTAL_SHADES+1], + TQColor itsHighlightCols[TOTAL_SHADES+1], itsBackgroundCols[TOTAL_SHADES+1], itsMenubarCols[TOTAL_SHADES+1], itsFocusCols[TOTAL_SHADES+1], + *itsPopupMenuCols, *itsSliderCols, *itsDefBtnCols, *itsMouseOverCols, @@ -275,7 +278,6 @@ class QtCurveStyle : public BASE_STYLE *itsSortedLvColors, *itsProgressCols, itsButtonCols[TOTAL_SHADES+1], - itsLighterPopupMenuBgndCol, itsCheckRadioCol; mutable TQColor *itsSidebarButtonsCols; mutable TQColor *itsActiveMdiColors; @@ -304,6 +306,7 @@ class QtCurveStyle : public BASE_STYLE mutable TQValueList<int> itsMdiButtons[2]; // 0=left, 1=right TQWidget *itsDragWidget; bool itsDragWidgetHadMouseTracking; + ShortcutHandler *itsShortcutHandler; }; #endif |