Edit inside tag

Questions, comments and suggestions concerning VintaSoft Imaging .NET SDK.

Moderator: Alex

Post Reply
rstrickland1958
Posts: 10
Joined: Mon Oct 30, 2017 11:16 pm

Edit inside tag

Post by rstrickland1958 »

For the annotation tags that the user can edit inside, the user has to first click on the tag to open the edit area. Is there any way for the tag to open directly in edit mode after the user places the tag on the viewer?
Alex
Site Admin
Posts: 2304
Joined: Thu Jul 10, 2008 2:21 pm

Re: Edit inside tag

Post by Alex »

Hello,

I am not sure I have understood your question. You are editing the annotation properties using the property grid and now you want to edit annotation properties programmatically. Am I right?

Please read information about annotations in the documentation: https://www.vintasoft.com/docs/vsimagin ... ction.html

and let me know if you will have any question or problem.

Best regards, Alexander
rstrickland1958
Posts: 10
Joined: Mon Oct 30, 2017 11:16 pm

Re: Edit inside tag

Post by rstrickland1958 »

Sorry for the confusion.

I select an annotation that allows text and place the annotation on the viewer. Based on how I have use this type of annotation, I have to double click on the annotation to open up edit region that allows me to enter my text. I then click outside this edit region to close the region and update the annotation. I need for the edit region to come up without having to double click with the mouse on the annotation. I was going to see if there is a key sequence from the keyboard that will do this or if there is a property for the annotation that automatically opens the edit region.
Alex
Site Admin
Posts: 2304
Joined: Thu Jul 10, 2008 2:21 pm

Re: Edit inside tag

Post by Alex »

Hello,

Here is code snippet that shows how to specify that one mouse click must be used for activating the text box of text annotation:

Code: Select all

/// <summary>
/// Determines that one mouse click must be used for activating the text box of text annotation.
/// </summary>
/// <param name="textAnnotationView">Text annotation.</param>
public void UseOneMouseClickForActivatingTextAnnotationTexBox(
    Vintasoft.Imaging.Annotation.UI.TextAnnotationView textAnnotationView)
{
    // get the rectangular transformer for text annotation from text annotation
    Vintasoft.Imaging.Annotation.UI.VisualTools.UserInteraction.RectangularTextAnnotationTransformer rectangularTextAnnotationTransformer =
        textAnnotationView.TextTransformer;
    // get the text box transformer from the rectangular transformer for text annotation
    Vintasoft.Imaging.UI.VisualTools.UserInteraction.TextObjectTextBoxTransformer textObjectTextBoxTransformer =
        rectangularTextAnnotationTransformer.TextBoxTransformer;
    // specify that text box must be shown when user clicked on text annotation
    textObjectTextBoxTransformer.ActivateClickCount = 1;
}
More info about the text box transfomer please see in the TextObjectTextBoxTransformer class:
https://www.vintasoft.com/docs/vsimagin ... ormer.html

Best regards, Alexander
Post Reply