patch missing code, remove apparent duplicate code, fix overall compilation
PictFormat is typedefed from XID
Merge branch 'x11-demo-fixes' of github.com:twall/jna into x11-demo-fixes