我想打印这样的数据:
http://www.csharp-examples.net/align-string-with-spaces/
------------------------------- Bi1l | Gates | 51 EdnA | Parker | 114 JohNny | Depp | 44 -------------------------------
我尝试使用上面的例子,PadRight以及PadLeft更多的长度计算,我总是得到这种类型的输出(我的输出转到a TextBox)
------------------------------- Bill | Gates | 51 Edna | Parker | 114 Johnny | Depp | 44 -------------------------------
对于我的想法,它发生是因为WPF不为每个字符提供固定和相等的块,因此W占用更多的空间i,并使分离看起来很糟糕.
有人可以帮我解决问题吗?