Browse Source

more comments, and fix compilation error

pull/2227/head
Jeffrey Ye 8 years ago
parent
commit
27edc74bf8
  1. 2
      src/Avalonia.Visuals/Media/FontFamily.cs
  2. 2
      tests/Avalonia.Visuals.UnitTests/VisualTree/MockRenderInterface.cs

2
src/Avalonia.Visuals/Media/FontFamily.cs

@ -53,7 +53,7 @@ namespace Avalonia.Media
public static FontFamily Default => new FontFamily(String.Empty);
/// <summary>
/// Represents all font families in the system
/// Represents all font families in the system. This can be an expensive call depending on platform implementation.
/// </summary>
public static IEnumerable<FontFamily> SystemFontFamilies =>
AvaloniaLocator.Current.GetService<IPlatformRenderInterface>().InstalledFontNames.Select(name => new FontFamily(name));

2
tests/Avalonia.Visuals.UnitTests/VisualTree/MockRenderInterface.cs

@ -8,6 +8,8 @@ namespace Avalonia.Visuals.UnitTests.VisualTree
{
class MockRenderInterface : IPlatformRenderInterface
{
public IEnumerable<string> InstalledFontNames => throw new NotImplementedException();
public IFormattedTextImpl CreateFormattedText(
string text,
Typeface typeface,

Loading…
Cancel
Save