Skip to content

Commit

Permalink
Merge commit '137568a7c94b93f991ead438940a1b2c530fa12b' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
lindexi committed Oct 7, 2023
2 parents 13c92e0 + 137568a commit 0a52cb2
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public partial class MainWindow : Window
public MainWindow()
{
InitializeComponent();
var file = "f:\\temp\\汉仪文黑-85W.ttf";
var file = "f:\\temp\\hw.ttf";

PrivateFontCollection collection = new PrivateFontCollection();
collection.AddFontFile(file);
Expand All @@ -33,8 +33,8 @@ public MainWindow()
}

var uri = new Uri(file);
FontFamily fontFamily = new FontFamily(uri, "汉仪文黑-85W");
//TextBlock.FontFamily = fontFamily;
FontFamily fontFamily = new FontFamily(uri, "hw");
TextBlock.FontFamily = fontFamily;
TextBlock.FontWeight = FontWeight.FromOpenTypeWeight(485);
Loaded += MainWindow_Loaded;
}
Expand Down

0 comments on commit 0a52cb2

Please sign in to comment.