Click here to Skip to main content
15,898,222 members

Comments by Harold Quintero Pineda (Top 7 by date)

Harold Quintero Pineda 18-Feb-18 8:18am View    
Friend, that is the problem both the MouseDown and the MouseWheel to have the first interaction with the events of the Mouse. I tried what he said, but even if he changes the transfer origin at the first time, he still has the strange behavior when he starts.

I know that the first time the user zooms (MouseWheel) or Pan (MouseDown and MouseMove), I have to define values ​​so that the drawing (always when starting is adjusted to the size of the control and centered) moves or zooms according to That position of the Mouse, but I can not do it. I started the variables with the mouse position, also in the center of the control, but it still does not work.

Please, I know you told me that you did not receive the file, but since you have been the only kind person who has tried to help me, please implore it let me send it to you, I know that with the file it will solve it. I am Colombian, and the source code has comments in Spanish, but I know you will understand it because the variables are mostly in English.

Please, I beg of you, help me.
Harold Quintero Pineda 17-Feb-18 18:24pm View    
Magnificent, thank you for your enthusiasm in helping me, I'm really very grateful.
Have a good night.
Harold Quintero Pineda 17-Feb-18 17:22pm View    
Thank you very much for your appreciation partner.

I know that the error is in the MouseDown, because the _TraslationX_Graphics and _TraslationY_Graphics variables, always by default, are worth zero (0). Then, when pressing the ButtonLeft in the MouseDown, what it does is that the drawing is run to the origin (0,0), only how much I interact with the drawing for the first time, but later if it works.

Now, how could I take this condition into account in that MouseDown event?
Harold Quintero Pineda 17-Feb-18 12:09pm View    
Sorry, I've already uploaded the most important code to verify, because the MouseWheel event is similar, but I upload it anyway so please can you help me. I know it is difficult because it is a part of the code, but if that could help me magnificently.

I think, I'm not contemplating something in the MouseDown and MouseWheel Event.
Harold Quintero Pineda 17-Feb-18 11:50am View    
Friend, I append the code that you request.