aboutsummaryrefslogtreecommitdiff
path: root/modules/home/apps/mpv/default.nix
blob: 3e74fb1bff938a3e3fe6e854da997bbaba810ce9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
{ options, config, lib, namespace, ... }:

with lib; with lib.${namespace}; let
  cfg = config.${namespace}.apps.mpv;
in {
  options.${namespace}.apps.mpv = with types; {
    enable = mkEnableOption "mpv";
  };

  config = mkIf cfg.enable {
    programs.mpv = {
      enable = true;
      
      config = {
        screenshot-format = "png";
        screenshot-template = "~/Pictures/Screenshots/mpv/%F/%P";

        sub-auto = "fuzzy";
      };

      profiles = {
        ja = {
          profile-restore = "copy";

          sub-font-size = 54;
          sub-bold = true;

          sub-border-style = "outline-and-shadow";
          sub-outline-size = 1.2;
          sub-shadow-offset = 0.8;

          sub-margin-x = 60;
          sub-margin-y = 46;
        };
      };
    };
  };
}