1

I'm currently working on a project that allows a user to pick an image, edit the text in it (using jQuery jEditable on a position:absolute formatted element to make it 'seem' like its the image still).

Once the user is happy with the edit, they save their changes and it creates an image with the updated text. This is all working fine but I'm having issues with the X and Y coordinates for the text. It seems that every time I pass through the top / left pixel values to imagettftext() it is slightly off.

I'm aware that the font-size value is measured in points instead of pixels and was wondering if that was the same issue with the X & Y? Unfortunately the documentation makes no reference of what the X and Y are measured in.

So my question is: What measurement does GD2 use for the X and Y coordinates & is this related to my top/left position issue?

Thanks!

4

0 回答 0