cowsay-python
cowsay-python copied to clipboard
Full-width characters compatibility and `max_width` adjustability
Since Chinese characters are full-width (twice larger than half-width characters, e.g., ASCII characters), the previous version break lines corresponding to the length of a string but not the true width of the string. I tried to modified it so it can determine when to break lines correctly.
Also, I want to adjust the value of max_width (default 49 characters). I simply add this argument for each functions so that I can adjust its value.