VintaSoft Annotation .NET Plug-in Discussions
Questions, comments and suggestions concerning VintaSoft Annotation .NET Plug-in.
Board index < VintaSoft Imaging < VintaSoft Annotation .NET Plug-in Discussions
private void AnnotationTool_MouseClick(object sender, VisualToolMouseEventArgs e)
{
AnnotationVisualTool sAnnotationVisualTool = (AnnotationVisualTool)sender;
//Point mp = sAnnotationVisualTool.ImageViewer.PointToImage(Control.MousePosition);
if (e.Button == MouseButtons.Right)
{
AnnotationViewer.AnnotationInteractionMode = AnnotationInteractionMode.Author;
try
{
Point objPoint = new Point(e.X, e.Y);
ReferencedImageAnnotationData objReferencedImageAnnotationData = new ReferencedImageAnnotationData();
objReferencedImageAnnotationData.Image.SetImage(BitmapToVintasoftImage(global::Advantmed.RiskAdjustment.Application.Properties.Resources.AnnotationDot_Green));
objReferencedImageAnnotationData.CreatedBy = Convert.ToString(NLPDataID);
objReferencedImageAnnotationData.ModifiedBy = Convert.ToString(PageAnnotation);
objReferencedImageAnnotationData.Name = "";
objReferencedImageAnnotationData.Intent = strDiagnosis;
objReferencedImageAnnotationData.Size = new SizeF((DotWidth / 2), (DotHeight / 2));
objReferencedImageAnnotationData.Location = AnnotationViewer.PointFromControlToDip(objPoint);
objReferencedImageAnnotationData.Border = false;
objReferencedImageAnnotationData.CanMirror = false;
objReferencedImageAnnotationData.CanResize = false;
objReferencedImageAnnotationData.CanRotate = false;
objReferencedImageAnnotationData.CanMove = true;
if (objReferencedImageAnnotationData != null)
{
AnnotationViewer.AddAndBuildAnnotation(objReferencedImageAnnotationData);
}
AnnotationViewer.FinishAnnotationBuilding();
}
}
}