Adding selection support

The multiple commits are caused by me uploading code via Github. I will rebase it all before I merge. 
Hm, the selector for `content` looks a bit complex and buggy. What happens with code when `pdfexport-content` isn’t checked? And why not use an id for the input element?