Hi Leia,
Thank you for your enquiry.
It's definitely the tip of the pointer. Try pasting the following code into a Script Object on the page:
Code:
while (true) {
mousepos = GetMousePosition()
Debug.trace(mousepos.x + "," + mousepos.y + "\n")
wait()
}
Now preview the publication and move the mouse to the top-left corner of the publication whilst keeping an eye on the values appearing in the script output window. You should find that when these values read
0,0 the tip of the cursor arrow is positioned in the very top-left corner of the page.
Please note, however, that if you are aligning objects with the cursor position, the centre of the object will be placed at the cursor position. Therefore, if you have a 50 x 50 pixel frame aligned to the cursor position and position the cursor at the co-ordinates
0,0, only the bottom-right quarter of the frame will visible with the rest of the frame falling outside the top and left edges of the publication.
If you want the top-left corner of the object to be aligned with the cursor, you will need to factor the width and height of the object into the positioning as follows:
Code:
while (true) {
mousepos = GetMousePosition()
offsetx = Frame.GetWidth() / 2
offsety = Frame.GetHeight() / 2
Frame.SetPosition(mousepos.x + offsetx, mousepos.y + offsety)
wait()
}
I hope this helps. Please do not hesitate to contact me if you have any further queries.
Kind regards,