index.md - sites - public wiki contents of suckless.org | |
git clone git://git.suckless.org/sites | |
Log | |
Files | |
Refs | |
--- | |
index.md (1423B) | |
--- | |
1 png images | |
2 ========== | |
3 | |
4 Description | |
5 ----------- | |
6 Preview PNG images using [libspng](https://libspng.org/). | |
7 | |
8 Lines like `PNG_IMAGE:/path/to/image.png` will be replaced with a previe… | |
9 the given image file. The prefix (`PNG_IMAGE:`) can be changed via the `… | |
10 flag. An empty prefix string is possible, too. | |
11 | |
12 The image preview is taken from the top left corner of the image. For ve… | |
13 menus, the height is limited to _N_ pixels provided via `-is N` or the h… | |
14 of two text lines otherwise. For horizontal menus, the preview height eq… | |
15 the bar height. The image width is limited to _N_ pixels provided via `-… | |
16 or the height of eight text lines otherwise. | |
17 | |
18 Example | |
19 ------- | |
20 | |
21 Select a [greenclip](https://github.com/erebe/greenclip) clipboard entry… | |
22 image previews: | |
23 | |
24 greenclip print | grep . \ | |
25 | sed -E 's|^(image/png )(.*)|\1/tmp/greenclip/\2.png|' \ | |
26 | ./dmenu -i -fn 'monospace:size=14' -ip 'image/png ' -p clipboar… | |
27 | sed -E 's|^(image/png )/tmp/greenclip/(-?[0-9]+)\.png$|\1\2|' \ | |
28 | xargs -r -d'\n' -I '{}' greenclip print '{}' | |
29 | |
30  (2024-11-04) ([… | |
35 | |
36 Authors | |
37 ------- | |
38 * Max Schillinger - <[email protected]> |