diff options
Diffstat (limited to 'kwin/clients/modernsystem')
-rw-r--r-- | kwin/clients/modernsystem/buttondata.h | 6 | ||||
-rw-r--r-- | kwin/clients/modernsystem/config/config.cpp | 18 | ||||
-rw-r--r-- | kwin/clients/modernsystem/modernsys.cpp | 64 | ||||
-rw-r--r-- | kwin/clients/modernsystem/modernsys.h | 2 |
4 files changed, 45 insertions, 45 deletions
diff --git a/kwin/clients/modernsystem/buttondata.h b/kwin/clients/modernsystem/buttondata.h index 1af5fb8dd..fc01c3840 100644 --- a/kwin/clients/modernsystem/buttondata.h +++ b/kwin/clients/modernsystem/buttondata.h @@ -1,8 +1,8 @@ /* Image bits processed by KPixmap2Bitmaps */ -#define lowcolor_mask_width 14 -#define lowcolor_mask_height 15 -static const unsigned char lowcolor_mask_bits[] = { +#define lowcolor_tqmask_width 14 +#define lowcolor_tqmask_height 15 +static const unsigned char lowcolor_tqmask_bits[] = { 0xf0,0x03,0xf8,0x07,0xfc,0xcf,0xfe,0x1f,0xfe,0x1f,0xff,0xff,0xff,0xff,0xff, 0x3f,0xff,0x3f,0xff,0xbf,0xfe,0xdf,0xfe,0x9f,0xfc,0x0f,0xf8,0x07,0xf0,0x03, 0x00,0x40,0x80,0x00,0x00,0x00,0x29,0x00,0x00,0x00,0x7c,0xfe,0x87,0x40,0x00, diff --git a/kwin/clients/modernsystem/config/config.cpp b/kwin/clients/modernsystem/config/config.cpp index 8a94c1748..60ef9a3c7 100644 --- a/kwin/clients/modernsystem/config/config.cpp +++ b/kwin/clients/modernsystem/config/config.cpp @@ -35,15 +35,15 @@ ModernSysConfig::ModernSysConfig(KConfig* conf, TQWidget* parent) : TQObject(par vbox->setMargin(0); handleBox = new TQWidget(mainw); - TQGridLayout* layout = new TQGridLayout(handleBox, 0, KDialog::spacingHint()); + TQGridLayout* tqlayout = new TQGridLayout(handleBox, 0, KDialog::spacingHint()); cbShowHandle = new TQCheckBox(i18n("&Show window resize handle"), handleBox); TQWhatsThis::add(cbShowHandle, i18n("When selected, all windows are drawn with a resize " "handle at the lower right corner. This makes window resizing " - "easier, especially for trackballs and other mouse replacements " + "easier, especially for trackballs and other mouse tqreplacements " "on laptops.")); - layout->addMultiCellWidget(cbShowHandle, 0, 0, 0, 1); + tqlayout->addMultiCellWidget(cbShowHandle, 0, 0, 0, 1); connect(cbShowHandle, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSelectionChanged())); sliderBox = new TQVBox(handleBox); @@ -59,18 +59,18 @@ ModernSysConfig::ModernSysConfig(KConfig* conf, TQWidget* parent) : TQObject(par bool rtl = kapp->reverseLayout(); label1 = new TQLabel(i18n("Small"), hbox); - label1->setAlignment(rtl ? AlignRight : AlignLeft); + label1->tqsetAlignment(rtl ? AlignRight : AlignLeft); label2 = new TQLabel(i18n("Medium"), hbox); - label2->setAlignment(AlignHCenter); + label2->tqsetAlignment(AlignHCenter); label3 = new TQLabel(i18n("Large"), hbox); - label3->setAlignment(rtl ? AlignLeft : AlignRight); + label3->tqsetAlignment(rtl ? AlignLeft : AlignRight); vbox->addWidget(handleBox); vbox->addStretch(1); -// layout->setColSpacing(0, 30); - layout->addItem(new TQSpacerItem(30, 10, TQSizePolicy::Fixed, TQSizePolicy::Fixed), 1, 0); - layout->addWidget(sliderBox, 1, 1); +// tqlayout->setColSpacing(0, 30); + tqlayout->addItem(new TQSpacerItem(30, 10, TQSizePolicy::Fixed, TQSizePolicy::Fixed), 1, 0); + tqlayout->addWidget(sliderBox, 1, 1); load(conf); mainw->show(); diff --git a/kwin/clients/modernsystem/modernsys.cpp b/kwin/clients/modernsystem/modernsys.cpp index ce7545cdf..1bb9f9815 100644 --- a/kwin/clients/modernsystem/modernsys.cpp +++ b/kwin/clients/modernsystem/modernsys.cpp @@ -65,7 +65,7 @@ static unsigned char shade_on_bits[] = { static unsigned char menu_bits[] = { 0xff, 0x81, 0x81, 0xff, 0x81, 0xff, 0x81, 0xff}; -static unsigned char btnhighcolor_mask_bits[] = { +static unsigned char btnhighcolor_tqmask_bits[] = { 0xe0,0x41,0xf8,0x07,0xfc,0x0f,0xfe,0xdf,0xfe,0x1f,0xff,0x3f,0xff,0xff,0xff, 0x3f,0xff,0x3f,0xff,0xff,0xff,0xff,0xfe,0x9f,0xfe,0x1f,0xfc,0x0f,0xf0,0x03, 0x00,0x40,0x80,0x00,0x00,0x00,0x39,0x00,0x00,0x00,0x20,0x99,0x0f,0x08,0xc4, @@ -127,7 +127,7 @@ static void make_button_fx(const TQColorGroup &g, TQPixmap *pix, bool light=fals } else{ - if(!lcDark1->mask()){ + if(!lcDark1->tqmask()){ lcDark1->setMask(*lcDark1); lcDark2->setMask(*lcDark2); lcDark3->setMask(*lcDark3); @@ -171,20 +171,20 @@ static void create_pixmaps() KPixmapEffect::VerticalGradient); } // buttons - TQColorGroup btnColor(options()->colorGroup(KDecoration::ColorButtonBg, true)); + TQColorGroup btnColor(options()->tqcolorGroup(KDecoration::ColorButtonBg, true)); buttonPix = new TQPixmap(14, 15); make_button_fx(btnColor, buttonPix); buttonPixDown = new TQPixmap(14, 15); make_button_fx(btnColor, buttonPixDown, true); - btnColor = options()->colorGroup(KDecoration::ColorButtonBg, false); + btnColor = options()->tqcolorGroup(KDecoration::ColorButtonBg, false); iButtonPix = new TQPixmap(14, 15); make_button_fx(btnColor, iButtonPix); iButtonPixDown = new TQPixmap(14, 15); make_button_fx(btnColor, iButtonPixDown, true); - if(qGray(btnColor.background().rgb()) < 150) + if(tqGray(btnColor.background().rgb()) < 150) buttonFg = new TQColor(Qt::white); else buttonFg = new TQColor(Qt::black); @@ -289,11 +289,11 @@ ModernButton::ModernButton(ButtonType type, ModernSys *parent, const char *name) { setBackgroundMode( NoBackground ); - TQBitmap mask(14, 15, TQPixmap::defaultDepth() > 8 ? - btnhighcolor_mask_bits : lowcolor_mask_bits, true); + TQBitmap tqmask(14, 15, TQPixmap::defaultDepth() > 8 ? + btnhighcolor_tqmask_bits : lowcolor_tqmask_bits, true); resize(14, 15); - setMask(mask); + setMask(tqmask); } void ModernButton::reset(unsigned long changed) @@ -410,7 +410,7 @@ bool ModernSys::decorationBehaviour(DecorationBehaviour behaviour) const } } -int ModernSys::layoutMetric(LayoutMetric lm, bool respectWindowState, const KCommonDecorationButton *btn) const +int ModernSys::tqlayoutMetric(LayoutMetric lm, bool respectWindowState, const KCommonDecorationButton *btn) const { // bool maximized = maximizeMode()==MaximizeFull && !options()->moveResizeMaximizedWindows(); @@ -425,9 +425,9 @@ int ModernSys::layoutMetric(LayoutMetric lm, bool respectWindowState, const KCom return border_width + handle_width; case LM_TitleEdgeLeft: - return layoutMetric(LM_BorderLeft,respectWindowState)+3; + return tqlayoutMetric(LM_BorderLeft,respectWindowState)+3; case LM_TitleEdgeRight: - return layoutMetric(LM_BorderRight,respectWindowState)+3; + return tqlayoutMetric(LM_BorderRight,respectWindowState)+3; case LM_TitleEdgeTop: return 2; @@ -454,7 +454,7 @@ int ModernSys::layoutMetric(LayoutMetric lm, bool respectWindowState, const KCom return 3; default: - return KCommonDecoration::layoutMetric(lm, respectWindowState, btn); + return KCommonDecoration::tqlayoutMetric(lm, respectWindowState, btn); } } @@ -515,10 +515,10 @@ void ModernSys::recalcTitleBuffer() p.drawTiledPixmap(0, 0, width(), title_height+2, *aUpperGradient); else p.fillRect(0, 0, width(), title_height+2, - options()->colorGroup(ColorTitleBar, true). + options()->tqcolorGroup(ColorTitleBar, true). brush(TQColorGroup::Button)); - TQRect t = titleRect(); // titlebar->geometry(); + TQRect t = titleRect(); // titlebar->tqgeometry(); t.setTop( 2 ); t.setLeft( t.left() ); t.setRight( t.right() - 2 ); @@ -554,7 +554,7 @@ void ModernSys::updateCaption() void ModernSys::drawRoundFrame(TQPainter &p, int x, int y, int w, int h) { kDrawRoundButton(&p, x, y, w, h, - options()->colorGroup(ColorFrame, isActive()), false); + options()->tqcolorGroup(ColorFrame, isActive()), false); } @@ -568,11 +568,11 @@ void ModernSys::paintEvent( TQPaintEvent* ) int hw = handle_width; TQPainter p( widget() ); - TQRect t = titleRect(); // titlebar->geometry(); + TQRect t = titleRect(); // titlebar->tqgeometry(); - TQBrush fillBrush(widget()->colorGroup().brush(TQColorGroup::Background).pixmap() ? - widget()->colorGroup().brush(TQColorGroup::Background) : - options()->colorGroup(ColorFrame, isActive()). + TQBrush fillBrush(widget()->tqcolorGroup().brush(TQColorGroup::Background).pixmap() ? + widget()->tqcolorGroup().brush(TQColorGroup::Background) : + options()->tqcolorGroup(ColorFrame, isActive()). brush(TQColorGroup::Button)); p.fillRect(1, title_height+3, width()-2, height()-(title_height+3), fillBrush); @@ -586,7 +586,7 @@ void ModernSys::paintEvent( TQPaintEvent* ) int h = height() - hw; // titlebar - TQColorGroup g = options()->colorGroup(ColorTitleBar, isActive()); + TQColorGroup g = options()->tqcolorGroup(ColorTitleBar, isActive()); if(isActive()){ p.drawPixmap(1, 1, titleBuffer, 0, 0, w-2, title_height+2); } @@ -609,7 +609,7 @@ void ModernSys::paintEvent( TQPaintEvent* ) p.drawLine(0, title_height+2, w-2, title_height+2); // frame - g = options()->colorGroup(ColorFrame, isActive()); + g = options()->tqcolorGroup(ColorFrame, isActive()); p.setPen(g.light()); p.drawLine(1, title_height+3, 1, h-2); p.setPen(g.dark()); @@ -649,22 +649,22 @@ void ModernSys::updateWindowShape() { int hs = handle_size; int hw = handle_width; - TQRegion mask; - mask += TQRect(0, 0, width()-hw, height()-hw); + TQRegion tqmask; + tqmask += TQRect(0, 0, width()-hw, height()-hw); //single points - mask -= TQRect(0, 0, 1, 1); - mask -= TQRect(width()-hw-1, 0, 1, 1); - mask -= TQRect(0, height()-hw-1, 1, 1); + tqmask -= TQRect(0, 0, 1, 1); + tqmask -= TQRect(width()-hw-1, 0, 1, 1); + tqmask -= TQRect(0, height()-hw-1, 1, 1); if (show_handle) { - mask += TQRect(width()-hs, height()-hs, hs-1, hs-1); - mask -= TQRect(width()-2, height()-2, 1, 1); - mask -= TQRect(width()-2, height()-hs, 1, 1); - mask -= TQRect(width()-hs, height()-2, 1, 1); + tqmask += TQRect(width()-hs, height()-hs, hs-1, hs-1); + tqmask -= TQRect(width()-2, height()-2, 1, 1); + tqmask -= TQRect(width()-2, height()-hs, 1, 1); + tqmask -= TQRect(width()-hs, height()-2, 1, 1); } else - mask -= TQRect(width()-1, height()-1, 1, 1); + tqmask -= TQRect(width()-1, height()-1, 1, 1); - setMask(mask); + setMask(tqmask); } ModernSysFactory::ModernSysFactory() diff --git a/kwin/clients/modernsystem/modernsys.h b/kwin/clients/modernsystem/modernsys.h index 3e0cf02fd..927e1e32e 100644 --- a/kwin/clients/modernsystem/modernsys.h +++ b/kwin/clients/modernsystem/modernsys.h @@ -36,7 +36,7 @@ public: virtual TQString defaultButtonsLeft() const; virtual TQString defaultButtonsRight() const; virtual bool decorationBehaviour(DecorationBehaviour behaviour) const; - virtual int layoutMetric(LayoutMetric lm, bool respectWindowState = true, const KCommonDecorationButton * = 0) const; + virtual int tqlayoutMetric(LayoutMetric lm, bool respectWindowState = true, const KCommonDecorationButton * = 0) const; virtual KCommonDecorationButton *createButton(ButtonType type); virtual void updateWindowShape(); |