New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nixos/hidpi: Reasonable defaults for high-density displays #88669
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me in general, I'd be happy to enable this on my systems.
94f8e86
to
2c0c134
Compare
Switched to |
push @attrs, "# High-DPI console"; | ||
push @attrs, 'console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-u28n.psf.gz";'; | ||
push @attrs, "# high-resolution display"; | ||
push @attrs, 'hardware.video.hidpi.enable = lib.mkDefault true;'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure having this is the best heuristic for HiDPI - what if the monitor is just really large? In general I don't think it's correct to determine HiDPI from resolution
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMHO it's a reasonable assumption that if we have lots of pixels it's okay to make stuff bigger, even if it's not correct in absolutely all cases.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you have a better method. i.e. a simple way to decode edid, we can change it.
Notice that this PR does not change the way hidpi is detected.
v32n has more characters.
@@ -42,7 +42,7 @@ | |||
</para> | |||
|
|||
<para> | |||
If the text is too small to be legible, try <command>setfont ter-132n</command> | |||
If the text is too small to be legible, try <command>setfont ter-v32n</command> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we just detect larger tty's in the installer and scale up automatically during boot?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Anyway. This should not be part of this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there an existing issue/PR for making nixos-minimal iso autodetect hidpi and choose a larger font?
Any other concerns? |
friendly ping to everyone. |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
Motivation for this change
This is a smaller subset of #87730
It does not contain any x11 settings yet.
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)