private void UpdateRowDefinitions()
 {
     while (RowDefinitions.Count > Rows && RowDefinitions.Count > 0)
     {
         RowDefinitions.Remove(RowDefinitions[RowDefinitions.Count - 1]);
     }
     while (RowDefinitions.Count < Rows)
     {
         RowDefinitions.Add(new RowDefinition());
     }
     if (DesignerProperties.GetIsInDesignMode(this) == true)
     {
         AddDesignTimeBorders();
     }
 }