WPF 文本换行与 WrapWithOverflow [英] WPF text Wrap vs WrapWithOverflow
问题描述
TextWrapping="Wrap"
和 TextWrapping="WrapWithOverflow"
之间的概念"区别是什么(例如对于 TextBox)?在关于 TextBox 类的 MSDN 页面中,没有什么......谢谢.
What's the "conceptual" difference between TextWrapping="Wrap"
and TextWrapping="WrapWithOverflow"
(e.g. for a TextBox)?
In the MSDN page about the class TextBox there is nothing ...
Thank you.
推荐答案
WrapWithOverflow 如果行溢出超出范围,则会发生换行可用的块宽度.但是,一行可能会溢出如果换行算法无法确定一条线,则块宽度打破机会,就像一个很长的词被限制在一个不允许滚动的固定宽度容器.
NoWrap 无行执行包装.
Wrap 如果换行,则会发生换行溢出超出可用块宽度,即使标准行换行算法无法确定任何换行机会,如一个很长的词被限制在一个固定宽度的容器中的情况不允许滚动.
WrapWithOverflow Line-breaking occurs if the line overflows beyond the available block width. However, a line may overflow beyond the block width if the line breaking algorithm cannot determine a line break opportunity, as in the case of a very long word constrained in a fixed-width container with no scrolling allowed.
NoWrap No line wrapping is performed.
Wrap Line-breaking occurs if the line overflows beyond the available block width, even if the standard line breaking algorithm cannot determine any line break opportunity, as in the case of a very long word constrained in a fixed-width container with no scrolling allowed.
希望能帮到你
这篇关于WPF 文本换行与 WrapWithOverflow的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!