grimshot: Fix man page issues

This fixes a few formatting errors in SYNOPSIS, moves the command
options out of SYNOPSIS, swaps the labels on the SYNOPSIS and
DESCRIPTION sections, creates an EXAMPLES section and slightly rewords
parts of the OPTIONS, DESCRIPTION, EXAMPLES, and OUTPUT sections.
This commit is contained in:
William Culhane 2020-12-20 00:33:32 -06:00 committed by Simon Ser
parent d1c4ed1867
commit 7c9706de71
2 changed files with 54 additions and 42 deletions

View file

@ -1,53 +1,60 @@
.\" Generated by scdoc 1.10.1 .\" Generated by scdoc 1.11.1
.\" Complete documentation for this program is not available as a GNU info page .\" Complete documentation for this program is not available as a GNU info page
.ie \n(.g .ds Aq \(aq .ie \n(.g .ds Aq \(aq
.el .ds Aq ' .el .ds Aq '
.nh .nh
.ad l .ad l
.\" Begin generated content: .\" Begin generated content:
.TH "grimshot" "1" "2020-05-08" .TH "grimshot" "1" "2020-12-20"
.P .P
.SH NAME .SH NAME
.P .P
grimshot - a helper for screenshots within sway grimshot - a helper for screenshots within sway
.P .P
.SH DESCRIPTION .SH SYNOPSIS
.P .P
grimshot [--notify] (copy|save) [TARGET] [FILE] \fBgrimshot\fR [--notify] (copy|save) [TARGET] [FILE]
grimshot check .br
grimshot usage \fBgrimshot\fR check
.br
\fBgrimshot\fR usage
.P
.SH OPTIONS
.P .P
\fB--notify\fR \fB--notify\fR
.RS 4 .RS 4
Show notifications to the user that a screenshot has been taken. Show notifications to the user that a screenshot has been taken.\&
.P .P
.RE .RE
\fBsave\fR \fBsave\fR
.RS 4 .RS 4
Save the screenshot into a regular file. Grimshot will write images Save the screenshot into a regular file.\& Grimshot will write images
files to \fB$XDG_SCREENSHOTS_DIR\fR if this is set (or defined files to \fBXDG_SCREENSHOTS_DIR\fR if this is set (or defined
in `user-dirs.dir`), or otherwise fall back to `$XDG_PICTURES_DIR` in \fBuser-dirs.\&dir\fR), or otherwise fall back to \fBXDG_PICTURES_DIR\fR.\&
.P .P
.RE .RE
\fBcopy\fR \fBcopy\fR
.RS 4 .RS 4
Copy the screenshot data (as image/png) into the clipboard. Copy the screenshot data (as image/png) into the clipboard.\&
.P .P
.RE .RE
.SH SYNOPSIS .SH DESCRIPTION
.P .P
Grimshot is an easy to use screenshot tool for sway. It relies on grim, slurp Grimshot is an easy-to-use screenshot utility for sway.\& It provides a
and jq to do the heavy lifting, and mostly provides an easy to use interface. convenient interface over grim, slurp and jq, and supports storing the
screenshot either directly to the clipboard using wl-copy or to a file.\&
.P .P
A recommended usage pattern is to just bind this to Super+P via sway: .SH EXAMPLES
.P
An example usage pattern is to add these bindings to your sway config:
.P .P
.nf .nf
.RS 4 .RS 4
# Screenshots: # Screenshots:
# Cmd+P: Current window # Super+P: Current window
# Cmd+Shift+p: Select area # Super+Shift+p: Select area
# Cmd+Alt+p Current output # Super+Alt+p Current output
# Cmd+Ctrl+p Select a window # Super+Ctrl+p Select a window
bindsym Mod4+p exec grimshot save active bindsym Mod4+p exec grimshot save active
bindsym Mod4+Shift+p exec grimshot save area bindsym Mod4+Shift+p exec grimshot save area
@ -62,34 +69,34 @@ grimshot can capture the following named targets:
.P .P
\fIactive\fR \fIactive\fR
.RS 4 .RS 4
Captures the currently active window. Captures the currently active window.\&
.P .P
.RE .RE
\fIscreen\fR \fIscreen\fR
.RS 4 .RS 4
Captures the entire screen. This includes all visible outputs. Captures the entire screen.\& This includes all visible outputs.\&
.P .P
.RE .RE
\fIarea\fR \fIarea\fR
.RS 4 .RS 4
Allows manually selecting a rectangular region, and captures that. Allows manually selecting a rectangular region, and captures that.\&
.P .P
.RE .RE
\fIwindow\fR \fIwindow\fR
.RS 4 .RS 4
Allows manually selecting a single window (by clicking on it), and Allows manually selecting a single window (by clicking on it), and
captures it. captures it.\&
.P .P
.RE .RE
\fIoutput\fR \fIoutput\fR
.RS 4 .RS 4
Captures the currently active output. Captures the currently active output.\&
.P .P
.RE .RE
.SH OUTPUT .SH OUTPUT
.P .P
Grimshot will always print the filename of the captured screenshot to Grimshot will print the filename of the captured screenshot to stdout if called
stdout. with the \fIsave\fR subcommand.\&
.P .P
.SH SEE ALSO .SH SEE ALSO
.P .P

View file

@ -4,36 +4,41 @@ grimshot(1)
grimshot - a helper for screenshots within sway grimshot - a helper for screenshots within sway
# DESCRIPTION # SYNOPSIS
grimshot [--notify] (copy|save) [TARGET] [FILE] *grimshot* [--notify] (copy|save) [TARGET] [FILE]++
grimshot check *grimshot* check++
grimshot usage *grimshot* usage
# OPTIONS
*--notify* *--notify*
Show notifications to the user that a screenshot has been taken. Show notifications to the user that a screenshot has been taken.
*save* *save*
Save the screenshot into a regular file. Grimshot will write images Save the screenshot into a regular file. Grimshot will write images
files to *$XDG_SCREENSHOTS_DIR* if this is set (or defined files to *XDG_SCREENSHOTS_DIR* if this is set (or defined
in `user-dirs.dir`), or otherwise fall back to `$XDG_PICTURES_DIR` in *user-dirs.dir*), or otherwise fall back to *XDG_PICTURES_DIR*.
*copy* *copy*
Copy the screenshot data (as image/png) into the clipboard. Copy the screenshot data (as image/png) into the clipboard.
# SYNOPSIS # DESCRIPTION
Grimshot is an easy to use screenshot tool for sway. It relies on grim, slurp Grimshot is an easy-to-use screenshot utility for sway. It provides a
and jq to do the heavy lifting, and mostly provides an easy to use interface. convenient interface over grim, slurp and jq, and supports storing the
screenshot either directly to the clipboard using wl-copy or to a file.
A recommended usage pattern is to just bind this to Super+P via sway: # EXAMPLES
An example usage pattern is to add these bindings to your sway config:
``` ```
# Screenshots: # Screenshots:
# Cmd+P: Current window # Super+P: Current window
# Cmd+Shift+p: Select area # Super+Shift+p: Select area
# Cmd+Alt+p Current output # Super+Alt+p Current output
# Cmd+Ctrl+p Select a window # Super+Ctrl+p Select a window
bindsym Mod4+p exec grimshot save active bindsym Mod4+p exec grimshot save active
bindsym Mod4+Shift+p exec grimshot save area bindsym Mod4+Shift+p exec grimshot save area
@ -63,8 +68,8 @@ _output_
# OUTPUT # OUTPUT
Grimshot will always print the filename of the captured screenshot to Grimshot will print the filename of the captured screenshot to stdout if called
stdout. with the _save_ subcommand.
# SEE ALSO # SEE ALSO