Interactive way to draw rectangle

PDF-XChange Editor SDK for Developers

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Post Reply
leemingxian
User
Posts: 14
Joined: Wed Oct 23, 2019 3:49 am

Interactive way to draw rectangle

Post by leemingxian »

Hi,
I am trying to do a similar function like the rectangle annotations in the PDF editor
I have search through the forum and also the SDKHelper, but I am only able to find the way to add the rectangle by defining the left, right, top, and left for the rectangle.
is there anywhere that allow me to define those information by obtaining mouse position?

Any help is appreciated. Thank you.
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Interactive way to draw rectangle

Post by Sasha - Tracker Dev Team »

Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
leemingxian
User
Posts: 14
Joined: Wed Oct 23, 2019 3:49 am

Re: Interactive way to draw rectangle

Post by leemingxian »

Hi Alex,
Sorry for taking so long to response
Now I am able to draw a rectangle on the PDF
However I'm kinda stuck when try to working on code to allow resize of rectangle (I mean interactively, just like the Editor allow to)
Any ideas on this?
Thanks for your reply
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Interactive way to draw rectangle

Post by Sasha - Tracker Dev Team »

Hello leemingxian,

Do you want to add a rectangle as a content item?

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
leemingxian
User
Posts: 14
Joined: Wed Oct 23, 2019 3:49 am

Re: Interactive way to draw rectangle

Post by leemingxian »

No
Actually I want to achieve something just like the "Rectangle" tools that available in the Editor
By using a custom button
Is that possible?
leemingxian
User
Posts: 14
Joined: Wed Oct 23, 2019 3:49 am

Re: Interactive way to draw rectangle

Post by leemingxian »

Hi Alex,
I have already figure out previous problem
Is there any way for me to get current Cursor information (cursor ID etc.)?

PS: I have found the solution for this question
https://sdkhelp.pdf-xchange.com/vi ... iew_Cursor

I will come back if I meet other problems
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Interactive way to draw rectangle

Post by Sasha - Tracker Dev Team »

:)
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Post Reply