开发者

Is there a way to set LineHeight in a Silverlight 4 RichTextBox?

开发者 https://www.devze.com 2022-12-27 05:14 出处:网络
The TextBlock control ha开发者_如何学JAVAs LineHeight. Does anyone know a good way to set LineHeight in the RichTextBox Control in Silverlight 4?Hack: This seems to cause all the lines (even when wrap

The TextBlock control ha开发者_如何学JAVAs LineHeight. Does anyone know a good way to set LineHeight in the RichTextBox Control in Silverlight 4?


Hack: This seems to cause all the lines (even when wrapped) to be the height that FontSize 26 would cause.

Run run = new Run();

run.FontSize = 26;

run.Text = "";

Par.Inlines.Add(run);

run = new Run();

run.Text = "long text here...";

run.FontSize = 12;

Par.Inlines.Add(run);

0

精彩评论

暂无评论...
验证码 换一张
取 消