-
Notifications
You must be signed in to change notification settings - Fork 72
Description
Describe the bug
Default mono-space font is not mono-space, especially noticeable when using non-ASCII characters
To Reproduce
Steps to reproduce the behavior:
- Write a
/tmp/test.md
file with the following content
┏━━━━━━━━━━━━━━━┓
┃ If you have to ask the price ┃
┃ then you cannot afford ┃
┃ Special Hugs ┃
┗━━━━━━━━━━━━━━━┛
- Use
freeze /tmp/test.md
- Preview with
okular freeze.png
- Notice how things almost line-up, but don't
Expected behavior
I expect something like the following input to be mono-spaced, in Vim (I use Vim BTW™), and on GitHub;
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ If you have to ask the price ┃
┃ then you cannot afford ┃
┃ Special Hugs ┃
┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
... but it seems even The GitHubs no likes to mono-space 0x2501
characters :-\
Screenshots
If applicable, add screenshots to help explain your problem.
Example of Freeze output given first given input
Example of Vim display with second example input
Desktop (please complete the following information):
- OS: GNU Linux (Arch BTW™)
- Browser "Wat?!"
- Version
freeze version v0.2.2 (80921ba)
Smartphone (please complete the following information):
Not Applicable
Additional context
Not Applicable
Update -- 2025-05-24
Found a work-around!
-
Find mono-space fonts available on system
fc-list | sort -u | grep -i mono
-
Mess about to find something that really is mono-space by defining it in configs
~/.config/freeze/user.json
(snip){ "font": { "family": "Liberation Mono", "file": "/usr/share/fonts/liberation/LiberationMono-Regular.ttf", "size": 14, "ligatures": false } }
-
Explicitly use config
freeze -c ~/.config/freeze/user.json -l markdown <<'EOF' ``` ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓ ┃ If you have to ask the price ┃ ┃ then you cannot afford ┃ ┃ Special Hugs ┃ ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛ ``` EOF
While this doesn't resolve the issue of freeze
default mono-space font not being mono-space, nor will it work on systems without alternative fonts to chose from, but hopefully this Issue will help anyone else struggling with making questionable usage choices x-)