[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-cygwin
Subject:    Re: QBitmap problems
From:       Peter_Kümmel <syntheticpp () gmx ! net>
Date:       2005-01-26 12:39:33
Message-ID: 41F78F85.4020401 () gmx ! net
[Download RAW message or body]

Chris January wrote:
> 
> Which of the images in disable_buttons_winFree.png is the current one?
> 
> Chris

They are both actual, one is the disabled QToolButton and the other the
disabled QPushButton, see attached code.

Peter


["trial2.C" (text/plain)]

#include <qapplication.h>
#include <qpixmap.h>
#include <qpushbutton.h>
#include <qtoolbar.h>
#include <qtoolbutton.h>


static const char* const image_data[] = {
"22 22 50 1",
". c None",
"g c #000000",
"# c #180808",
"a c #200808",
"h c #290c08",
"b c #311010",
"p c #5a2820",
"x c #8b0c08",
"f c #8b615a",
"N c #9c0400",
"w c #ac0000",
"o c #b44c41",
"M c #bd0400",
"T c #bd1410",
"J c #bd2410",
"v c #bd615a",
"E c #c53c31",
"R c #c54c41",
"I c #c55041",
"u c #c5695a",
"t c #c56962",
"s c #c56d62",
"V c #c57d7b",
"D c #cd5552",
"C c #cd5d52",
"H c #cd615a",
"r c #cd716a",
"e c #cdbebd",
"B c #d5655a",
"A c #d56962",
"z c #d56d62",
"L c #d5716a",
"S c #d57573",
"O c #d57973",
"n c #d57d7b",
"y c #de716a",
"G c #de7573",
"P c #de7d73",
"m c #de8583",
"c c #de898b",
"l c #de918b",
"K c #e67d73",
"F c #e67d7b",
"k c #e6958b",
"j c #e69d94",
"U c #e6d2d5",
"q c #ee9d94",
"d c #ffeaee",
"Q c #fffaff",
"i c #ffffff",
"......................",
"......#aaaaaaaa.......",
".....bcddddddefg......",
"....hcijjkllmnopg.....",
"...hciqrrstuuvwxpg....",
"..bcilyyyzABCDEwxpg...",
".#ciqyyiFGyzHiIJwxpg..",
".adjKyiiiFGLiiiIMNpg..",
".adjOyFiiiPiQiCEMNpg..",
".adkOzGFiiiiiCREMNpg..",
".adlOAyGPiiiHIIEMNpg..",
".adlSBzLiiiiiRETMNpg..",
".#dnrCHiQiHiiiJMMNpg..",
".aUnvEiiiCIRiiiJMNpg..",
".aVowJEiRREJJiMMNxpg..",
"..gpxwJJJJTJMJMNxpg...",
"...gpxwMMMMMMMNxpg....",
"....gpxNNNNNNNxpg.....",
".....gpppppppppg......",
"......ggggggggg.......",
"......................",
"......................"};


int main(int argc, char * argv[])
{
    QApplication a( argc, argv );
	 
    QPixmap image( (const char **) image_data );

    QToolBar toolbar;
    toolbar.resize( 100, 30 );

    QToolButton button(image, "Stop!", "",  0, 0, &toolbar, "");
	button.setPixmap(image);
    button.setEnabled(false);

    a.setMainWidget( &toolbar );
    toolbar.show();

    QPushButton button2( "Stop!", 0 );
    button2.setPixmap(image);	
	button2.setEnabled(false);
 
    button2.resize( 100, 30 );
 
    a.setMainWidget( &button2 );
    button2.show();

    return a.exec();
}


_______________________________________________
kde-cygwin mailing list
kde-cygwin@kde.org
https://mail.kde.org/mailman/listinfo/kde-cygwin


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic