Well, first of all, as you pointed out- both can sometimes be possible. That aside...
If I had to choose strictly one or the other, I would choose reason over happiness. If you've ever seen the movie The Matrix, I view it kind of like how some of the crew members did. The Matrix is a reasonably ok virtual reality that people live in and have no idea they live there, whereas the real world is a barren, cold, destroyed place. Some of the crew members argue whether it's really better to be "freed" from the prison of the Matrix if it means they are stuck in a rather crappy real world. I would choose to be freed from the Matrix even if it meant that the real world was a worse place.
I would also argue that it's not usually a choice, but instead just happens one way or another. Some people are more pre-disposed to be logical, and can't help but to view everything in a critical way. Once a myth is dispelled, even if it was pleasant, it is virtually impossible to return to.
-Lyn
The Matrix is a pretty good example. The problem with using the comparison is that people look at Cypher and they're like, "omigash, he's such an evil guy, man, and he doesn't prefer reality," and they look at Neo are like, "omigash, Neo has this self-inclination towards finding the truth, and he's miserable without it man, a splinter in his mind, you know" (love the Matrix, but it does attract a lot of annoying pseudophilosophical people).
To clarify (without sarcasm): Neo prefers the real world
because he is inexorably unhappy with the false world of the Matrix. That is, he's more happy with the truth (even though it's initially quite distressing); the other members of the crew (and in Zion) have the goal of restoring the rest of the human race (in the Matrix) to the real world, which would presumably result in a restored Earth -- not sure, but that seems the implication to me: everyone's freed, the machines have no more "fuel", they die, and things are back to where they were before the Matrix. In both the cases of Neo (in getting out of the Matrix) and the people of Zion (and the crew), the reason for escaping the Matrix is related to a quest for happiness. That means they aren't choosing reason/knowledge/the truth/logic/whatever
at the expense of happiness in the long run. It's even questionable that they're choosing to sacrifice happiness in the short run: the real world is an ugly, unattractive place (as you point out), but they all seem to share the same inward drive to realization that Neo also shares -- which means they can't be happy in the fake world of the Matrix, and even happier in the real world, although they obviously have lost many of the pluses of the Matrix (wealth, chicks, pretty sunshiny days, good food, etc.).
The point: the Matrix is an example of knowing the truth and happiness lining up, and so it isn't really an example of the dichotomy I'm pointing out in the OP. A good example I have in mind is, well, take a look at talkrational.org or philosophyforums.com -- pervaded with very, very smart people who in many cases tend to be irritable, sarcastic, many times humorless, cold, careless, etc. They live a life that reflects a preference for reason at the expense of happiness (in that they aren't inclined to seek happiness in as many ways as possible, similar to their obvious preference for being "right").