
{ pkgs, config, lib, ... }:

{
  programs.autorandr = {
    enable = true;
    hooks = {
      postswitch = { 
      "nitrogen" = "nitrogen --restore";
      };
    };
    profiles = { 
      "3monitor" = {
      fingerprint = {
        "DVI-D-1" = "00ffffffffffff0009d1a578455400002116010380351e782eb7d5a456549f270c5054a56b80810081c08180a9c0b300d1c001010101023a801871382d40582c4500132a2100001e000000ff003638433130393736534c300a20000000fd00324c1e5311000a202020202020000000fc0042656e5120474c323435300a2000be";
        "DP-1" = "00ffffffffffff001e6df259a1360300031b0104a55022789eca95a6554ea1260f5054a54b80714f818081c0a9c0b3000101010101017e4800e0a0381f4040403a001e4e31000018023a801871382d40582c45001e4e3100001a000000fc004c4720554c545241574944450a000000fd00384b1e5a18000a202020202020015502031c71499004030012001f0113230907078301000065030c001000023a801871382d40582c450056512100001e011d8018711c1620582c2500a5222100009e011d007251d01e206e285500a5222100001e8c0ad08a20e02d10103e9600a52221000018000000000000000000000000000000000000000000000000000000d5";
        "HDMI-1" = "00ffffffffffff001e6df15932fe0000081b010380431c78eaca95a6554ea1260f5054a54b80714f818081c0a9c0b3000101010101017e4800e0a0381f4040403a00a11c21000018023a801871382d40582c4500a11c2100001e000000fc004c4720554c545241574944450a000000fd00384b1e5a18000a202020202020016202031cf1499004031412051f0113230907078301000065030c001000023a801871382d40582c450056512100001e011d8018711c1620582c250056512100009e011d007251d01e206e28550056512100001e8c0ad08a20e02d10103e9600565121000018000000ff003730384e54445631583037340a00000000000000000094";
      };
      config = {
        "DVI-D-1" = {
          enable = true;
          position = "0x0";
          crtc = 0;
          mode = "1920x1080";
          rotate = "right";
          rate = "60.00";
        };
        "DP-1" = {
          enable = true;
          position = "1080x420";
          crtc = 1;
          mode = "2560x1080";
          rate = "60.00";
          primary = true;
        }; 
        "HDMI-1" = {
          enable = true;
          position = "3640x420";
          crtc = 2;
          mode = "2560x1080";
          rate = "60.00";
        };         
      };
      };
    };
  };
}

