Book List

Okay, I’ll admit it: I love making lists. The Pragmatic ProgrammerI’m one of those people that can make a list of things to do, and add one or two things I’ve already done, just so I can enjoy that feeling you get when you check something off the to-do-list. Do you recognize that feeling?

For books I know there’s wildly popular sites like Goodreads, to keep a list of things to read, get suggestions, and so on. I wanted something simpler, and something I have control over. So I decided to put it up on my blog as a page, just like all the (other?) hipsters with blogs. Not so much a reading list to tell others what they should read, but more a track record where I can quickly look up things I’ve read before.

The book that inspired me for this reading list (shown in the image) is The Pragmatic Programmer, amongst others. Who knows; perhaps this post will inspire others to (re)start a reading list as well?

Want to know what I have been reading? Check out my book list.

Episode 4: Android Stack Exchange Challenge

Android Enthusiasts Stack Exchange

Here’s a short new post in the Stack Exchange Challenge, this time on the relatively new Android Stack Exchange site.

Recently I’ve been mostly lurking on the main Stack Overflow site, incidentally asking or answering a question or two. However, I’m not ready yet to do a post on the main site…yet.

The reason I was triggered to write a new post on the Android sub-domain will become clear in the section with My Questions, below. Let’s have a look at how the site will hold up (compare?) against, say, XDA-Developers.

Current Statistics

Here’s the stats for this relatively new sub-domain:

Fact Android.SE
Questions 7,948
Questions with no upvoted answers 1,309 (16.47%)
FAQ (questions with most links) 2,344
Top 3 questions 134 votes, 115 votes, 98 votes
Questions active last hour 6
All-time rep for top 3 users 30.1k, 15.8k, 15.6k
Meta questions 322

My Questions

At the moment of writing, there’s only one item in my questions on Android Enthusiasts. I wasn’t a regular, in fact I had not visited the site before I figured it was the best place to go with my question:

And there’s the reason I love browsing through the Stack Exchange sites (usually): the percentage of nice and helpful people on those sites is very high! Within the hour someone popped up and wrote a detailed, practical answer. Awesome! And a great incentive to write this post.

My Answers

To be honest: I didn’t spend very much time on the site after asking my question. Before writing this I decided to sit down, do some research, and even help out and answer a question or two if I could. I’m almost too ashamed to post it, but here are the results:

Interesting questions

Here’s a few questions that caught my eye:

After skimming through the first four pages of questions (by votes) I gave up. This site is not for me. The questions aren’t “bad”, but they’re just mainly… boring or trivial.

Community Wiki

The top wiki-style question is (not very unexpected) about changing your phone: how to root it.

Conclusion

This site is not for me. However: it did remind me of how nice the communities on most (if not: all) Stack Exchange sites are!

Can haz layout

Contains IE Hack This weekend I decided to deep dive in a StackOverflow question on the combination of pseudo-elements and the IE8 (and lower) filters. Even though it seemed to me the question couldn’t be answered with 100% certainty, I still gave it a shot. A similar but better answer got accepted (damn you, “ScottS”!!), but that’s besides the point. The most important thing I learned from answering this question, is understanding the magic in IE (especially version 8 and below). So, for reference, here are the important links of articles that made me understand IE a bit better:

The kicker from all this research is that I now finally understand this remotely related line of CSS I’ve seen (and even used) a lot:

This is a CSS hack to get some versions of IE to behave nicely. So far, nothing new. However, after reading the above articles, I finally understand what it does: it  forces the hidden IE property hasLayout to true. And that’s useful for quite a few cases where you’d expect things to have layout, but when they don’t by default.

Hack or not, I’m glad I understand things a wee bit more now.

Episode 3: Gaming Stack Exchange Challenge

Space invaders wall painting
Space invaders wall painting

It’s been a while since my previous post: Episode 2 in my Stack Exchange Challenge, on Programming. Work, a new table-top RPG experiment, a Twitter vs Voice Recognition experiment, some playing around with MVC 3, and a big-ass painting on our living room wall (see pica) were all keeping me from writing on my blog.

In addition, even though I’ve been mildly active on various SE sites, I didn’t have a real drive to dive deeply into one of them. However, I did experience one peculiar effect of the SE engine last month: you can earn badges while not being very active on a site anymore.

One of the sites stood out the most, awarding me a gold badge for asking a (now apparently) famous question. And that’s as good a trigger as any to grab some more writing experience, et voila: a blog post on Gaming.StackExchange!

Current Statistics

Again, like last two reviews, some of the current facts for the site:

Fact Gaming.SE
Questions 18,629
Questions with no upvoted answers 845 (4.54%)
FAQ (questions with most links) 4,573
Top 3 questions 156 votes, 130 votes, 112 votes
Questions active last hour 8
All-time rep for top 3 users 75.6k, 34.6k, 31.6k
Meta questions 1,240

With 18k questions about as big as Programming, examined in my previous blog post.

Gaming.StackExchange logo
Gaming Stack Exchange

My Questions

At the time I write this I’ve asked a measly three questions. In my previous blogpost on Programming what held me back in asking questions was that I found it hard to ask “good subjective questions”. On Gaming there’s no such barrier, and as you can see in the FAQ they go for a totally different kind of questions here. What held me back in this case is just that on most games (the ones I play, at least) there’s already a ton of information to be found through Google search engines, rendering it useless to ask it again on SE. Of the three questions, these two were most interesting:

My Answers

Wups! Bad, bad community member. I haven’t written any answer yet. I came close once though.

Interesting Questions

Although I guess what gaming-questions are interesting depend heavily on what games you like, there are some questions that stand out if you have a look at the top questions:

Community Wiki

Not too many fun questions in this category at first sight, besides perhaps the Starcraft 2 skill improvement question.

Conclusion

The site is great for browsing through occasionally. It’s probably more fun if you go with the hype and by AAA titles the moment they come out. Surely the site will be flooded with Diablo 3 questions soon. Not intending to play D3 that will probably chase me away though, but perhaps that will push me to another SE site for my next SE challenge?

Episode 2: Programming Stack Exchange Challenge

Programmers Stack Exchange
Programmers Stack Exchange

Last week I wrote a post about CSS naming conventions, while trying to start up my review of the Programmers Stack Exchange site. Writing the question got me all excited about the wonderful answers and insights I was about to gain. Unfortunately my question fell to the 2nd page of the site quite quickly, with a meager one upvote, and one (though well-written) unsatisfactory answer.

For a week I debated whether to skip Programmers and review a different site, but today this problem struck me as an opportunity! This is a great way to test the bounty system. So I decided to put 100 of my current 106 reputation up for a bounty, looking for any answer that can provide me with something more solid than the “personal-preference” argument.

While waiting and frantically F5-refreshing the question I have some time to write about the site. One fun side-effect from the reputation system already became clear though: I can’t upvote any answers on the site anymore, because the 100 rep bounty I gave up dropped me below the 15 rep threshold you need to pass to be able to upvote things.

Current Statistics

Just like last review, first we dig up the current facts for this site:

Fact Programmers.SE
Questions 17,311
Questions with no upvoted answers 225 (1.30%)
FAQ (questions with most links) 4,241
Top 3 questions 313 votes, 275 votes, 275 votes
Questions active last hour 10
All-time rep for top 3 users 37.4k, 34.7k, 31.1k
Meta questions 1,004

Bigger than Cooking SE, but still quite the “little brother” to Stack Overflow.

My Questions

Next up, my questions. Even though I often have questions that feel like a great fit for Programmers SE, once I’m halfway writing them I tend to delete them again. The reason is simple: even though the “good subjective” kind of questions are the bread and butter of Programmers SE, I’m probably too exact to ask a subjective question. However, the one question that got this post rolling is still worth noting:

My Answers

Like many people I have a certain mental threshold before I post anything on a public site like Stack Overflow. However, I was determined to overcome or ignore the threshold for the Stack Exchange Challenge. Nonetheless, at the time of writing this, I came up with zero answers.

Perhaps in the future I will answer a question or two (heck, I may even answer my own question), but until then, this section is shamefully empty…

Interesting questions

Now this is the good part of Programmers Stack Exchange. Although often subjective or even “whiny”, there are quite a few questions that are interesting or plain fun to read! Some questions i enjoyed:

Community Wiki

Some fun ones on this site:

Conclusion

This particular Stack Exchange is a fun site. It’s a fine line though between subjectivity and questions following the “good” Q&A format. This fine line will probably keep me from becoming a regular poster. However, I can highly recommend the level of interaction I’ve currently settled on: follow them on Twitter for the occasional fun-to-read question that pops by.

CSS syntax naming conventions

My next Stack Exchange Challenge post will most likely be about the Programmers SE. One part of the challenge is to actually ask a question I have on the topic. The question I came up with (to be honest, this has been bothering me for months now) took quite some time to write down carefully. So, as I don’t have my next SE Challenge post ready yet, I decided to cross-post my question here on my blog as well.

The Question: what are the practical considerations for the syntax in class and id values?

Note that I’m not asking about the semantics, i.e. the actual words that are being used, as for example described in this blogpost. There are a lot of resources on that side of naming conventions already, in fact obscuring my search for practical information on the various syntactical bits: casing, use of interpunction (specifically the - dash), specific characters to use or avoid, etc.

To sum up the reasons I’m asking this question:

  • The naming restrictions on id and class don’t naturally lead to any conventions
  • The abundance of resources on the semantic side of naming conventions obscure searches on the syntactic considerations
  • I couldn’t find any authorative source on this
  • There wasn’t any question on SE Programmers yet on this topic

Some of the conventions I’ve considered using:

CSS naming conventions
CSS naming conventions
  1. UpperCamelCase, mainly as a cross-over habit from server side coding
  2. lowerCamelCase, for consistency with JavaScript naming conventions
  3. css-style-classes, which is consistent with naming of css properties (but can be annoying when Ctrl+Shift+ArrowKey selection of text)
  4. with_under_scores, which I personally haven’t seen used much
  5. alllowercase, simple to remember but can be hard to read for longer names
  6. UPPERCASEFTW, as a great way to annoy your fellow programmers (perhaps combined with option 4 for readability)

And probably I’ve left out some important options or combinations as well. So: what considerations are there for naming conventions, and to which convention do they lead?

Episode 1: Cooking Stack Exchange Challenge

Cooking Stack Exchange
Cooking Stack Exchange

Last week I announced the little Stack Exchange Challenge that I’d designed for myself. In this post I will be doing the first episode, featuring the Cooking Stack Exchangesite. This post should be the first in a series. I’ll try to stick to a format, though it may evolve a little over the episodes.

Important note: in all cases, I try to go through the site and actually contribute as a well-behaved member of the community. I’d love to be able to ask questions, answer some, and will up and downvote if it seems appropriate; but only if it is appropriate! Afterwards, I’ll summarize:

  • The questions I may have asked.
  • The answers I may have given.
  • Some questions that I found interesting and subsequently upvoted.
  • Noteworthy “community wiki” questions and answers.
  • A conclusion.

So, let’s move on to the Cooking site.

Current Statistics

First up, the current “fun facts” for this particular sub-site:

Fact Cooking.SE
Questions 5,336
Questions with no upvoted answers 56 (1.05%)
FAQ (questions with most links) 1,617
Top 3 questions 134 votes, 72 votes, 59 votes
Questions active last hour 3
All-time rep for top 3 users 27.6k, 23.4k, 19.1k
Meta questions 386

Not the biggest SE site, but still a decent volume of knowledge.

Photo's for the dishwasher-fish-recipe
Photo’s for the dishwasher-fish-recipe

My Questions

To be honest, my choice to do Cooking SE for the first episode was because I wanted to answer a particular question. When I wanted to do so it turned out that I needed to have earned at least 10 rep before I was even allowed to answer that question. Not to worry though, there were two actual questions I still had from my own cooking experiments in the past few weeks, so I came up with these:

My Answers

This section was the reason I picked Cooking SE first: I was very eager to provide an answer with empirical evidence for one particular question:

My wife and I were laughing uncontrollably when it turned out the experiment was successful. It was extremely fun to write this particular answer. Afterwards, I felt the urge to thank the creators of Stack Exchange, and so I did via Twitter. To my surprise and excitement @CodingHorror a.k.a. Jeff Atwood almost immediately retweeted this to his 65,000 (!) followers. What followed were several retweets, favorites, upvotes for the answers, and wonderful direct responses about my answer. This made me realize: I love the interwebs!

Interesting questions

There were several very interesting questions on this site for a home chef. Don’t expect any recipes (which are probably subjective and thus off-topic), but do expect very practical tips. Some questions I enjoyed:

Community Wiki

At first sight, there was just one real “ultimate list” question that caught my eye:

Conclusion

The Q&A format of Stack Exchange seems perfect for a particular type of cooking questions. Once you’re used to the fact that things like recipe-requests are off-topic you’ll start to appreciate the practical aspect of this site.

Probably because it’s a sister site to things like Stack Overflow, several top users note in their  bio that they’re “fulltime computer guy, part-time amateur chef“. That probably means I’m going to have a lot of fun there!

Stack Exchange Challenge

My new hobby: the great Stack Exchange sites.

In the 90’s most of my questions on software development were either answered by friends and family, trial and error, or books. I’ve always loved reading books on this topic. Most of my books have some particular animal on the cover, from the company with a man on a mission. In addition to books, the new millenium lured me to the Google Groups on C#. It seems at the time of writing this only a “new” Google Groups exists, which is a good thing: even though I enjoyed reading and posting there very much, the spam drove me (and many others) away.

Of course, just Google Search remained a very decent source for answers to development questions. In recent years, the search results have slowly started to point to one particular site: Stack Overflow. The various interesting sister sites quickly grabbed my attention.

I can highly recommend looking at the sites they have, and joining some of the discussions. Overall, the communities seemed very friendly to me as long as you put effort and thought in your questions and answers. Personally, I’m seriously considering to set myself up for a challenge and investigate one site a time, with perhaps a blog post on my findings. Now where shall I begin?

Shredder

Shredder, nemesis of the TMNT!
Shredder, nemesis of the TMNT!

Trading my three year old PC for a bottle of whisky (or is it whiskey?) to a friend seems like a great deal. With several work-related files left on my computer, it felt like a great opportunity to try out a shredding tool. So I figured I’d just Google for the popular choice and try it out.

Then I got submerged in a whirlpool of information. Some folks linked to “non geek perspectives”, for example this article on 4 file shredder tools. Others gave walls of text on the technical details. I was in fact hoping to find some article on the Dutch hardware.info site on this topic. In the end the Stack Exchange site for “power users” gave me the most info through a dedicated file-shredding-tag.

And there, finally: a great list of shredding options! Options all around: bootable CDs, hidden Windows 7 tools, as well as a  great post on Scott Hanselman’s blog. For some reason one of the answers with almost the least amount of answers caught my attention.

So I downloaded a bootable ISO of Ubuntu and fired it up. First I tried the “basic” suggestion:

The terminal screen just sat there, with a blinking caret. Apparently I’d entered a staring contest. After some time I decided to hit the enter key a few times in the console: the caret moved. After a minute of pondering I tried CTRL+C: and the operation got cancelled. I’d lost the staring competition, that’s for sure.

Now, this staring contest had taken about one hour. So I decided to try the second suggestion:

No dice. Utterly confising console error messages. Since I’m mot quite a Linux guru like these guys, I did some more searching around. Finally I found some more detailed instructions on hdparm. First I had to unfreeze my drive, and I had to set a password (though I don’t quite grasp why). Then the moment of truth…

Ever since I’ve been in yet another staring contest with Ubuntu. Only this time I’m gonna win, or die trying!


Update: after over two hours the staring contest is over… and won! The console returns to normal. At first, it seems Ubuntu can still browse the drives. But, after a reboot, there is not a single file, folder or partition to be found anymore!

CSS first-letter drop caps

A little while ago this interesting Stack Overflow question caught my attention. The question is about drop caps: a typographical gimmick where the first letter of a paragraph is very big and prominent. In older texts this could be even more than “prominent”, for example this page from an old Dutch Bible:

Drop caps in an old Dutch Bible
Drop caps in an old Dutch Bible

Of course, the CSS pseudo-selector :first-letter seems perfect to achieve this effect on the web. The question on Stack Overflow used that as a starting point, and is about a particular situation where IE wouldn’t render correctly. While trying to find a solution to that particular problem I found out things were not so simple, and posted this answer. The answer basically came down to “no way to get it right in all browsers”. With rather “standard” CSS rules, various browsers gave varying results:

Rendering of drop caps in various browsers
Various browsers render drop caps differently

Not very satisfying at all! After thinking about this some more, I decided to try and at least get a “minimal” example of drop caps working in all current browsers. To keep things “minimal” my first try will:

  • Not bother with padding for now (just set them all at zero);
  • Not bother (yet) with browsers <IE9;
  • Stick to the basic 26 characters from the latin alphabet;
  • Stick with uppercase versions of those characters.

It took some time, but I did come up with decent results. You can show the example html file on my blog, or view it as a jsfiddle. The example contains a reset style and some coloring so you can see the results clearly. However, the nitty gritty is in this bit of CSS:

This actually gives acceptable and mostly consistent results. Here’s a screenshot of how this renders in up to date versions of my browsers (all on Windows 7):

Drop caps experiment in IE9
IE9
Drop caps experiment in Chrome
Google Chrome
Drop caps experiment in Opera
Opera
Drop caps experiment in Firefox
Firefox

Great! However, one browser is still not playing nice. No, not everyone’s “favorite” browser IE is acting weird, but Firefox is! Have a closer look at the left (:first-letter) rendering in Firefox: the height of the drop cap isn’t what we want it to be. However, some searching on Google leads to a related Stack Overflow question as well as this question, ultimately leading me to a bug from 2007 in Firefox. Guess it can’t be done easily then.

End of the road? Perhaps. But perhaps also a great opportunity to try and create a jQuery plugin that creates drop caps…