سلام 😉 در این پست آموزش استفاده از Span های تو در تو (Nested Span) برای تغییر بخشی از متن با wpf و سی شارپ #C را آماده کردم. امیدوارم که این کد برای شما مفید باشد.
کد استفاده از Span های تو در تو (Nested Span) برای تغییر بخشی از متن با wpf و سی شارپ #C :
<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
HorizontalAlignment="Center" VerticalAlignment="Center">
<TextBlock>
<Span FontFamily="Cambria">
This uses <Span FontWeight="Bold">a
<Span FontStyle="Italic">mixture</Span> of</Span> styles.
</Span>
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
HorizontalAlignment="Center" VerticalAlignment="Center">
<TextBlock>
<Span FontFamily="Cambria">
This uses <Span FontWeight="Bold">a
<Span FontStyle="Italic">mixture</Span> of</Span> styles.
</Span>