View Full Version : Degree of color
NewLegend
21st November 2010, 18:04
Hello
How do I know the degree the color of the window?
- The normal color of qt creator.
http://www13.0zz0.com/2010/11/21/18/646466948.png (http://www.0zz0.com)
tbscope
21st November 2010, 18:08
Please try to ask that question again. I can't make anything out of it. What do you want to know? What colors are used by Qt Creator?
NewLegend
21st November 2010, 18:37
Please try to ask that question again. I can't make anything out of it. What do you want to know? What colors are used by Qt Creator?
I want to paint the graphicsView with the same background color.
by Using
ui->graphicsView->setBackgroundBrush(QBrush( Qt::lightGray, Qt::SolidPattern));
Experimented more than one color without interest.
In short, what is the background color of the MainWindow?
FelixB
22nd November 2010, 10:02
try this:
QPalette palette = yourWidget->palette();
QColor color = palette.color(QPalette::Base);
wysota
22nd November 2010, 15:33
It's more likely QPalette::Window and not QPalette::Base.
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.