khalidabuhakmeh / ConsoleTables

Print out a nicely formatted table in a console application C#
MIT License
944 stars 157 forks source link

Table will went wrong if some chars' width is two. (如果某些字符的宽度是2, 表格将出错) #55

Closed SlimeNull closed 1 year ago

SlimeNull commented 3 years ago

image image

English: Clearly, if a char which width is two, this current row will move right... Also, if you want to calculate the width of a string in the console, see this repository: Null.ConsoleEx

using namspace Null.ConsoleEx, and call this method: ConsoleEx.GetStringDisplayLength(string str);

Chinese : 下面是中文: 显然, 如果一个字符的宽度是2, 当前的这一行就会向右移动... 对了, 如果你想计算字符串在控制台中的宽度, 看看这个仓库吧: Null.ConsoleEx using Null.ConsoleEx 命名空间, 然后调用这个方法: ConsoleEx.GetStringDisplayLength(string str);

telecomadm1145 commented 3 years ago

哈哈哈Null你跑这里来干啥[滑稽]

telecomadm1145 commented 3 years ago

还有并不是宽度是2,而是其他字符(的宽度)是ASCII字符的宽度的两倍

telecomadm1145 commented 3 years ago

这个其实和Windows的字体渲染有点关系

telecomadm1145 commented 3 years ago

很多软件也有这种问题

telecomadm1145 commented 3 years ago

比如ssh(貌似是ash的问题)

telecomadm1145 commented 3 years ago

还有如果你有解决方案应该fork代码然后建立一个Pull Request

telecomadm1145 commented 3 years ago

发一个Issue基本没法解决问题

SlimeNull commented 3 years ago

没办法解决就不解决了, 反正这个我用不到

Linlccc commented 3 years ago

At present, the problem is that the table will be deformed by inputting some characters

khalidabuhakmeh commented 1 year ago

I believe the latest release 2.5.0 addresses this issue.