VintaSoft Imaging .NET SDK 10.0
In This Topic
    Build and transform annotations in WPF
    In This Topic

    The WpfAnnotationVisualTool allows the user to build or transform annotation in WpfAnnotationViewer. The building of annotation is performed by annotation builder, the transformation of annotation is performed by annotation transformer. The visual tool gets information about builder and transformer from WpfAnnotationView class:

    Build annotation in WPF annotation viewer

    For newly created annotation the value of WpfAnnotationView.InteractionController property is equal to the value of WpfAnnotationView.Builder property, i.e. annotation is ready for building.
    The WpfAnnotationVisualTool.AddAndBuildAnnotation method allows to start the annotation building process, i.e. method adds the annotation into the annotation collection of focused image, gets the current interaction controller (builder) using WpfAnnotationView.InteractionController property and starts the building of annotation.
    For annotation building can be used the following interaction controllers (builders):

    Transform annotation in WPF annotation viewer

    Transformation of annotation, which is focused in WpfAnnotationViewer, can be started using mouse. For annotation transformation can be used the following interactive controllers:

    Transform annotation using several controllers

    The WpfCompositeInteractionController class allows to combine several interactive controllers.

    For example, WpfFreeTextAnnotationView uses composite interaction controller because WpfFreeTextAnnotationView consists from 2 annotations (WpfTextAnnotationView and WpfLeaderLineAnnotationView) and needs to interact with both annotations using different interactive controllers: