public void AsString_should_persist_font_with_styles(FontStyle fontStyle, string serialised) { using (var font = new Font("Arial", 9, fontStyle)) { font.AsString().Should().Be(serialised); } }
private static void SafeSet(string key, Font value, ref Font field) { field = value; SetValue(key, field.AsString()); }
public void SetFont(string name, Font value) { string?stringValue = value.AsString(); SetValue(name, stringValue); }