Subject: Monospace font rendering

From: amc252 <[email-masked]>
Date: Thu, 9 Dec 2021 16:37:08 -0800

Hello,
I'm quite new to Alpine, still learning the ropes.
I have noticed that monospace fonts rendering (I use Trelby word processor) in Alpine is not so good as the Devuan system I use on the same laptop.
Both Alpine and Devuan are set up the same way.
I installed:
setup-xorg-base xorg-server xf86-video-intel ttf-dejavu 
While the difference is not dramatic, it is still noticeable.
I took some screenshots, but they do not show the differences I see in normal use.
I'd like some advice as to how I could troubleshoot the issue.

---

From: Paul Bredbury <[email-masked]>
Date: Fri, 10 Dec 2021 10:40:41 +0000

Common differences are the DPI being used, e.g.:

$ xdpyinfo | grep -B1 dot
dimensions: 1920x1080 pixels (443x249 millimeters)
resolution: 110x110 dots per inch

... and the fontconfig settings in e.g. /etc/fonts/conf.d/

---

From: amc252 <[email-masked]>
Date: Fri, 10 Dec 2021 09:07:37 -0800

Paul.
Thanks for your answer.
These are the outputs of the command you suggested and the contains of /etc/fonts/conf.d
The resolution seems different. Could that be the issue and how would I adjust it?

alpine 
  $ xdpyinfo | grep -B1 dot
  dimensions:    1366x768 pixels (340x190 millimeters)
  resolution:    102x103 dots per inch
  
devuan  
  $ xdpyinfo | grep -B1 dot
  dimensions:    1366x768 pixels (361x203 millimeters)
  resolution:    96x96 dots per inch

ALPINE 
/etc/fonts/conf.d
10-hinting-slight.conf      45-dejavu.conf     51-local.conf          69-unifont.conf
10-scale-bitmap-fonts.conf  45-generic.conf    60-generic.conf        80-delicious.conf
20-unhint-small-vera.conf   45-latin.conf      60-latin.conf          90-synthetic.conf
30-metric-aliases.conf      49-sansserif.conf  65-fonts-persian.conf  90-tt-dejavu.conf
40-nonlatin.conf            50-user.conf       65-nonlatin.conf       README
*45-dejavu.conf and 90-tt-dejavu.conf appear in red.

DEVUAN 
/etc/fonts/conf.d
10-hinting-slight.conf                         58-dejavu-lgc-serif.conf
10-scale-bitmap-fonts.conf                     60-generic.conf
11-lcdfilter-default.conf                      60-latin.conf
20-unhint-small-dejavu-lgc-sans.conf           61-urw-bookman.conf
20-unhint-small-dejavu-lgc-sans-mono.conf      61-urw-c059.conf
20-unhint-small-dejavu-lgc-serif.conf          61-urw-d050000l.conf
20-unhint-small-dejavu-sans.conf               61-urw-fallback-backwards.conf
20-unhint-small-dejavu-sans-mono.conf          61-urw-fallback-generics.conf
20-unhint-small-dejavu-serif.conf              61-urw-gothic.conf
20-unhint-small-vera.conf                      61-urw-nimbus-mono-ps.conf
30-0-google-crosextra-carlito-fontconfig.conf  61-urw-nimbus-roman.conf
30-metric-aliases.conf                         61-urw-nimbus-sans.conf
30-opensymbol.conf                             61-urw-p052.conf
40-nonlatin.conf                               61-urw-standard-symbols-ps.conf
45-generic.conf                                61-urw-z003.conf
45-latin.conf                                  65-fonts-persian.conf
49-sansserif.conf                              65-nonlatin.conf
50-user.conf                                   69-unifont.conf
51-local.conf                                  70-yes-bitmaps.conf
57-dejavu-sans.conf                            80-delicious.conf
57-dejavu-sans-mono.conf                       90-fonts-linux-libertine.conf
57-dejavu-serif.conf                           90-synthetic.conf
58-dejavu-lgc-sans.conf                        README
58-dejavu-lgc-sans-mono.conf

-- 
amc252 <amc252@@gmail.com>

---

From: Paul Bredbury <[email-masked]>
Date: Fri, 10 Dec 2021 22:00:01 +0000

>   resolution:    102x103 dots per inch

If running startx as normal (i.e. not root) user, then can add to ~/.xinitrc

xrandr --dpi 96