亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? qplatinumstyle.cpp

?? qtopia-phone-2.2.0下公共的控件實現(xiàn)源代碼。
?? CPP
?? 第 1 頁 / 共 3 頁
字號:
/****************************************************************************** $Id: qt/src/widgets/qplatinumstyle.cpp   2.3.12   edited 2005-10-27 $**** Implementation of Platinum-like style class**** Created : 981231**** Copyright (C) 1998-2000 Trolltech AS.  All rights reserved.**** This file is part of the widgets module of the Qt GUI Toolkit.**** This file may be distributed under the terms of the Q Public License** as defined by Trolltech AS of Norway and appearing in the file** LICENSE.QPL included in the packaging of this file.**** This file may be distributed and/or modified under the terms of the** GNU General Public License version 2 as published by the Free Software** Foundation and appearing in the file LICENSE.GPL included in the** packaging of this file.**** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition** licenses may use this file in accordance with the Qt Commercial License** Agreement provided with the Software.**** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.**** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for**   information about Qt Commercial License Agreements.** See http://www.trolltech.com/qpl/ for QPL licensing information.** See http://www.trolltech.com/gpl/ for GPL licensing information.**** Contact info@trolltech.com if any conditions of this licensing are** not clear to you.************************************************************************/#include "qplatinumstyle.h"#ifndef QT_NO_STYLE_PLATINUM#include "qapplication.h"#include "qpainter.h"#include "qdrawutil.h" // for now#include "qpixmap.h" // for now#include "qpalette.h" // for now#include "qwidget.h"#include "qlabel.h"#include "qimage.h"#include "qpushbutton.h"#include "qwidget.h"#include "qrangecontrol.h"#include "qscrollbar.h"#include <limits.h>// NOT REVISED/*!  \class QPlatinumStyle qplatinumstyle.h  \brief Platinum Look and Feel  \ingroup appearance  This class implements the Platinum look and feel. It's an  experimental class that tries to resemble a Macintosh-like GUI style  with the QStyle system. The emulation is, however, far from being  perfect yet.*//*!    Constructs a QPlatinumStyle*/QPlatinumStyle::QPlatinumStyle(){    setButtonDefaultIndicatorWidth( 3 );}/*!  Destructs the style.*/QPlatinumStyle::~QPlatinumStyle(){}/*! \reimp */void QPlatinumStyle::drawPopupPanel( QPainter *p, int x, int y, int w, int h,			       const QColorGroup &g,  int lineWidth,			       const QBrush *fill ){    QWindowsStyle::drawPopupPanel( p, x, y, w, h, g, lineWidth, fill );}/*!  Draws a press-sensitive shape.*/void QPlatinumStyle::drawButton( QPainter *p, int x, int y, int w, int h,				const QColorGroup &g, bool sunken, const QBrush* fill){    QPen oldPen = p->pen();     if (!sunken) {	 p->fillRect(x+3, y+3, w-6, h-6,fill ? *fill :					 g.brush( QColorGroup::Button ));	 // the bright side	 p->setPen(g.shadow());	 p->drawLine(x, y, x+w-1, y);	 p->drawLine(x, y, x, y+h-1);	 p->setPen(g.button());	 p->drawLine(x+1, y+1, x+w-2, y+1);	 p->drawLine(x+1, y+1, x+1, y+h-2);	 p->setPen(g.light());	 p->drawLine(x+2, y+2, x+2, y+h-2);	 p->drawLine(x+2, y+2, x+w-2, y+2);	 // the dark side!	 p->setPen(g.mid());	 p->drawLine(x+3, y+h-3 ,x+w-3, y+h-3);	 p->drawLine(x+w-3, y+3, x+w-3, y+h-3);	 p->setPen(g.dark());	 p->drawLine(x+2, y+h-2 ,x+w-2, y+h-2);	 p->drawLine(x+w-2, y+2, x+w-2, y+h-2);	 p->setPen(g.shadow());	 p->drawLine(x+1, y+h-1,x+w-1, y+h-1);	 p->drawLine(x+w-1, y, x+w-1, y+h-1);	 // top left corner:	 p->setPen(g.background());	 p->drawPoint(x, y);	 p->drawPoint(x+1, y);	 p->drawPoint(x, y+1);	 p->setPen(g.shadow());	 p->drawPoint(x+1, y+1);	 p->setPen(g.button()); 	 p->drawPoint(x+2, y+2);	 p->setPen(white); 	 p->drawPoint(x+3, y+3);	 // bottom left corner:	 p->setPen(g.background());	 p->drawPoint(x, y+h-1);	 p->drawPoint(x+1, y+h-1);	 p->drawPoint(x, y+h-2);	 p->setPen(g.shadow());	 p->drawPoint(x+1, y+h-2);	 p->setPen(g.dark());	 p->drawPoint(x+2, y+h-3);	 // top right corner:	 p->setPen(g.background());	 p->drawPoint(x+w-1, y);	 p->drawPoint(x+w-2, y);	 p->drawPoint(x+w-1, y+1);	 p->setPen(g.shadow());	 p->drawPoint(x+w-2, y+1);	 p->setPen(g.dark());	 p->drawPoint(x+w-3, y+2);	 // bottom right corner:	 p->setPen(g.background());	 p->drawPoint(x+w-1, y+h-1);	 p->drawPoint(x+w-2, y+h-1);	 p->drawPoint(x+w-1, y+h-2);	 p->setPen(g.shadow());	 p->drawPoint(x+w-2, y+h-2);	 p->setPen(g.dark());	 p->drawPoint(x+w-3, y+h-3);	 p->setPen(g.mid());	 p->drawPoint(x+w-4, y+h-4);     }     else {	 p->fillRect(x+2, y+2, w-4, h-4,fill ? *fill :					   g.brush( QColorGroup::Dark ));	 // the dark side	 p->setPen(g.shadow());	 p->drawLine(x, y, x+w-1, y);	 p->drawLine(x, y, x, y+h-1);	 p->setPen(g.dark().dark());	 p->drawLine(x+1, y+1, x+w-2, y+1);	 p->drawLine(x+1, y+1, x+1, y+h-2);	 // the bright side!	 p->setPen(g.button());	 p->drawLine(x+1, y+h-2 ,x+w-2, y+h-2);	 p->drawLine(x+w-2, y+1, x+w-2, y+h-2);	 p->setPen(g.dark());	 p->drawLine(x, y+h-1,x+w-1, y+h-1);	 p->drawLine(x+w-1, y, x+w-1, y+h-1);	 // top left corner:	 p->setPen(g.background());	 p->drawPoint(x, y);	 p->drawPoint(x+1, y);	 p->drawPoint(x, y+1);	 p->setPen(g.shadow());	 p->drawPoint(x+1, y+1);	 p->setPen(g.dark().dark());	 p->drawPoint(x+3, y+3);	 // bottom left corner:	 p->setPen(g.background());	 p->drawPoint(x, y+h-1);	 p->drawPoint(x+1, y+h-1);	 p->drawPoint(x, y+h-2);	 p->setPen(g.shadow());	 p->drawPoint(x+1, y+h-2);	 // top right corner:	 p->setPen(g.background());	 p->drawPoint(x+w-1, y);	 p->drawPoint(x+w-2, y);	 p->drawPoint(x+w-1, y+1);	 p->setPen(g.shadow());	 p->drawPoint(x+w-2, y+1);	 // bottom right corner:	 p->setPen(g.background());	 p->drawPoint(x+w-1, y+h-1);	 p->drawPoint(x+w-2, y+h-1);	 p->drawPoint(x+w-1, y+h-2);	 p->setPen(g.shadow());	 p->drawPoint(x+w-2, y+h-2);	 p->setPen(g.dark());	 p->drawPoint(x+w-3, y+h-3);	 p->setPen(g.mid());	 p->drawPoint(x+w-4, y+h-4);     }     //     // top left corner://     p->setPen(g.background());//     p->drawPoint(x, y);//     p->drawPoint(x, y);    p->setPen(oldPen);}/*! \reimp */QRect QPlatinumStyle::buttonRect( int x, int y, int w, int h){    QRect r = QCommonStyle::buttonRect(x,y,w,h);    r.setTop( r.top()+1);    r.setLeft( r.left()+1);    r.setBottom( r.bottom()-1);    r.setRight( r.right()-1);    return r;}/*!  mixes two colors to a new colors  */QColor QPlatinumStyle::mixedColor(const QColor &c1, const QColor &c2){    int h1,s1,v1,h2,s2,v2;    c1.hsv(&h1,&s1,&v1);    c2.hsv(&h2,&s2,&v2);    return QColor( (h1+h2)/2, (s1+s2)/2, (v1+v2)/2, QColor::Hsv );}/*! \reimp */void QPlatinumStyle::drawBevelButton( QPainter *p, int x, int y, int w, int h,				const QColorGroup &g, bool sunken, const QBrush* fill){    QPen oldPen = p->pen();    // small or non-square bevel buttons are drawn in a small style, others in a big style.    if ( w * h < 1600 || QABS(w-h) > 10) {	// small buttons	if (!sunken) {	    p->fillRect(x+2, y+2, w-4, h-4,fill ? *fill :					     g.brush( QColorGroup::Button ));	    // the bright side	    p->setPen(g.dark());	    p->drawLine(x, y, x+w-1, y);	    p->drawLine(x, y, x, y+h-1);	    p->setPen(g.light());	    p->drawLine(x+1, y+1, x+w-2, y+1);	    p->drawLine(x+1, y+1, x+1, y+h-2);	    // the dark side!	    p->setPen(g.mid());	    p->drawLine(x+2, y+h-2 ,x+w-2, y+h-2);	    p->drawLine(x+w-2, y+2, x+w-2, y+h-3);	    p->setPen(g.dark().dark());	    p->drawLine(x+1, y+h-1,x+w-1, y+h-1);	    p->drawLine(x+w-1, y+1, x+w-1, y+h-2);	}	else {	    p->fillRect(x+2, y+2, w-4, h-4,fill ? *fill :					       g.brush( QColorGroup::Mid ));	    // the dark side	    p->setPen(g.dark().dark());	    p->drawLine(x, y, x+w-1, y);	    p->drawLine(x, y, x, y+h-1);	    p->setPen(g.mid().dark());	    p->drawLine(x+1, y+1, x+w-2, y+1);	    p->drawLine(x+1, y+1, x+1, y+h-2);	    // the bright side!	    p->setPen(g.button());	    p->drawLine(x+1, y+h-2 ,x+w-2, y+h-2);	    p->drawLine(x+w-2, y+1, x+w-2, y+h-2);	    p->setPen(g.dark());	    p->drawLine(x, y+h-1,x+w-1, y+h-1);	    p->drawLine(x+w-1, y, x+w-1, y+h-1);	}    }    else {	// big ones	if (!sunken) {	    p->fillRect(x+3, y+3, w-6, h-6,fill ? * fill :					    g.brush( QColorGroup::Button ));	    // the bright side	    p->setPen(g.button().dark());	    p->drawLine(x, y, x+w-1, y);	    p->drawLine(x, y, x, y+h-1);	    p->setPen(g.button());	    p->drawLine(x+1, y+1, x+w-2, y+1);	    p->drawLine(x+1, y+1, x+1, y+h-2);	    p->setPen(g.light());	    p->drawLine(x+2, y+2, x+2, y+h-2);	    p->drawLine(x+2, y+2, x+w-2, y+2);	 // the dark side!	    p->setPen(g.mid());	    p->drawLine(x+3, y+h-3 ,x+w-3, y+h-3);	    p->drawLine(x+w-3, y+3, x+w-3, y+h-3);	    p->setPen(g.dark());	    p->drawLine(x+2, y+h-2 ,x+w-2, y+h-2);	    p->drawLine(x+w-2, y+2, x+w-2, y+h-2);	    p->setPen(g.dark().dark());	    p->drawLine(x+1, y+h-1,x+w-1, y+h-1);	    p->drawLine(x+w-1, y+1, x+w-1, y+h-1);	}	else {	    p->fillRect(x+3, y+3, w-6, h-6,fill ? *fill :						  g.brush( QColorGroup::Mid ));	    // the dark side	    p->setPen(g.dark().dark().dark());	    p->drawLine(x, y, x+w-1, y);	    p->drawLine(x, y, x, y+h-1);	    p->setPen(g.dark().dark());	    p->drawLine(x+1, y+1, x+w-2, y+1);	    p->drawLine(x+1, y+1, x+1, y+h-2);	    p->setPen(g.mid().dark());	    p->drawLine(x+2, y+2, x+2, y+w-2);	    p->drawLine(x+2, y+2, x+w-2, y+2);	    // the bright side!	    p->setPen(g.button());	    p->drawLine(x+2, y+h-3 ,x+w-3, y+h-3);	    p->drawLine(x+w-3, y+3, x+w-3, y+h-3);	    p->setPen(g.midlight());	    p->drawLine(x+1, y+h-2 ,x+w-2, y+h-2);	    p->drawLine(x+w-2, y+1, x+w-2, y+h-2);	    p->setPen(g.dark());	    p->drawLine(x, y+h-1,x+w-1, y+h-1);	    p->drawLine(x+w-1, y, x+w-1, y+h-1);	    // corners	    p->setPen( mixedColor(g.dark().dark().dark(), g.dark()) );	    p->drawPoint( x, y+h-1 );	    p->drawPoint( x+w-1, y);	    p->setPen( mixedColor(g.dark().dark(), g.midlight() ) );	    p->drawPoint( x+1, y+h-2 );	    p->drawPoint( x+w-2, y+1);	    p->setPen( mixedColor(g.mid().dark(), g.button() ) );	    p->drawPoint( x+2, y+h-3 );	    p->drawPoint( x+w-3, y+2);	}    }    p->setPen(oldPen);}/*! \reimp */voidQPlatinumStyle::drawPushButton( QPushButton* btn, QPainter *p){    QColorGroup g = btn->colorGroup();    int x1, y1, x2, y2;    bool useBevelButton;    btn->rect().coords( &x1, &y1, &x2, &y2 );	// get coordinates    p->setPen( g.foreground() );    p->setBrush( QBrush(g.button(),NoBrush) );    QBrush fill;    if ( btn->isDown() )	fill = g.brush( QColorGroup::Dark );    else if ( btn->isOn() )	fill = QBrush( g.mid(), Dense4Pattern );    else	fill = g.brush( QColorGroup::Button );    // small or square image buttons as well as toggle buttons are    // bevel buttons (what a heuristic....)    if ( btn->isToggleButton()	 || ( btn->pixmap() &&	      (btn->width() * btn->height() < 1600 || QABS( btn->width() - btn->height()) < 10 )) )	useBevelButton = TRUE;    else	useBevelButton = FALSE;    int diw = buttonDefaultIndicatorWidth();    if (btn->isDefault() ) {	x1 += 1;	y1 += 1;	x2 -= 1;	y2 -= 1;	QColorGroup g2( g );	g2.setColor( QColorGroup::Button,  g.mid() );	if( useBevelButton )	    drawBevelButton( p, x1, y1, x2-x1+1, y2-y1+1, g, FALSE, &fill );	else	    drawButton( p, x1, y1, x2-x1+1, y2-y1+1, g2, FALSE, &fill );    }    if ( btn->isDefault() || btn->autoDefault() ) {	x1 += diw;	y1 += diw;	x2 -= diw;	y2 -= diw;    }    if ( !btn->isFlat() || btn->isOn() || btn->isDown() ) {	if( useBevelButton)	    drawBevelButton( p, x1, y1, x2-x1+1, y2-y1+1, g, btn->isOn() || btn->isDown(),			     &fill );	else	    drawButton( p, x1, y1, x2-x1+1, y2-y1+1, g, btn->isOn() || btn->isDown(),			&fill );    }    if ( p->brush().style() != NoBrush )	p->setBrush( NoBrush );}/*! \reimp */void QPlatinumStyle::drawPushButtonLabel( QPushButton* btn, QPainter *p){    bool on = btn->isDown() || btn->isOn();    QRect r = pushButtonContentsRect( btn );    int x, y, w, h;    r.rect( &x, &y, &w, &h );    if ( btn->isMenuButton() ) {	int dx = menuButtonIndicatorWidth( btn->height() );	QColorGroup g( btn->colorGroup() );	int xx = x+w-dx-4;	int yy = y-3;	int hh = h+6;	if ( !on ) {	    p->setPen( g.mid() );	    p->drawLine(xx, yy+2, xx, yy+hh-3);	    p->setPen( g.button() );	    p->drawLine(xx+1, yy+1, xx+1, yy+hh-2);	    p->setPen( g.light() );	    p->drawLine(xx+2, yy+2, xx+2, yy+hh-2);	}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日本一区二区三区免费乱视频| 中文字幕乱码亚洲精品一区| 国产精品一区二区久久精品爱涩 | 一区二区三区日韩精品| 欧美精品丝袜中出| 久久精品国产一区二区| 中文字幕一区二区三区不卡| 91精品在线观看入口| 国产suv精品一区二区6| 综合久久综合久久| 日韩午夜激情视频| 91免费观看在线| 国内精品久久久久影院色| 亚洲视频免费在线观看| 欧美大黄免费观看| 欧洲亚洲精品在线| 粉嫩一区二区三区在线看| 丝袜诱惑亚洲看片| 久久伊99综合婷婷久久伊| 欧洲亚洲国产日韩| 成人国产精品免费观看动漫| 亚洲男人的天堂在线观看| 日韩写真欧美这视频| 91福利视频网站| 国产成人精品影院| 日本视频免费一区| 亚洲视频一二区| 国产三级三级三级精品8ⅰ区| 欧美曰成人黄网| 高清日韩电视剧大全免费| 日韩综合在线视频| 一区二区三区在线免费观看| 欧美国产一区视频在线观看| 欧美成人一区二区三区片免费| 欧美在线免费播放| 日韩视频在线你懂得| 在线电影国产精品| 欧美妇女性影城| 欧美日韩一区精品| 欧美日韩国产成人在线91| 欧美日韩综合色| 欧美区视频在线观看| 欧美伊人久久大香线蕉综合69| 欧美中文字幕亚洲一区二区va在线| 91免费看视频| 欧洲一区二区三区免费视频| 欧美日韩色综合| 91精品国产综合久久香蕉的特点| 91精品国产乱| 26uuu精品一区二区| 国产精品视频一二三区| **网站欧美大片在线观看| 亚洲欧美日韩国产中文在线| 亚洲一区二区三区视频在线| 亚洲一区二区免费视频| 免费日韩伦理电影| 国内精品久久久久影院薰衣草 | 日韩你懂的在线观看| 欧美成人精精品一区二区频| 久久亚洲综合色| 欧美国产日韩一二三区| 亚洲猫色日本管| 日本不卡的三区四区五区| 国模大尺度一区二区三区| 成人精品国产免费网站| 欧洲一区二区三区在线| 精品日韩av一区二区| 国产精品乱人伦| 午夜精品一区二区三区电影天堂 | 美女网站视频久久| 国产一区二区三区蝌蚪| 91在线丨porny丨国产| 欧美日韩五月天| 久久久99免费| 一区二区三区国产豹纹内裤在线| 日日摸夜夜添夜夜添国产精品| 激情欧美一区二区三区在线观看| 国产成人午夜片在线观看高清观看| 91麻豆精品在线观看| 91精品国产麻豆| 国产精品动漫网站| 日韩高清不卡一区二区三区| 国产成人精品免费| 欧美二区乱c少妇| 中文字幕欧美三区| 亚洲v日本v欧美v久久精品| 韩国一区二区三区| 日韩精品在线一区| 中文字幕日本不卡| 美女视频网站黄色亚洲| 91在线观看下载| 精品国内片67194| 亚洲一卡二卡三卡四卡无卡久久| 国产精品亚洲一区二区三区妖精| 欧美亚洲一区二区在线观看| 国产香蕉久久精品综合网| 午夜精品免费在线| 91麻豆蜜桃一区二区三区| 久久久久久99精品| 午夜视频一区在线观看| av毛片久久久久**hd| www国产精品av| 首页亚洲欧美制服丝腿| 色香蕉久久蜜桃| 日本一区二区三级电影在线观看| 首页国产欧美久久| 在线视频一区二区免费| 国产精品久久久久久亚洲伦 | 成人app网站| 久久免费午夜影院| 日韩成人精品视频| 欧美在线一二三| 日韩毛片高清在线播放| 国产福利精品导航| 精品成人一区二区三区四区| 日本系列欧美系列| 欧美人妇做爰xxxⅹ性高电影| 亚洲精品中文在线影院| 91色porny| 国产精品福利在线播放| 成人国产精品免费网站| 欧美经典三级视频一区二区三区| 国内精品国产成人国产三级粉色| 欧美一区二区三区播放老司机| 午夜视频一区二区| 欧美日韩和欧美的一区二区| 亚洲靠逼com| 色综合天天狠狠| 1024亚洲合集| 91最新地址在线播放| 亚洲视频中文字幕| 色综合久久综合网欧美综合网| 日韩av网站在线观看| 在线视频你懂得一区二区三区| 亚洲美女在线国产| 在线欧美一区二区| 一区二区三区欧美在线观看| 91网页版在线| 亚洲蜜臀av乱码久久精品蜜桃| www.av精品| 亚洲最色的网站| 91欧美一区二区| 亚洲午夜在线电影| 欧美日韩第一区日日骚| 婷婷中文字幕综合| 欧美一区二区日韩| 狠狠色丁香久久婷婷综| 久久久久97国产精华液好用吗| 国产不卡视频在线播放| 国产精品福利影院| 欧美三级视频在线观看| 亚洲123区在线观看| 欧美mv和日韩mv国产网站| 国产精品亚洲人在线观看| 中文字幕永久在线不卡| 一本色道**综合亚洲精品蜜桃冫| 亚洲成av人片在www色猫咪| 日韩一区二区三区四区| 国产一区999| 亚洲欧美一区二区视频| 欧美日韩一区二区不卡| 久久99久国产精品黄毛片色诱| 欧美国产一区二区| 在线观看区一区二| 久久99国产精品成人| 国产精品视频九色porn| 欧美裸体bbwbbwbbw| 国产精品自拍三区| 一区二区三区国产| 日韩欧美色综合| 91免费版在线| 久久精品二区亚洲w码| 国产精品不卡在线观看| 717成人午夜免费福利电影| 国产精品自产自拍| 亚洲综合区在线| 久久网站热最新地址| 欧美亚洲综合在线| 国产宾馆实践打屁股91| 五月激情综合婷婷| 国产精品国产三级国产a| 56国语精品自产拍在线观看| 成人性生交大片免费| 青娱乐精品视频在线| 亚洲欧美在线视频| 欧美变态tickling挠脚心| 色婷婷久久久久swag精品 | 丁香婷婷综合激情五月色| 亚洲国产成人高清精品| 香蕉久久一区二区不卡无毒影院| 久久久久久久久久美女| 欧美日韩亚洲综合一区二区三区 | 欧美久久高跟鞋激| 99久久久国产精品免费蜜臀| 久久国产精品色婷婷| 亚洲成人动漫一区| 亚洲私人影院在线观看| 久久久久一区二区三区四区| 欧美日韩免费高清一区色橹橹| 99久免费精品视频在线观看|