.\" Generated by scdoc 1.11.3 .\" Complete documentation for this program is not available as a GNU info page .ie \n(.g .ds Aq \(aq .el .ds Aq ' .nh .ad l .\" Begin generated content: .TH "swappy" "1" "2025-08-27" .PP .SH NAME .PP swappy - grab and edit on the fly snapshots of a Wayland compositor .PP .SH SYNOPSIS .PP \fBswappy\fR [options.\&.\&.\&] .PP .SH DESCRIPTION .PP swappy is a command-line utility to take and edit screenshots of Wayland desktops.\& Works great with grim, slurp and sway.\& But can easily work with other screen copy tools that can output a final image to \fBstdout\fR.\& .PP swappy will save the annotated images to the config \fBsave_dir\fR, see below.\& .PP If absent, then if it will try to default to a \fBDesktop\fR folder following this pattern: \fB$XDG_DESKTOP_DIR\fR.\& If this variable is not set, it will revert to: \fB$XDG_CONFIG_HOME/Desktop\fR.\& If \fB$XDG_CONFIG_HOME\fR is not set, it will revert to: \fB$HOME/Desktop\fR.\& .PP .SH OPTIONS .PP \fB-h, --help\fR .RS 4 Show help message and quit.\& .PP .RE \fB-v, --version\fR .RS 4 Show version and quit.\& .PP .RE \fB-f, --file\fR .RS 4 An image file to load for editing.\& .PP If set to \fB-\fR, read the file from standard input instead.\& This is grim friendly.\& .PP .RE \fB-o, --output-file \fR .RS 4 Print the final surface to \fB\fR when exiting the application.\& .PP If set to \fB-\fR, prints the final surface to \fBstdout\fR.\& .PP Note that the \fBSave\fR button will save the image to the config \fBsave_dir\fR parameter, as described in the DESCRIPTION section.\& .PP .RE .SH CONFIG FILE .PP The config file is located at \fB$XDG_CONFIG_HOME/swappy/config\fR or at \fB$HOME/.\&config/swappy/config\fR.\& The file follows the GLib \fBconf\fR format.\& .PP .nf .RS 4 [Section] key=value .fi .RE .PP The following lines can be used as swappy'\&s default: .PP .nf .RS 4 [Default] save_dir=$HOME/Desktop save_filename_format=swappy-%Y%m%d-%H%M%S\&.png show_panel=false line_size=5 text_size=20 text_font=sans-serif paint_mode=brush early_exit=false fill_shape=false auto_save=false custom_color=rgba(192,125,17,1) transparent=false transparency=50 .fi .RE .PP .PD 0 .IP \(bu 4 \fBsave_dir\fR is where swappshots will be saved, can contain env variables, when it does not exist, swappy attempts to create it first, but does not abort if directory creation fails .IP \(bu 4 \fBsave_filename_format\fR is the filename template, if it contains a date format, this will be parsed into a timestamp.\& Format is detailed in strftime(3).\& If this date format is missing, filename will have no timestamp .IP \(bu 4 \fBshow_panel\fR is used to toggle the paint panel on or off upon startup .IP \(bu 4 \fBline_size\fR is the default line size (must be between 1 and 50) .IP \(bu 4 \fBtext_size\fR is the default text size (must be between 10 and 50) .IP \(bu 4 \fBtext_font\fR is the font used to render text, its format is pango friendly .IP \(bu 4 \fBpaint_mode\fR is the mode activated at application start (must be one of: brush|text|rectangle|ellipse|arrow|blur, matching is case-insensitive) .IP \(bu 4 \fBearly_exit\fR is used to make the application exit after saving the picture or copying it to the clipboard .IP \(bu 4 \fBfill_shape\fR is used to toggle shape filling (for the rectangle and ellipsis tools) on or off upon startup .IP \(bu 4 \fBauto_save\fR is used to toggle auto saving of final buffer to \fBsave_dir\fR upon exit .IP \(bu 4 \fBcustom_color\fR is used to set a default value for the custom color.\& Accepted .PD formats are: standard name (one of: https://github.\&com/rgb-x/system/blob/master/root/etc/X11/rgb.\&txt), #rgb, #rrggbb, #rrrgggbbb, #rrrrggggbbbb, rgb(r,b,g), rgba(r,g,b,a) .PD 0 .IP \(bu 4 \fBtransparency\fR is used to set transparency of everything that is drawn during startup .IP \(bu 4 \fBtransparent\fR is used to toggle transparency during startup .PD .PP .PP .SH KEY BINDINGS .PP .SS LAYOUT .PP .PD 0 .IP \(bu 4 \fBCtrl+b\fR: Toggle Paint Panel .PD .PP .SS PAINT MODE .PP .PD 0 .IP \(bu 4 \fBb\fR: Switch to Brush .IP \(bu 4 `e` `t`: Switch to Text (Editor) .IP \(bu 4 `r` `s`: Switch to Rectangle (Square) .IP \(bu 4 `c` `o`: Switch to Ellipse (Circle) .IP \(bu 4 \fBa\fR: Switch to Arrow .IP \(bu 4 \fBd\fR: Switch to Blur (d stands for droplet) .PD .PP .PD 0 .IP \(bu 4 \fBR\fR: Use Red Color .IP \(bu 4 \fBG\fR: Use Green Color .IP \(bu 4 \fBB\fR: Use Blue Color .IP \(bu 4 \fBC\fR: Use Custom Color .IP \(bu 4 \fBMinus\fR: Reduce Stroke Size .IP \(bu 4 \fBPlus\fR: Increase Stroke Size .IP \(bu 4 \fBEqual\fR: Reset Stroke Size .IP \(bu 4 \fBf\fR: Toggle Shape Filling .IP \(bu 4 \fBT\fR: Toggle Transparency .IP \(bu 4 `x` `k`: Clear Paints (cannot be undone) .PD .PP .SS MODIFIERS .PP .PD 0 .IP \(bu 4 \fBCtrl\fR: Center Shape (Rectangle & Ellipse) based on draw start .PD .PP .SS HEADER BAR .PP .PD 0 .IP \(bu 4 \fBCtrl+z\fR: Undo .IP \(bu 4 \fBCtrl+Shift+z\fR or \fBCtrl+y\fR: Redo .IP \(bu 4 \fBCtrl+s\fR: Save to file (see man page) .IP \(bu 4 \fBCtrl+c\fR: Copy to clipboard .IP \(bu 4 \fBEscape\fR or \fBq\fR or \fBCtrl+w\fR: Quit swappy .PD .PP .SH AUTHORS .PP Written and maintained by jtheoof .\& See https://github.\&com/jtheoof/swappy.\&