s2 (simple screenshot / suckless screenshots) is a keyboard-first screenshot annotation and redaction tool.
makesudo pacman -S libx11 libxft freetype2 libpng pango cairo harfbuzz xclip maim slopInstall equivalents for:
- X11 development headers/libs (
libX11) - Xft + FreeType (
libXft,freetype2) - text shaping/rendering stack (
pango,cairo,harfbuzz) - PNG library (
libpng) - clipboard helper (
xclip) - optional capture workflow tools (
maim,slop)
makesudo make clean installInstall destination defaults to /usr/local/bin/s2 and can be changed in config.mk.
config.his generated fromconfig.def.hduring build.- Edit
config.hfor local customization. - Save defaults can be customized in
config.hwithdefault_save_directory. - Tool defaults can be customized in
config.hwithdefault_palette_index,default_thickness_index, anddefault_text_scale. - UI defaults can be customized in
config.hwithdefault_tool_indexandselection_bbox_color. - Before reinstalling after upstream changes, remove local
config.hso defaults can refresh:
rm -f config.h
sudo make clean installYou can also run:
make distcleanmaim -s | s2 -i -maim -s | s2 -i -Ctrl+C: copy and exitCtrl+S: save timestamped PNG and exit (prints saved absolute path)q/Esc: quit/cancel (non-zero exit)
Ctrl+C: copy rendered image to clipboard and exit successCtrl+Y: copy current image to clipboardCtrl+V: paste clipboard text only (text MIME); starts/appends text inputCtrl+S: save timestamped file to configured save directory (YYYY-MM-DDTHHMM.png)Enter: save and exitqorEsc: quit/cancel (returns non-zero)s: selection toola: arrow tooll: line toolr: rectangle toolo: circle toolt: text toolh: highlight toolb: blur toolp: pen tool (freehand)n: number tool (auto-incrementing markers)x: pixelate toolc: color picker tool (sample from image)h/j/k/lor arrow keys: move keyboard cursor by 1pxH/J/K/L: move keyboard cursor by 10pxSpaceor left click: apply tool action[/]: thickness, text size, or pixelate block size[/]on highlight tool changeshl-strength(1..100)Ctrl+Z: undo last actionCtrl+Shift+Z: redo1..9: select color from palette#: enter hex color mode (type 6 hex chars, Enter to apply)f: toggle fill mode (filled circles + text background with inverse contrast)X: cancel pending anchor or active pen/text input?: toggle keybindings help panelBackspace/Delete: delete selected object
Text mode note:
- Pressing
Escwhile typing exits text input first; pressingEscagain then quits.
Tool flow:
- Arrow/Circle/Pixelate/Blur keyboard flow: first
Spacesets anchor, secondSpacecommits. - Arrow/Circle/Pixelate/Blur mouse flow: press sets anchor, release commits at current cursor.
- Text: click or
Spaceenters text input mode; type with live preview;Enteror click commits text. - Text live-preview: while typing, current text is previewed on image before commit.
- Picker:
Spacesamples color under cursor into active color. - Selection: click object to select (shows configurable bounding box), drag moves only the bbox preview until release, then commits object move.
- Pen: click-hold and drag to draw freehand using current thickness.
- Number: each click places a filled numbered circle (
1,2,3, ...) using current color; number size follows text-size.
CLI additions:
-C <class>sets X11WM_CLASS(instance/class) for window rules in WMs like dwm.-D <absdir>sets absolute save directory for Ctrl+S timestamp files (overrides config default).--normal-windowuses X11 normal window type instead of the default dialog window type.
UI behavior:
- While dragging/selecting anchored tools, a rectangle guide is shown.
- Status is shown in a dedicated bottom bar (not drawn on top of the image).
- Window/status colors follow a best-effort light/dark preference detection from environment/X resources.
- Window resize scales image and all objects to fit window canvas.
- Editor enforces a minimum usable window size so very small captures remain operable.
config.def.h now includes font_name for text rendering defaults.
Text fill styling in config.def.h:
text_fill_padding: background padding around filled texttext_fill_corner_radius: rounded corner radius for filled text backgroundwindow_padding: outer margin around canvas/status so bars stay visible at large sizesmax_text_scale: max text size reachable with]in text tool
Keyboard movement:
- Cursor movement now uses arrow keys only (
Left/Right/Up/Down)
