The only way I know would be to use an extension, such as Xaml Styler, which will break a Xaml onto new lines for each attribute. Other plugins exist, I'm sure, which will give you more control.
How to format xaml properties' indentations in visual studio 2013?
-
13-06-2023 - |
Question
How can I force Visual Studio 2013
to indent following code?
<Grid>
<TextBlock Margin="42"
Text="yolo"
FontSize="42">
</TextBlock>
</Grid>
Unfortunatelly CONTROL+K CONTROL+D and CONTROL+K CONTROL+F don't work...
I know that I can rewrite it to
<Grid>
<TextBlock>
<TextBlock.Margin>42</TextBlock.Margin>
<TextBlock.FontSize>42</TextBlock.FontSize>
yolo
</TextBlock>
</Grid>
but i don't want to do this this way.
Update
I can't install Xaml Styler according to @Mashton's answer, because I've got following error.
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow