Jens
Qt
Styles
DotNet
Posted by Jens
 in Qt, Styles, DotNet
 on Friday, July 06, 2007 @ 17:18

The style now comes in two flavors: Standard, and Office. The standard style is the one seen previously. The new Office style is presented here:

office style

I also have some good news for commercial users waiting for this. The style will be renamed QtDotNetStyle and should be released as a dual licensed Qt Solution, hopefully next week.

8 Responses to “DotNet style with Office flavor”

» Posted by Clement
 on Sunday, July 08, 2007 @ 12:34

This is great news !

I updated from the SVN and now the style fails to compile under VS2005 (No SP), I got 2 C2264 errors in dotnetstyle.cpp, at lines 1127 and 1128.

» Posted by Clement
 on Sunday, July 08, 2007 @ 12:53

I fixed the bug :) Here is the diff file content :

Index: /path/to/Qt/DotNetStyle/dotnetstyle.cpp
===================================================================
— /path/to/Qt/DotNetStyle/dotnetstyle.cpp (revision 52)
+++ /path/to/Qt/DotNetStyle/dotnetstyle.cpp (working copy)
@@ -1124,8 +1124,8 @@
WCHAR themeColor[maxlength];
internalPalette = Classic;
if (pIsAppThemed && pIsAppThemed() && pGetCurrentThemeName(themeFileName, maxlength, themeColor, maxlength, NULL, 0) == S_OK) {
- QString name = QString::fromUtf16(themeFileName);
- QString color = QString::fromUtf16(themeColor);
+ QString name = QString::fromWCharArray(themeFileName);
+ QString color = QString::fromWCharArray(themeColor);
if (theme == DotNetStyle::Standard) {
if (name.endsWith(”Luna.msstyles”)) {
if (color == “Metallic”)

» Reply from Jens
 on Sunday, July 08, 2007 @ 19:12

Thanks clement. I’ll see if I can get it patched up soon. It’s good to get feedback like that.

» Posted by Mark
 on Monday, July 09, 2007 @ 07:02

This looks fantastic and it’s great news that it’s being made available to commercial customers, however, shouldn’t this be a part of Qt itself rather than a Solution?

» Reply from Jens
 on Monday, July 09, 2007 @ 08:18

Mark: Since it is not really the platform look and feel and it only makes sense for Windows customers, I think it makes most sense to deliver it as a solution at the moment. This also has the added benefit of being made available to people without having to wait for the next minor release of Qt. We need to be careful about what we actually include inside the Qt libraries since adding things comes at the expense of library size and maintainability. There are some signs that Microsoft is moving away from this style and adding it inside Qt essentially means we have to stay committed to it for all future versions. That said, popular solutions do have a tendency to make it into Qt itself.

» Posted by Andy Brice
 on Tuesday, July 10, 2007 @ 16:09

Excellent. I look forward to trying it.

» Posted by Marius
 on Wednesday, July 11, 2007 @ 09:47

To all our commercial customers:
The QtDotNetStyle has now been released as a Qt Solution product! Go get it! :-)
http://trolltech.com/products/qt/addon/solutions/catalog/4/styles/qtdotnetstyle

» Posted by Andy Brice
 on Wednesday, July 11, 2007 @ 16:22

I needed to make this change to get it to work with vc6:
if (QStatusBar *statusBar = qFindChild( mw )) {
to
if (QStatusBar *statusBar = mw->findChild()) {

How do I get the blue/orange office style? I am running XP with the style set to XP and the colour scheme to ‘Default (blue)’ and have initialised the QApplication with:

setStyle( new QtDotNetStyle( QtDotNetStyle::Office ) );



© 2008 Nokia Corporation and/or its subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation in Finland and/or other countries worldwide.
All other trademarks are property of their respective owners.