Categorized examples

That's importing the example file changes from pull request #742 so it's easier to prepare them for inclusion.

(It's also rebased against current master as the original pull request did cause some conflicts with the latest changes in master)