Make Run's BaselineAlignment set globally

This commit is contained in:
Tyrrrz
2026-02-27 18:31:40 +02:00
parent 675d910ea3
commit 951c1e4613
3 changed files with 63 additions and 65 deletions

View File

@@ -33,10 +33,7 @@ public class MarkdownToInlinesConverter : IValueConverter
{
case LiteralInline literal:
{
var run = new Run(literal.Content.ToString())
{
BaselineAlignment = BaselineAlignment.Center,
};
var run = new Run(literal.Content.ToString());
if (fontWeight is not null)
run.FontWeight = fontWeight.Value;
@@ -142,9 +139,7 @@ public class MarkdownToInlinesConverter : IValueConverter
var prefix = list.IsOrdered ? $"{itemOrder++}. " : $"{list.BulletType} ";
inlines.Add(
new Run(prefix) { BaselineAlignment = BaselineAlignment.Center }
);
inlines.Add(new Run(prefix));
foreach (var subBlock in listItem.OfType<ParagraphBlock>())
{