ravachol / kew

A command-line music player
GNU General Public License v2.0
567 stars 21 forks source link

[Bug] Terminal resize messes up the song's names #122

Closed xplshn closed 6 months ago

xplshn commented 6 months ago

2024-02-12-204555_1366x768_scrot This happens when the song's names are bigger than the terminal's reported width., I propose that kew subtracts the left over characters that can't be displayed - 1 and adds '…' to the end of the string. Note that '…' is a UTF8 char.

https://unicode.scarfboy.com/?s=%E2%80%A6 ; Lookup of the Unicode character.

ravachol commented 6 months ago

It's not subtracting enough when files are directly under the first folder like that.

xplshn commented 6 months ago

I don't know, that's how I do it in my program, I have a function to print lines, which automagically checks which characters would get excluded and also if it ends in a comma or dot, it removes the characters before adding the special Ellipsis character.