void _label_Move(object sender, EventArgs e)
 {
     _label.SaveLocation();
     _label.SaveRelativePosition();
     if (XmlData != null)
     {
         XmlSerialization.WriteToUniqueChildXmlNode(_writer, XmlData, XML_LABEL, _label);
     }
     VplDesigner.Changed = true;
 }
Esempio n. 2
0
 public void AdjustLabelPosition()
 {
     if (_label != null)
     {
         if (_label.Top > this.Top + this.Height)
         {
             _label.Left = this.Left;
         }
         else if (_label.Top < this.Top - _label.Height)
         {
             _label.Left = this.Left;
         }
         else if (_label.Left > this.Left + this.Width)
         {
             _label.Left = this.Left + this.Width;
         }
         else
         {
             _label.Left = this.Left - _label.Width;
         }
         _label.SaveLocation();
         _label.SaveRelativePosition();
     }
 }