Atalasoft
Welcome to Atalasoft Community Sign in | Join | Help
in

Annotation Confinement

Last post 14 Feb 2008, 9:50 AM by AndyB. 2 replies.
Sort Posts: Previous Next
  •  13 Feb 2008, 11:42 AM 13199

    Annotation Confinement

    We are having a bit of trouble with the annotation confinement feature in dotAnnotate 5.0g. It quickly became obvious that by allowing our users to have unlimited abilities to drag annotations around, we were going to run into problems with annotations becoming inaccessible in the client areas of the viewer. As a resolution to this problem, we set the AnnotationConfinement property to keep annotations within the bounds of the document area.

    This has now solved the problem, but has potentially exposed another problem as a result. If we move an annotation in our viewer (either a newly created annotation or an existing one), and try to drag it outside the bounds of the document, the annotation stops at the edge but the mouse carries on into the grey client area. If the mouse button is released whilst the annotation is in this area, the annotation remains on the edge of the document as expected. However the AnnotationMoved() event isn't triggered in response, even though the annotation has moved from it's origin. If the document is closed and re-opened (which saves the annotations in their last-known positions), upon re-opening the dragged annotation has returned to it's original location prior to being dragged to the edge of the document.

    Our VB.NET program is a follow-on from an existing VB6 program, and because dotAnnotate won't function with this we've had to devise a way to generate a file of annotation positions and properties that can be interpretted by both applications for backwards compatibility. As a result we have a number of objects in .NET which are continuously updated by the triggering of the various events. Due to the AnnotationMoved event not being triggered, the objects aren't being updated and therefore when the image is reloaded, any annotations which were dragged to the edge of the screen have suddenly reverted back to their original locations.

    Could you shed any light on this please?

    Thanks.

  •  13 Feb 2008, 3:20 PM 13206 in reply to 13199

    Re: Annotation Confinement

    Looks like a bug.  It's written so if the mouse is released outside of the confined bounds it doesn't raise the event, but it still should if the position has changed.

    I'll log it to be fixed in the next update.


    Glenn Chittenden Jr.
    Atalasoft Development Team
  •  14 Feb 2008, 9:50 AM 13217 in reply to 13206

    Re: Annotation Confinement

    Thanks for your help on that Glenn.

    I thought there was something funny going on with this one. It makes sense for the event not to fire if you are over the client area but not the document area. However as in this case, an annotation has physically moved prior to this occurring, so the event should fire in this instance.

    We'll see if we can work around it until a fix comes along.

    Thanks.

View as RSS news feed in XML