move configurable to Document class

since every document type is depend on it now
add pic document type
style cleanup in document.lua
Merge pull request #324 from houqp/houqp-master

add pic document type for jpeg