November 29, 2002
XP Visual Styles

Ah, I feel a rant coming on. How many hours must I spend fighting with CommCtrls 6 just to get my app to look right under XP.

To start lets go for ownerdraw buttons. The second you ask for ownerdraw (or bitmap buttons for that matter) XP decides that you couldn't possibly want the themed background for your button. I had to find the code to do the entire drawing process myself. Wonderful.

Continuing on the theme (pun not intended) of buttons, try creating a simple application with a number of buttons on a dialog. Enable theming for this application and keep running the app. Try moving the focus between buttons by clicking on each different one, and then separately try using the keyboard to move between them. If you can describe the rules that define the difference between these two drawing styles (below) then please do let me know:

And now to tab controls. These can look really nice when properly themed. The only problem is that it seems nigh-on impossible to get this right.

Scenario 1: Create a tab control on a dialog, and use dialogs for the pages. The tab control will appear correctly themed, but the dialogs (the tab pages) will not. Use EnableThemeDialogTexture I hear you cry. Unfortunately, while this might appear to work at first you'll notice two things:

1) The background of the tab page does not contain the correct gradiented background, but simply a plain colour all over. wrong.

2) Try adding a checkbox to the dialog. Oh dear, it would appear that the checkbox is drawing the old grey colour instead of the nice white that should be used. disaster!

I tried a number of different ways to solve this problem including overriding WM_ERASEBKGND, WM_CTLCOLORDLG, WM_CTLCOLORSTATIC and friends. None of these could get the correct gradient in the background of the tab.

Scenario 2: At this point, I noticed that property pages seemed to look OK in some programs that I'd seen, so I decided to try swapping my tab control for a property sheet and see if that works.

Low and behold, my first tab looked fantastic - all the controls were correctly themed, the checkboxes had transparent backgrounds and the tab had a gradient. Who knows what's different between a property sheet and a tab control.

Then I switched to my second tab page (which had only a list control on it). disaster! The second page had the all-original, everyone's favorite COLOR_BTNFACE background. So why did one page work, and the other not? To cut a long story short (one which involved lots of resource editing and recompiling) I discovered that page one had a button control on it, and page two didn't. Adding a single button to page two enabled the theming. Please, someone, explain this madness to me!

If anyone has a surefire way to enable theming on XP tab controls, then please let me know. I would be most grateful for your help.

Posted by Simon at 05:28 PM
November 27, 2002
PN2 Options Dialog

One of the most important features to develop (believe it or not) in PN2 is the options dialog. Many people open an application and go straight to the options - the "what can I play with?" test.

For the past week (or so) I've been working almost exclusively on this feature, and here's a taster screenshot:

In PN1 the scheme configuration was very separate from the main application options. This has all changed with PN2 with a much prettier and properly integrated options system. All developed in house, the new system provides enormous amounts of configurability - so much that my brain hurts when working on the code for it!

To read more about how the scheme configuration works, you can see the article here.

Posted by Simon at 10:39 PM
November 08, 2002
More Browser-Based Aggie

I finally got browser based aggie to work thanks to Sean and a bit more fiddling. It appears you need to grant the "Write" right to the wwwroot folder as well as the BrowserAggie installed folder (or I misunderstood seans instructions). Is this a bug?

I miss the collapsed view from the Aggie pixel skin, but the rest is quite nice and polished - although I'm unsure of the function of some of the buttons (the Scan button, for example). There are the traditional browser-based page update problems - the need to press F5 occasionally to see updated pages. I couldn't find a way to simulate a press of the Go! button thereby wiping out old news without pressing the "Update" button on each feed.

Anyway, well done Sean and keep up the good work.

Posted by Simon at 03:01 PM
November 07, 2002
Photo Studio

Seeing as I'm on a roll with this categories malarky, I'll add another link to a cool piece of software - "Photo Studio" by my mate John Hawkins. This excellent piece of software is a free JPEG organiser, manipulator, tool and more. It also does movies and other file types. If you're a digital camera user (I've got a lovely Canon Powershot S30 which I highly recommend) then I seriously recommend you check out Photo Studio.

Incidentally, the version on his website is old. I know because I have a much newer version. I suggest you bug him for a newer version. If enough people bug him, he might get around to releasing the newer version.

Posted by Simon at 10:10 PM
Aggie

The first entry in my "Cool Software" category, great :) I've just discovered Aggie in the last few days. I've been using FeedReader for a while, which is quite cute and got the job done (p.s. the job I'm referring to is RSS aggregation). However, the bugs got too much for me as did its spinning tray icon. I was spending too much of my day bringing up FeedReader and trying to find what was new and/or interesting.

Aggie nicely groups all of the new news together for me when I want to read it. This has actually been a great productivity boost for me. In addition, it has made me feel happier about RSS in general - I don't have to look for new news, it is just presented to me. This is made even better by the fantastic "Pixel" skin for Aggie. I'm now far happier about subscribing to loads of RSS feeds as I don't spend my time looking for ones with new news.

Now, if I was going to suggest improvements for Aggie - these would be mine:

1. Make more of the GUI, allow an internal view of the generated HTML.
2. Then, have a list down the left with "New News" at the top, and each feed down the side. The feeds when selected would show their recent posts. See below for why.
3. A search.

Sometimes, I'll have read an item and the next time I load Aggie it's gone. This is right and good (in some ways) - it is old news. However, I'd like some way of getting back to it.

Sean is working on a browser-based version of Aggie. It looks nice but I've had problems actually using it. Once these are sorted, it could be quite cool.

Posted by Simon at 10:07 PM
User Customisable Schemes

Roughly as suggested in the article I've mostly implemented the user-customisable scheme settings which are used at scheme compile time. It's not enabled in the code yet, but will be for the next release - it was actually more simple to write than I thought it would be - that means it's going to be more difficult when I get to writing the actual configuration dialog.

Those that are interested can see the UserSettingsParser class in SchemeCompiler.h and SchemeCompiler.cpp.

I also added the missing _CrtDumpMemoryLeaks() call and added some missing tear-down code. Much cleaner now. In addition I removed some un-neccessary calls to CString.Format in the compiler - should improve speed a little.

Posted by Simon at 09:48 PM