如何在StatusStrip中正确对齐控件? [英] How do I right align controls in a StatusStrip?
问题描述
我试图在 StatusStrip
.我该怎么办?
I am trying to right align a control in a StatusStrip
. How can I do that?
我没有看到要在ToolStripItem
控件上设置的属性,该属性指定它们在父StatusStrip
上的物理对齐方式.
I don't see a property to set on ToolStripItem
controls that specifies their physical alignment on the parent StatusStrip
.
如何使消息下拉至正确对齐的位置? http://i.friendfeed.com/ed90b205f64099687db30553daa79d075f280b90
推荐答案
发布后几乎立即通过MSDN论坛找到它:)
Found it via MSDN forums almost immediately after posting :)
您可以使用 ToolStripLabel
通过将Text
属性设置为string.Empty
并将Spring
属性设置为true
来伪右对齐控件.这将使其填充所有可用空间,并将所有控件推到 ToolStripLabel
结束.
You can use a ToolStripLabel
to pseudo right align controls by setting the Text
property to string.Empty
and setting the Spring
property to true
. This will cause it to fill all of the available space and push all the controls to the right of the ToolStripLabel
over.
这篇关于如何在StatusStrip中正确对齐控件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!