Added fixes mentioned in bugreport 3306
- Added author provided fixes
- Added code example
- Added documentation fixes
Merge pull request #1845 from StevenPuttemans:bugfix_3306