निम्नलिखित एक्सएएमएल में, "टेस्ट" शब्द क्षैतिज पर लंबवत नहीं है।मैं स्टैकपैनल के अंदर टेक्स्टबॉक्स को लंबवत रूप से कैसे संरेखित कर सकता हूं?
मैं इसे लंबवत केंद्र में कैसे प्राप्त कर सकता हूं?
alt text http://www.deviantsart.com/upload/i4i5mt.png
<Window x:Class="TestVerticalAlign2343.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
WindowStartupLocation="CenterScreen"
Title="Window1" Height="768" Width="1024">
<DockPanel LastChildFill="True">
<Slider x:Name="TheSlider"
DockPanel.Dock="Left"
Orientation="Vertical"
HorizontalAlignment="Center"
HorizontalContentAlignment="Center"
Minimum="0"
Maximum="10"
Cursor="Hand"
Value="{Binding CurrentSliderValue}"
IsDirectionReversed="True"
IsSnapToTickEnabled="True"
Margin="10 10 0 10"/>
<Border DockPanel.Dock="Right" Background="Beige"
Padding="10"
Margin="10"
CornerRadius="5">
<StackPanel Height="700">
<TextBlock
Text="Test"
HorizontalAlignment="Center"
VerticalAlignment="Center"
FontSize="200" x:Name="TheNumber"/>
</StackPanel>
</Border>
</DockPanel>
</Window>
+1 "एक स्टैकेपनेल, चाहे आप इसे कैसे फैलाते हैं, अपने बच्चों के चारों ओर पतन हो जाएंगे"। हालांकि, केवल पहले: –