HI,
"Need to provide Label Property for the RibbonTextBox control to display the label and property to mention the position of label" is an adequate description.
Please note that the actual layout for having the label horizontal was a little more complicated than the vertical option and I needed to set both the stackpanel orientation as well as the VerticalAlignment and padding on the textblock in order for it to look consistent. You might then want to expose LabelVerticalAlignment and LabelPadding as additional properties.
for Horizontal:
<StackPanel Orientation="Horizontal" >
<TextBlock
Padding="0, 0, 5, 0"
VerticalAlignment="Center"
HorizontalAlignment="{Binding Path=(local:RibonTextBoxWithLabel.LabelHorizontalAlignment), RelativeSource={RelativeSource Mode=TemplatedParent}}"
Text="{Binding Path=(local:RibonTextBoxWithLabel.Label), RelativeSource={RelativeSource Mode=TemplatedParent}}" />
<Border
x:Name="Bd"
Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
Width="{TemplateBinding Width}"
SnapsToDevicePixels="true">
<ScrollViewer x:Name="PART_ContentHost" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
</Border>
</StackPanel>
Thanks and Best Regards,
Adam