I am develop an UWP app, and I am using Template10.
I have an TextBlock
, that in VisualStateNarrow
I want it RelativePanel.AlignVerticalCenterWit
For attached properties you have to add brackets to in setters as follows:
Element.(Grid.Row)
Element.(ToolTipService.ToolTip)
So your code will look like this:
<Setter Target="TextBlock.(RelativePanel.AlignVerticalCenterWithPanel)" Value="True" />
Here is a way to create setters for adaptive triggers without writing a single line of code. Since VS provides neither IntelliSense nor error warning for writting them, this helps prevent bugs that are hard to diagnose.
TextBlock
element.That's all! Feel free to check out the gif demo below too.