Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 0 additions & 34 deletions pkgs/by-name/kr/kreative-square-fonts/package.nix

This file was deleted.

95 changes: 95 additions & 0 deletions pkgs/data/fonts/open-relay/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
{
lib,
stdenvNoCC,
fetchFromGitHub,
}:

let
mkOpenRelayTypeface =
name:
{ directory, meta }:
stdenvNoCC.mkDerivation (finalAttrs: {
pname = "open-relay-${name}";
version = "2025-03-20";

src = fetchFromGitHub {
owner = "kreativekorp";
repo = "open-relay";
tag = finalAttrs.version;
hash = "sha256-OQpZHPbNL3rxXH89lwtHvm7eENl8fS0M0i8IBn4m2hI=";
};

installPhase = ''
runHook preInstall

install -D -m444 -t "$out/share/fonts/truetype" "${directory}/*.ttf"
install -D -m644 -t "$out/share/doc/${finalAttrs.pname}-${finalAttrs.version}" "${directory}/OFL.txt"

runHook postInstall
'';

meta = {
homepage = "https://www.kreativekorp.com/software/fonts/index.shtml";
description = "Free and open source fonts from Kreative Software";
license = lib.licenses.ofl;
platforms = lib.platforms.all;
maintainers = with lib.maintainers; [
linus
toastal
];
} // meta;
});
in
lib.mapAttrs mkOpenRelayTypeface {
constructium = {
directory = "Constructium";
meta = {
homepage = "https://www.kreativekorp.com/software/fonts/constructium/";
description = "fork of SIL Gentium designed specifically to support constructed scripts as encoded in the Under-ConScript Unicode Registry";
longDescription = ''
Constructium is a fork of SIL Gentium designed specifically to support
constructed scripts as encoded in the Under-ConScript Unicode Registry.
It is ideal for mixed Latin, Greek, Cyrillic, IPA, and conlang text in
web sites and documents.
'';
};
};

fairfax = {
directory = "Fairfax";
meta = {
homepage = "https://www.kreativekorp.com/software/fonts/fairfax/";
description = "6×12 bitmap font supporting many Unicode blocks & scripts as well as constructed scripts";
longDescription = ''
Fairfax is a 6×12 bitmap font for terminals, text editors, IDEs, etc. It
supports many scripts and a large number of Unicode blocks as well as
constructed scripts as encoded in the Under-ConScript Unicode Registry,
pseudographics and semigraphics, and tons of private use characters. It
has been superceded by Fairfax HD but is still maintained.
'';
};
};

fairfax-hd = {
directory = "FairfaxHD";
meta = {
homepage = "https://www.kreativekorp.com/software/fonts/fairfaxhd/";
description = "halfwidth scalable monospace font supporting many Unicode blocks & script as well as constructed scripts";
longDescription = ''
Fairfax HD is a halfwidth scalable monospace font for terminals, text
editors, IDEs, etc. It supports many scripts and a large number of
Unicode blocks as well as constructed scripts as encoded in the
Under-ConScript Unicode Registry, pseudographics and semigraphics, and
tons of private use characters.
'';
};
};

kreative-square = {
directory = "KreativeSquare";
meta = {
homepage = "https://www.kreativekorp.com/software/fonts/ksquare/";
description = "Fullwidth scalable monospace font designed specifically to support pseudographics, semigraphics, and private use characters";
};
};
}
1 change: 1 addition & 0 deletions pkgs/top-level/aliases.nix
Original file line number Diff line number Diff line change
Expand Up @@ -929,6 +929,7 @@ mapAliases {
kodiPlugins = kodiPackages; # Added 2021-03-09;
kramdown-rfc2629 = throw "'kramdown-rfc2629' has been renamed to/replaced by 'rubyPackages.kramdown-rfc2629'"; # Converted to throw 2024-10-17
krb5Full = krb5;
kreative-square-fonts = throw "'kreative-square-fonts' has been renamed to 'kreative-square'"; # Added 2025-04-16
krita-beta = throw "'krita-beta' has been renamed to/replaced by 'krita'"; # Converted to throw 2024-10-17
krun = throw "'krun' has been renamed to/replaced by 'muvm'"; # Added 2025-05-01
kubei = kubeclarity; # Added 2023-05-20
Expand Down
7 changes: 7 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13642,6 +13642,13 @@ with pkgs;
vm = callPackage ../applications/audio/open-music-kontrollers/vm.nix { };
};

inherit (callPackages ../data/fonts/open-relay { })
constructium
fairfax
fairfax-hd
kreative-square
Comment on lines 13646 to 13649
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Would it make more sense to use something like open-relay-fonts.kreative-square for the name? My Nix is rusty and to me this just looks like we're expecting users to install the fonts only by their name. But these fonts all come from open-relay so maybe it makes sense to group them together somehow?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tough call since I don’t see it as much with everything trying to flatten (tho I prefer nesting myself).

Copy link
Copy Markdown
Contributor Author

@toastal toastal May 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other top-level nested things are like ocamlPackages, gnomeExtension, linuxKernel, libsForQt5, where 4 fonts seems a bit out of place—tho lohit-fonts + mplus-outline-fonts are there.


If I were a Nixpkgs maintainer, I would personally like to see fonts in its own attrset like the aforementioned ocamlPackages since there is a lot of names used just for fonts & fonts, while being software, generally tend to ship as is versus the from-source build approach (tho I would venture to guess Google Fonts requiring a repository with the prebuilt font has something to do with that). It would also make certain operations easier since you could do with pkgs.fonts; … or have the system font setups take a callback with the fonts (such as { fonts.packages = (fonts: with fonts; [ roboto ]); }).

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I were a Nixpkgs maintainer, I would personally like to see fonts in its own attrset like [...]

You /are/ a nixpkgs maintainer. You might not have the commit bit yet, but that's not a requirement to propose refactors in nixpkgs. It's more of a Do-ocracy, there's not a font institution inside the community responsible for a fonts attribute 😆

If you're serious about this, open an issue, highlighting people previously involved. Maybe prototype on the "how" somewhere local before, and open a draft PR once it cooked a bit more. This shouldn't be self-merged anyways, but needs to be reviewed by people frequently interacting with the font system, so commit bits are orthogonal.

;

openscad = libsForQt5.callPackage ../applications/graphics/openscad { };

opentoonz = libsForQt5.callPackage ../applications/graphics/opentoonz { };
Expand Down