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

Upgrading from DotImage 4.0 to 5.0

Last post 21 Feb 2008, 1:28 PM by Glenn. 2 replies.
Sort Posts: Previous Next
  •  21 Feb 2008, 11:45 AM 13291

    Upgrading from DotImage 4.0 to 5.0

    We've finally got around to upgrading from version 4.0 to 5.0, but we'd forgotten that you have changed the Annotations. Please can we have a little more guidance to modifying our code than:

    If your application only uses the built-in annotation objects, the changes required will be minor.  For instance, the annotation classes have been moved to a different namespace (Atalasoft.Annotate.UI).  We've also changed from using .NET Pen, Brush, Font and Image classes to our own more generic classes, so constructor arguments and property settings will need to be modified.

    We don't have custom annotations, but we do have a number of generic routines. For example how can I convert the following:

    public void AddAnnotation(Annotation annotation)
    {
      imageViewer.Annotations.CurrentLayer.Add(annotation);
      imageViewer.Update();
    }

    I've tried replacing Annotation with AnnotationData, but I see it's not as simple as that. What is the base Annotation class now? AnnotationData or AnnotationUI? something else?

    Quite frankly we're shocked at the amount of change that has gone on here without any backward compatibility, and it's looking like we'll stick with version 4 forever more.

    Not amused.


     

  •  21 Feb 2008, 12:08 PM 13292 in reply to 13291

    Re: Upgrading from DotImage 4.0 to 5.0

    Here are just a few of the issues we're having, just getting the thing to compile:

    Where have the following properties on the AnnotationController gone to: IncludeXmpInWang, MirrorOnResize, ShowWhileMoving, ShowWhileResizing

    There's no Tag on either AnnotationUI or AnnotationData - we use this to reference our database record for the annotation.

    Where are Annotation.Lock or Annotation.Unlock gone to (ignoring the fact for the minute that Annotation has gone.)

     

  •  21 Feb 2008, 1:28 PM 13294 in reply to 13292

    Re: Upgrading from DotImage 4.0 to 5.0

    The AnnotationData class is the base class for the data portion of annotations.  AnnotationUI is the base class for the top-most level of annotations and is normally the class you will access directly.  For instance, when you create a RectangleAnnotation, you are creating an AnanotationUI object.

    IncludeXmpInWang was removed because this turned out to be a bad idea.  Some viewers were having problems reading the WANG data because of this extra information.  Our WangFormatter class now only generates standard WANG data.

    ShowWhileMoving and ShowWhileResizing were removed because of the redesign.  Annotations are now always fully drawn when moving and resizing.

    MirrorOnResize can be controlled by setting the CanMirror property of the annotation objects.  This way each annotation's behavior can be controlled.

    The Tag property was removed because of serialization changes.  You will either have to keep track in a Hashtable or Array, or create classes that derive from our annotations and add the additional properties you need.

    The Lock and Unlock methods were moved to the AnnotationUI.Data.Security property.  You can now create your own security protocol for annotations or use our default AnnotationLock class.

     


    Glenn Chittenden Jr.
    Atalasoft Development Team
View as RSS news feed in XML