A color object that defines the required color of the newly added line arrow annotation. It corresponds to the AnnotationLineArrow.StrokeColor property.
The width of the newly added line arrow annotation, in inches. This value defines the width of the line and it corresponds to the AnnotationLineArrow.BorderWidth property.
The width of the arrow, in inches. This value only defines the width of the very arrow on the end of the line.
The height of the arrow, in inches. This value only defines the height of the very arrow on the end of the line.
Specifies the look of the arrowhead. Set this parameter to true to depict a sharp arrowhead. Set it to false to paint a rounded arrowhead.
The opacity value of the newly added line arrow annotation, from 0 (full transparency) to 1 (full opacity).
Specifies if the starting and ending points of the line arrow are inverted during drawing. Set this parameter to true if you want to paint an arrowhead straightway on the starting point of the line. Otherwise, set it to false.
Example





In This Topic
GdPicture14.WPF Namespace / GdViewer Class / AddLineArrowAnnotInteractive Method

AddLineArrowAnnotInteractive Method (GdViewer)

In This Topic
Allows users to interactively add a new line arrow annotation using the mouse on the current page of the document displayed in the GdViewer control. The annotation object is added following all the parameters you have specified and respecting the dimensions users will define using the mouse as well.

This annotation depicts a straight line with an arrow on one of its ending points. Using this method you can specify if the arrowhead is painted when users start the line or when they finish it.

The type of the newly added annotation object is GdPictureAnnotationType.AnnotationTypeLineArrow. You can change the annotation properties directly using the GdPicture14.Annotations.AnnotationLineArrow class before or after the successful creation of the annotation object. Please refer to both the BeforeAnnotationAddedByUser and the AnnotationAddedByUser events, respectively to both the PreviewBeforeAnnotationAddedByUser and the PreviewAnnotationAddedByUser events, for how to achieve this.

Be aware that the editing mode for annotations must be enabled using the SetAnnotationEditorMode method, otherwise this method will fail.

Syntax
'Declaration
 
Public Sub AddLineArrowAnnotInteractive( _
   ByVal BorderColor As Color, _
   ByVal BorderWidth As Single, _
   ByVal ArrowWidth As Single, _
   ByVal ArrowHeight As Single, _
   ByVal ArrowFilled As Boolean, _
   ByVal Opacity As Single, _
   ByVal Reversed As Boolean _
) 
public void AddLineArrowAnnotInteractive( 
   Color BorderColor,
   float BorderWidth,
   float ArrowWidth,
   float ArrowHeight,
   bool ArrowFilled,
   float Opacity,
   bool Reversed
)
public procedure AddLineArrowAnnotInteractive( 
    BorderColor: Color;
    BorderWidth: Single;
    ArrowWidth: Single;
    ArrowHeight: Single;
    ArrowFilled: Boolean;
    Opacity: Single;
    Reversed: Boolean
); 
public function AddLineArrowAnnotInteractive( 
   BorderColor : Color,
   BorderWidth : float,
   ArrowWidth : float,
   ArrowHeight : float,
   ArrowFilled : boolean,
   Opacity : float,
   Reversed : boolean
);
public: void AddLineArrowAnnotInteractive( 
   Color BorderColor,
   float BorderWidth,
   float ArrowWidth,
   float ArrowHeight,
   bool ArrowFilled,
   float Opacity,
   bool Reversed
) 
public:
void AddLineArrowAnnotInteractive( 
   Color BorderColor,
   float BorderWidth,
   float ArrowWidth,
   float ArrowHeight,
   bool ArrowFilled,
   float Opacity,
   bool Reversed
) 

Parameters

BorderColor
A color object that defines the required color of the newly added line arrow annotation. It corresponds to the AnnotationLineArrow.StrokeColor property.
BorderWidth
The width of the newly added line arrow annotation, in inches. This value defines the width of the line and it corresponds to the AnnotationLineArrow.BorderWidth property.
ArrowWidth
The width of the arrow, in inches. This value only defines the width of the very arrow on the end of the line.
ArrowHeight
The height of the arrow, in inches. This value only defines the height of the very arrow on the end of the line.
ArrowFilled
Specifies the look of the arrowhead. Set this parameter to true to depict a sharp arrowhead. Set it to false to paint a rounded arrowhead.
Opacity
The opacity value of the newly added line arrow annotation, from 0 (full transparency) to 1 (full opacity).
Reversed
Specifies if the starting and ending points of the line arrow are inverted during drawing. Set this parameter to true if you want to paint an arrowhead straightway on the starting point of the line. Otherwise, set it to false.
Remarks
The GetStat method can be subsequently used to determine if this method has been successful. If the editing mode for annotations is disabled, the method will fail.
Example
How to allow users to interactively add a line arrow annotation on the currently displayed page.
'We assume that the GdViewer1 control has been properly integrated.
Sub buttonAddLineArrow_Click(ByVal sender As Object, ByVal e As EventArgs)
    GdViewer1.AddLineArrowAnnotInteractive(Color.FromArgb(255, 138, 43, 226), 0.1F, 2, 5, True, 1, True)
    If GdViewer1.GetStat() <> GdPictureStatus.OK Then MessageBox.Show("Error!  Status: " + GdViewer1.GetStat().ToString(), "AddLineArrowAnnotInteractive")
End Sub
//We assume that the GdViewer1 control has been properly integrated.
void buttonAddLineArrow_Click(object sender, EventArgs e)
{
    GdViewer1.AddLineArrowAnnotInteractive(Color.FromArgb(255, 138, 43, 226), 0.1f, 2, 5, true, 1, true);
    if (GdViewer1.GetStat() != GdPictureStatus.OK) MessageBox.Show("Error!  Status: " + GdViewer1.GetStat().ToString(), "AddLineArrowAnnotInteractive");
}
See Also