habbisify opened a new pull request #114:
URL: https://github.com/apache/pdfbox/pull/114


   This pull request is discussed in Jira ticket:
   https://issues.apache.org/jira/browse/PDFBOX-4073
   
   Our take on this: There could be a need to work with millimetres or inches 
instead of points. @THausherr commented that he uses PDFBox with points and 
adjusts the parameters via trial and error until he likes what he sees. 
However, our take on this topic is that there are documents which are strictly 
standardized to have certain measures, such as offset from the paper edges, in 
millimetres or inches.
   
   Another concern by @lehmi was that the original idea of the reporter, "a 
central setting of an unitconverter so that every coordinate is converted deep 
inside shortly before rendering", is problematic since it will ultimately lead 
to more complicated and error prone code. We agree with this point.
   
   Therefore, instead of implementing an internal unitconverter setting, we 
simply implemented a convertUnit method inside PDAbstractContentStream to do 
the unitconversion from mm or inches to points. This will not complicate other 
code or make it more error prone - it is just a stand-alone method to do the 
conversion. Basic test was also implemented to check that the unitconversion 
works as expected with the convertUnit method.
   
   Please note, this PR is a mandatory part of the university course we are 
taking. However, acceptance of the PR is not required. This is also the last 
submission our group during this course.
   
   What do you think?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to