如何将 Expander ToggleButton 放在右侧
默认情况下,扩展器有一个左对齐的切换按钮,但在我的 WPF 应用程序中,我希望切换按钮位于标题的右侧,而不需要 Expression Blend 的帮助。只是简单的 XAML 和/或 C#。我的扩展器包含一个垂直方向的堆栈面板,其中标签作为其子项。
我去了它的部分,但这里它说“扩展器控件确实没有任何命名零件”。
我在此处找到了一个示例。但它会覆盖默认的扩展器样式。
我认为所附图片应该传达我想要的内容。怎么办。任何链接都会有帮助。
By default the expander has a left aligned toggle button but in my WPF app i want toggle button on the right side of the header without the help of Expression Blend. just plain XAML and/or C#. My expander contains a vertically oriented stackpanel which has labels as its child.
I went for its part but here it says "The Expander control does not have any named parts".
I found an example here. But it overrides the default Expander Style.
I think the attached image should convey what i want. How to do. Any link would be helpful.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
有一个技巧可以帮助你
There is a trick that can help
使用此方法:
如果您不希望整个内容从右到左,请将您的内容添加到
TextBlock
中。Use this:
Add your content in the
TextBlock
, if you don't want to the whole content to be right to left.