DotNet style with Office flavor

Posted by Jens Bache-Wiig on July 6, 2007 · 8 comments

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.

QShare(this)

Possibly related posts:

  1. Lighthouse is integrated!

8 comments

1 Clement July 8, 2007 at 1:34 pm
 

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.

2 Clement July 8, 2007 at 1:53 pm
 

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”)

3 Jens July 8, 2007 at 8:12 pm
 

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

4 Mark July 9, 2007 at 8:02 am
 

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?

5 Jens July 9, 2007 at 9:18 am
 

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.

6 Andy Brice July 10, 2007 at 5:09 pm
 

Excellent. I look forward to trying it.

7 Marius July 11, 2007 at 10:47 am
 

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

8 Andy Brice July 11, 2007 at 5:22 pm
 

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 ) );

Comments on this entry are closed.

Previous post:

Next post: