At present, if a placed image is :at[x,y], none of the other image position options are read.
It would be nice to be able to use something like
image "file.png" :at=>[300,100], :position=>center, :vposition=>center
whereby the centre of the image, rather than the top left, would be positioned at 300,100.
Prawn has already read the image dimensions when it comes to determining the placement, so it can do this more efficiently than the calling program.
(Incidentally, thanks for the quick and excellent response to #281!)
Adding the following code to lib/prawn/images.rb at line 122 works:
(apologies - haven't got my head around git enough to send a pull request yet but will try for next time :) )
This is a neat idea, but I feel like the right solution is for us to come up with a unified API for positioning box-like content, rather than adding new special cases to each component.
Sorry we never responded to you about this, the project died down for a while. The good news is that we're now active again, so your contributions would be welcome!
Adding myself to the issue
I created a fork with your code: https://github.com/mirelon/prawn/tree/patch-1