WPF FlowDocument use to achieve photo-text

Code:

<RichTextBox CaretBrush="#fff" Background="Transparent" BorderThickness="0">
    <FlowDocument FontSize="16" Foreground="#fff">
        <Paragraph LineHeight="22">
            <Run Text="{Binding Name}"></Run>
            <Image Height="16" Width="32" Stretch="Fill" Source="/SunCreate.Vipf.Client.Resources;component/Image/MainPage/重要.png" />
        </Paragraph>
    </FlowDocument>
</RichTextBox>
View Code

Renderings:

 

Guess you like

Origin www.cnblogs.com/s0611163/p/11354005.html