| 1 | # :pencil: colorglass |
| 2 | |
| 3 | If your terminal supports 24-bit color, you can adjust the theme colors by |
| 4 | specifying gamma, contrast, hue rotation, etc. This also works for the |
| 5 | terminals without the 24-bit color support if `bleopt term_index_colors` is |
| 6 | properly set up, but the resulting colors would be reduced to a smaller number |
| 7 | of colors. |
| 8 | |
| 9 | ```bash |
| 10 | ble-import contrib/colorglass |
| 11 | |
| 12 | # If your terminal does not support the 24-bit colors, please explicitly |
| 13 | # configure it by putting the following line: |
| 14 | #bleopt term_true_colors= |
| 15 | ``` |
| 16 | |
| 17 | ## Options |
| 18 | |
| 19 | ### Blopet `colorglass_gamma` (Integer) |
| 20 | |
| 21 | This option specifies the change of gamma by percentage. For example, `bleopt |
| 22 | colorglass_gamma=5` performs the gamma correction with $\gamma=1.05$, and |
| 23 | `bleopt colorglass_gamma=-5` performs the gamma correction with $\gamma=0.95$ |
| 24 | |
| 25 | ```bash |
| 26 | # default |
| 27 | bleopt colorglass_gamma=0 |
| 28 | ``` |
| 29 | |
| 30 | ### Blopet `colorglass_contrast` (Integer) |
| 31 | |
| 32 | This option specifies the contrast modification in the range -100..100. |
| 33 | |
| 34 | ```bash |
| 35 | # default |
| 36 | bleopt colorglass_contrast=0 |
| 37 | ``` |
| 38 | |
| 39 | ### Blopet `colorglass_rotate` (Integer) |
| 40 | |
| 41 | This option specifies the angle of hue rotation in degrees. |
| 42 | |
| 43 | ```bash |
| 44 | # default |
| 45 | bleopt colorglass_rotate=0 |
| 46 | ``` |
| 47 | |
| 48 | ### Blopet `colorglass_saturation` (Integer) |
| 49 | |
| 50 | This option specifies the change of saturation in the range -100..100. |
| 51 | |
| 52 | ```bash |
| 53 | # default |
| 54 | bleopt colorglass_saturation=0 |
| 55 | ``` |
| 56 | |
| 57 | ### Blopet `colorglass_brightness` (Integer) |
| 58 | |
| 59 | This option specifies the change of brightness in the range -100..100. |
| 60 | |
| 61 | ```bash |
| 62 | # default |
| 63 | bleopt colorglass_brightness=0 |
| 64 | ``` |
| 65 | |
| 66 | ### Blopet `colorglass_alpha` (Integer) |
| 67 | |
| 68 | This option specifies the opacity in the range 0..255 when the color is |
| 69 | synthesized with the background color specified by `bleopt colorglass_color`. |
| 70 | |
| 71 | ```bash |
| 72 | # defualt |
| 73 | bleopt colorglass_alpha=255 |
| 74 | ``` |
| 75 | |
| 76 | ### Blopet `colorglass_color` (Integer) |
| 77 | |
| 78 | This option specifies the background color used by the color synthesis by |
| 79 | `bleopt colorglass_alpha`. |
| 80 | |
| 81 | ```bash |
| 82 | # defualt |
| 83 | bleopt colorglass_color=0x8888FF |
| 84 | ``` |
| 85 | |
| 86 | ### Bleopt `colorglass_base16_palette` (Empty/Enumerate) |
| 87 | |
| 88 | This option specifies a color scheme of `base16` colors (index colors 0..15). |
| 89 | When this option is set to a (non-empty) palette name, index colors 0..15 in |
| 90 | the output of `ble.sh` will be replaced by the corresponding 24-bit colors in |
| 91 | the palette. See [List of base16 palettes](https://akinomyoga.github.io/ble.sh/colorglass.base16.html) |
| 92 | or [`colorglass.base16.dat`](https://github.com/akinomyoga/blesh-contrib/blob/master/colorglass.base16.dat) |
| 93 | for the list of available palettes. |
| 94 | |
| 95 | ```bash |
| 96 | # defualt |
| 97 | bleopt colorglass_base16_palette= |
| 98 | ``` |
| 99 | |
| 100 | ### Bleopt `colorglass_blindness` (Enumerate) |
| 101 | |
| 102 | When this option is set to a non-empty value, the colors under color blindness |
| 103 | are simulated. Five values `none`, `protanopia`, `deuteranopia`, `tritanopia`, |
| 104 | and `achromatopsia` are supported. |
| 105 | |
| 106 | ```bash |
| 107 | # default |
| 108 | bleopt colorglass_blindness=none |
| 109 | ``` |