I had a very frustrating experience last week trying to align the baselines of adjacent pieces of text in a WPF app. The problem seems to be that this is supported behaviour in a flow document, but not in general UI (e.g. the visual tree of a Window).
After a lot of fiddling, head scratching and googling we discovered that the easiest way to do this is to have two TextBlock elements inside an outer TextBlock. The following markup:

produces this end result:

The TextBlock has magically communicated with its TextBlock children and pulled them into line.
However, we are using a Label next to a ContentPresenter to present arbitrary data with a DataTemplate and we couldn’t find a way to automatically line up the baseline of text in each control.
This isn’t really surprising, since the ContentPresenter could present just about anything. It just so happens in our app that this is a line of text (with a different font size to the label next to it).
In the end, we had to resort to top aligning the Label (small font size) and the ContentPresenter (larger font size) and binding the Margin property on the Label to its FontSize property via a converter. This did the trick, but involved a hack because we couldn’t understand the Baseline property on the FontFamily class.
It seems from the MSDN docs that the Baseline property on this class should be the proportion of a font’s height represented by the distance from the very top to the baseline of the text, i.e. it should be less than 1. However, for Verdana it is 1.005!
The code in our converter ended up looking like this and I’m a bit shamefaced to be publishing it! I know that we will have to revisit this in the future and I’m frustrated that we couldn’t find an elegant solution to the problem.

The 0.75 bit is particularly gratuitous. Can anyone shed any light on this?
What this new blog is about
Tech - I'm going to blog about technical stuff that interests / excites / confuses / frustrates me.
Meta-tech - I'm going to blog about over-arching concepts and issues related to software development. Philosophical, architectural, social...
I hope this blog will have an interesting slant because I started a new career as a software developer at the age of 33. It’s been a roller coaster ride over the last 2 years (so now you know my age) and I’ve had a chance to reflect on my experiences and want to get it out there on the internet.
Who I am
I'm currently specialising in C# and WPF. I've only been a developer for 2 years now, and have only been writing C# for 8 months. Before the C# I wrote Perl, and before that I was an actuary.
I chose this new career because I love developing software. I have a degree in maths and therefore an instinct for elegant solutions to technical problems and I enjoy building something that feels right and works well.
Getting into this industry without a Computer Science degree at the age of 33 wasn't easy and I'll definitely have more to say on that subject in future posts. I took the Perl job because I was interested in the language, liked the people who interviewed me, found the company interesting (it provides financial services) and, dare I say, because there weren't many companies out there willing to offer me a job. I really wanted to get into more mainstream, compiled languages such as Java or C#, but that simply wasn't a possibility 2 years ago. I was caught in the "no job without experience and no experience without a job" trap.
At the start of this year an opportunity came up to work for an agile shop and I jumped in. I wanted to work with C# and the .NET framework and I wanted to see a published product through from inception to delivery. I also wanted to learn about Test Driven Development and all that that implies.
It’s been a case of “be careful what you wish for”. I have had to get up to speed on a slew of new technologies (C# 3.0, WPF, WCF, threading, Linq, MbUnit, JavaScript, NHibernate) and also grapple with good practices such as low coupling, DRY, programming to interfaces, etc. and at times I’ve felt overwhelmed.
But I’m glad I took the plunge and I’m looking forward to learning more about the wonderful world of computers and software development. That seems enough for a first post. Time to think about what to blog about first!