modify automapaper to use nix-colors

This commit is contained in:
Noa Aarts 2024-06-18 16:04:30 +02:00
parent 20dd891399
commit 03b2f54a25
2 changed files with 8 additions and 8 deletions

10
flake.lock generated
View file

@ -216,11 +216,11 @@
]
},
"locked": {
"lastModified": 1718526747,
"lastModified": 1718716991,
"narHash": "sha256-sKrD/utGvmtQALvuDj4j0CT3AJXP1idOAq2p+27TpeE=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "0a7ffb28e5df5844d0e8039c9833d7075cdee792",
"rev": "fab8e511d58f9c3f1cf8456abd685bfd381f7ebe",
"type": "github"
},
"original": {
@ -487,11 +487,11 @@
"nixpkgs-lib": "nixpkgs-lib"
},
"locked": {
"lastModified": 1707825078,
"narHash": "sha256-hTfge2J2W+42SZ7VHXkf4kjU+qzFqPeC9k66jAUBMHk=",
"lastModified": 1718718715,
"narHash": "sha256-NS95zWZfv/IZvqoAouUW8RJIiBf+HFTKNRlay0GxLzI=",
"owner": "itepastra",
"repo": "nix-colors",
"rev": "b01f024090d2c4fc3152cd0cf12027a7b8453ba1",
"rev": "5020bfccdad81ca4b0827d3b49ad72353ba1694c",
"type": "github"
},
"original": {

View file

@ -1,4 +1,4 @@
{ lib, config, pkgs, inputs, ... }:
{ lib, config, pkgs, inputs, nix-colors, ... }:
let
cfg = config.modules.automapaper;
in
@ -149,8 +149,8 @@ in
in highp vec2 texCoords;
out vec4 stateColor;
const vec4 bgColor = vec4(38.0/255.0, 5.0/255.0, 46.0/255.0, 1.0); // #26052e
const vec4 fgColor = vec4(148.0/255.0, 15.0/255.0, 173.0/255.0, 1.0); // #950fad
const vec4 bgColor = ${nix-colors.lib.conversions.hexToGLSLVec "26052e"}; // #26052e
const vec4 fgColor = ${nix-colors.lib.conversions.hexToGLSLVec "950fad"}; // #950fad
void main() {
vec2 canvasSize = vec2(textureSize(tex2D, 0));