void at_MouseClick(object sender, MouseEventArgs e) { this.Select(); //Id = Convert.ToInt32(at.annotationTextCount_lbl.Text); at = sender as AnnotationText; at.isActive = true; }
//public void Set_annotationComments(int cnt, string comments) //{ // this.comments = comments; // at = new AnnotationText(); // at.MouseClick += at_MouseClick; // at.Size = new Size(250, 100); // at.Dock = DockStyle.Top; // at.ID = cnt; // at.setValues(cnt, comments); // this.class11.Controls.Add(at); //} public void addControl2FLP(int cnt, string comments) { this.comments = comments; at = new AnnotationText(); at.annotation_id += at_annotation_id; at.MouseClick += at_MouseClick; if (Screen.PrimaryScreen.Bounds.Width == 1280) { at.Size = new Size(235, 75); } else if (Screen.PrimaryScreen.Bounds.Width == 1366) { at.Size = new Size(220, 60); } else if (Screen.PrimaryScreen.Bounds.Width == 1920) { at.Size = new Size(250, 50); } at.Dock = DockStyle.Top; at.ID = cnt; if (!isIdExists(at.ID)) { at.setValues(cnt, comments); this.class11.Controls.Add(at); //this.class11.Controls.SetChildIndex(at, 0); Highlight_control(); } }
public void CommentsAdded(AnnotationText c) { if (this.ShowComments) { EventArgs e = null; _commentsAddedEvent(c, e); } }
public void addControl2FLP(int cnt, string comments) { this.comments = comments; at = new AnnotationText(); at.MouseClick += at_MouseClick; at.Size = new Size(120, 45); at.Dock = DockStyle.Top; at.ID = cnt; //at.isActive = false; at.BackColor = Color.Black; at.setValues(cnt, comments); this.annotationFlowLayout1.Controls.Add(at); //this.annotationFlowLayout1.Controls.SetChildIndex(at, 0); }
public override void OnMouseUp(DrawArea drawArea, MouseEventArgs e) { c = new AnnotationText(); //this if condition has been added by darshan to resolve defect no 0000539. if (drawArea.ListGraphics.Count > 0) { for (int i = 0; i < drawArea.ListGraphics.Count; i++) { //if (drawArea.ListGraphics[i] is DrawLine) if (drawArea.ListGraphics[i].GetType().ToString().Equals("Annotation.DrawLine")) { } else { idVal = drawArea.ListGraphics.ids.ElementAtOrDefault(i); if (idVal != 0) { c.ID = drawArea.ListGraphics.ids[i]; drawArea.ListGraphics[0].Normalize(); drawArea.CommentsAdded(c); } } } //c.Dock = DockStyle.Top; //c.SetBounds(c.Location.X, c.Location.Y, c.Width, c.Height); //} drawArea.ActiveTool = DrawArea.DrawToolType.Pointer; //drawArea.Capture = false; //annotationPanel.Location = drawArea.active_point; //c.ac.X = annotationPanel.Location.X; //c.ac.Y = annotationPanel.Location.Y; //c.Show(); //drawArea.comments.Add(c.ac); drawArea.Refresh(); } //drawArea.Refresh(); }
public void AddAnnotationText(AnnotationText c) { //this.flowLayoutPanel1.Controls.Add(c); }