Page 1 of 1

wxRibbonBar Office 2010 and Metro Art Providers

Posted: Fri May 03, 2013 10:18 pm
by iwbnwif
I have put together two wxRibbonArtProvider classes that make a wxRibbonBar look similar to Office 2010 and Windows 8 Metro respectively.

At the moment they are still a bit messy but are okay. If anyone is interested in copies at this stage, just ask.
office2010.PNG
office2010.PNG (37.84 KiB) Viewed 8668 times
metro.png
metro.png (31.5 KiB) Viewed 8668 times
There are a couple of problems that I would like to ask about:

1. Unlike the old MSW ribbon panels only have a divider at their right end, however I can't find a way to add a few pixels to the panel to be able to draw the divider. If I draw it in the current panel rect it is too close to the controls.

2. I haven't been able to figure out the HSL adjustment of colours and the macros LikePrimary and LikeSeconary. I have tried using an online RGB to HSL converter but the results from these macros don't seem to match up at all. This is less of a problem for the Metro provider because there are no gradients and actually I would like to use wxSystemColour as much as possible.

Thanks for any advice.

Re: wxRibbonBar Office 2010 and Metro Art Providers

Posted: Mon May 06, 2013 1:23 pm
by Cursor
Oh yes ! Looks good, I want it ;)

Do you plan to submit it to wxWidgets for integration ? Or do you plan to release it in any licence ?

Best regards

Emilien

Re: wxRibbonBar Office 2010 and Metro Art Providers

Posted: Wed May 08, 2013 7:41 pm
by iwbnwif
Hi Emilien, sorry I haven't had time to work on this for the past few days.

I simply want to donate it to wxWidgets if it is of interest to them, I don't require any licence or credit etc. Its really just a straightforward adaptation of the existing MSW art provider.

Re: wxRibbonBar Office 2010 and Metro Art Providers

Posted: Fri May 10, 2013 7:48 am
by Cursor
If you want to offer your code to wx, you just have to submit an enhancement patch (http://trac.wxwidgets.org/wiki/HowToSubmitPatches).
If your code is clean and the feature usable, there is no reason it will not be integrated.

Dont hesitate to submit a patch like this, the feature looks good; problems seems to be really minor (little visual adaptations).
Moreover, when you patch, developpers can enhance your code, even if it is not integrated immediately.

Best regards

Re: wxRibbonBar Office 2010 and Metro Art Providers

Posted: Sun May 12, 2013 9:03 pm
by iwbnwif
Thank you for the pointers. I am away for a week but will tidy up the two classes as much as I can and then submit them.

The main problem with my code at the moment is that it is using RGB colours so although they look fine on the default MSW colours, I think they will look awful if the user changes their colour scheme!

Re: wxRibbonBar Office 2010 and Metro Art Providers

Posted: Mon May 13, 2013 6:19 am
by Cursor
If you think you will have a fix at short term, take the time to fix that. Otherwise, dont hesitate to submit your patch and describe the problem in the ticket. Someone probably can look at it :).
As I am interested by this functionality, I will intend to look at it too.

Re: wxRibbonBar Office 2010 and Metro Art Providers

Posted: Fri May 17, 2013 7:21 pm
by iwbnwif
Hi,

Sorry for the delay. I have spent some time today trying to work out the relationship of the colours, but haven't found an answer yet.

Attached are the two files for the Metro look. I don't feel that the code is clean enough to submit yet but would welcome any opinions.

I have a three file limit, so will add the Office 2010 look in the next post

Re: wxRibbonBar Office 2010 and Metro Art Providers

Posted: Fri May 17, 2013 7:22 pm
by iwbnwif
Office 2010 look art provider ...