/// <summary> /// Writes the attribute. /// </summary> /// <param name="name">The name.</param> /// <param name="value">The value.</param> /// <param name="defaultValue">The default value.</param> protected void WriteAttribute(string name, GridLength value, GridLength defaultValue) { if (this.settings.WriteDefaultValues || !value.Equals(defaultValue)) { this.writer.WriteAttributeString(name, value.Format()); } }