nixos/hidpi: remove harder
We can't agree on what the right settings are (see #222236), so let's make the users choose.
This commit is contained in:
parent
c9183f5905
commit
8454084ffc
|
@ -179,6 +179,12 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
|
|
||||||
- conntrack helper autodetection has been removed from kernels 6.0 and up upstream, and an assertion was added to ensure things don't silently stop working. Migrate your configuration to assign helpers explicitly or use an older LTS kernel branch as a temporary workaround.
|
- conntrack helper autodetection has been removed from kernels 6.0 and up upstream, and an assertion was added to ensure things don't silently stop working. Migrate your configuration to assign helpers explicitly or use an older LTS kernel branch as a temporary workaround.
|
||||||
|
|
||||||
|
- The catch-all `hardware.video.hidpi.enable` option was removed. Users on high density displays may want to:
|
||||||
|
|
||||||
|
- Set `services.xserver.upscaleDefaultCursor` to upscale the default X11 cursor for higher resolutions
|
||||||
|
- Adjust settings under `fonts.fontconfig` according to preference
|
||||||
|
- Adjust `console.font` according to preference, though the kernel will generally choose a reasonably sized font
|
||||||
|
|
||||||
- The `baget` package and module was removed due to being unmaintained.
|
- The `baget` package and module was removed due to being unmaintained.
|
||||||
|
|
||||||
## Other Notable Changes {#sec-release-23.05-notable-changes}
|
## Other Notable Changes {#sec-release-23.05-notable-changes}
|
||||||
|
@ -258,11 +264,6 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
[headscale's example configuration](https://github.com/juanfont/headscale/blob/main/config-example.yaml)
|
[headscale's example configuration](https://github.com/juanfont/headscale/blob/main/config-example.yaml)
|
||||||
can be directly written as attribute-set in Nix within this option.
|
can be directly written as attribute-set in Nix within this option.
|
||||||
|
|
||||||
- The `hardware.video.hidpi.enable` was renamed to `fonts.optimizeForVeryHighDPI` to be consistent with what it actually does.
|
|
||||||
They disable by default: antialiasing, hinting and LCD filter for subpixel rendering. They can be overridden if you experience problems with font rendering.
|
|
||||||
On Xorg, the default cursor is upscaled.
|
|
||||||
Please see the documentation for the new option to decide if you want to keep it enabled.
|
|
||||||
|
|
||||||
- `nixos/lib/make-disk-image.nix` can now mutate EFI variables, run user-provided EFI firmware or variable templates. This is now extensively documented in the NixOS manual.
|
- `nixos/lib/make-disk-image.nix` can now mutate EFI variables, run user-provided EFI firmware or variable templates. This is now extensively documented in the NixOS manual.
|
||||||
|
|
||||||
- `services.grafana` listens only on localhost by default again. This was changed to upstreams default of `0.0.0.0` by accident in the freeform setting conversion.
|
- `services.grafana` listens only on localhost by default again. This was changed to upstreams default of `0.0.0.0` by accident in the freeform setting conversion.
|
||||||
|
|
|
@ -218,6 +218,8 @@ let
|
||||||
paths = cfg.confPackages;
|
paths = cfg.confPackages;
|
||||||
ignoreCollisions = true;
|
ignoreCollisions = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
fontconfigNote = "Consider manually configuring fonts.fontconfig according to personal preference.";
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
|
@ -229,6 +231,8 @@ in
|
||||||
(mkRemovedOptionModule [ "fonts" "fontconfig" "forceAutohint" ] "")
|
(mkRemovedOptionModule [ "fonts" "fontconfig" "forceAutohint" ] "")
|
||||||
(mkRemovedOptionModule [ "fonts" "fontconfig" "renderMonoTTFAsBitmap" ] "")
|
(mkRemovedOptionModule [ "fonts" "fontconfig" "renderMonoTTFAsBitmap" ] "")
|
||||||
(mkRemovedOptionModule [ "fonts" "fontconfig" "dpi" ] "Use display server-specific options")
|
(mkRemovedOptionModule [ "fonts" "fontconfig" "dpi" ] "Use display server-specific options")
|
||||||
|
(mkRemovedOptionModule [ "hardware" "video" "hidpi" "enable" ] fontconfigNote)
|
||||||
|
(mkRemovedOptionModule [ "fonts" "optimizeForVeryHighDPI" ] fontconfigNote)
|
||||||
] ++ lib.forEach [ "enable" "substitutions" "preset" ]
|
] ++ lib.forEach [ "enable" "substitutions" "preset" ]
|
||||||
(opt: lib.mkRemovedOptionModule [ "fonts" "fontconfig" "ultimate" "${opt}" ] ''
|
(opt: lib.mkRemovedOptionModule [ "fonts" "fontconfig" "ultimate" "${opt}" ] ''
|
||||||
The fonts.fontconfig.ultimate module and configuration is obsolete.
|
The fonts.fontconfig.ultimate module and configuration is obsolete.
|
||||||
|
|
|
@ -13,13 +13,10 @@ let
|
||||||
pkgs.unifont
|
pkgs.unifont
|
||||||
pkgs.noto-fonts-emoji
|
pkgs.noto-fonts-emoji
|
||||||
];
|
];
|
||||||
|
|
||||||
in
|
in
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
(mkRemovedOptionModule [ "fonts" "enableCoreFonts" ] "Use fonts.fonts = [ pkgs.corefonts ]; instead.")
|
(mkRemovedOptionModule [ "fonts" "enableCoreFonts" ] "Use fonts.fonts = [ pkgs.corefonts ]; instead.")
|
||||||
(mkRenamedOptionModule [ "hardware" "video" "hidpi" "enable" ] [ "fonts" "optimizeForVeryHighDPI" ])
|
|
||||||
];
|
];
|
||||||
|
|
||||||
options = {
|
options = {
|
||||||
|
@ -42,33 +39,9 @@ in
|
||||||
and families and reasonable coverage of Unicode.
|
and families and reasonable coverage of Unicode.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
optimizeForVeryHighDPI = mkOption {
|
|
||||||
type = types.bool;
|
|
||||||
default = false;
|
|
||||||
description = lib.mdDoc ''
|
|
||||||
Optimize configuration for very high-density (>200 DPI) displays:
|
|
||||||
- disable subpixel anti-aliasing
|
|
||||||
- disable hinting
|
|
||||||
- automatically upscale the default X11 cursor
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkMerge [
|
config = { fonts.fonts = mkIf cfg.enableDefaultFonts defaultFonts; };
|
||||||
{ fonts.fonts = mkIf cfg.enableDefaultFonts defaultFonts; }
|
|
||||||
(mkIf cfg.optimizeForVeryHighDPI {
|
|
||||||
services.xserver.upscaleDefaultCursor = mkDefault true;
|
|
||||||
# Conforms to the recommendation in fonts/fontconfig.nix
|
|
||||||
# for > 200DPI.
|
|
||||||
fonts.fontconfig = {
|
|
||||||
antialias = mkDefault false;
|
|
||||||
hinting.enable = mkDefault false;
|
|
||||||
subpixel.lcdfilter = mkDefault "none";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
];
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue