Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

file 188 lines (180 sloc) 4.816 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188
.\" man page for xcowsay
.TH "xcowsay" 6
.SH NAME
xcowsay \- Display a cute cow and speech bubble.
.SH SYNOPSIS
.B xcowsay
.RB [ "-h" ]
.RB [ "-t"
.RI \| time \|]
.RB [ "-r"
.RI \| speed \|]
.RB [ "-d" ]
.RB [ "-f"
.RI \| font \|]
.RI [\| text \|]...

.SH DESCRIPTION
Display a cow with a speech bubble containing some text. If
.I text
is specified it will be displayed in the bubble. Otherwise the text
will be read from the standard input and displayed when end of file
is encountered.

The cow is displayed for either a fixed amount of time, or an amount
of time calculated from the size of the text. Click on the cow to
dismiss it immediately.

If
.B xcowsay
is started with
.B "--daemon"
it will fork away from the terminal and run in daemon mode. The
daemon provides a DBus service
.B uk.me.doof.Cowsay
that responds to
.B ShowCow
requests. The daemon can queue up any number of requests and displays
them in order.

When
.B xcowsay
starts it checks to see if a daemon is running, and if it is, sends a
.B ShowCow
request and returns immediately. Otherwise
.B xcowsay
will block until the cow has disappeared.

.SH CONFIGURATION FILE
xcowsay reads a configuration file on startup. The configuration file
can be stored in the XDG compliant location
.I $XDG_CONFIG_HOME/xcowsayrc
(which will default to
.IR $HOME/.config/xcowsayrc )
or in your home directory at
.IR $HOME/.xcowsayrc .
If the
.BI --config= FILE
command line option is passed
.I FILE
will be processed after your personal configuration file.

The configuration file consists of 'option = value' pairs, one per line. The
valid keys are given in the next section. For example, the following line sets
display time to 10 seconds:
.PP
.RS
display_time = 10000
.RE
.PP
The character '#' begins a comment which lasts until the end of the
line.

Values containing spaces should be enclosed in quotes. For example:
.PP
.RS
font = "mono 28"
.RE
.PP

.SH OPTIONS
Note that these options override any settings in the config file.
.TP
.B "-h, --help"
Display usage information.
.TP
.BI "-t " time ", --time=" time
Display the cow for
.I time
seconds. This overrides any value set for
.IR reading_speed .
Setting
.I time
to zero displays the cow until it is clicked.
The corresponding config file option is
.IR display_time .
.TP
.BI "-r " speed ", --reading-speed=" speed
Number of milliseconds to display the cow for each word in the input
text. This is clamped to a minimum of
.I min_display_time
and a maximum of
.IR max_display_time .
The defaults are 1 second and 30 seconds respectively. The corresponding
config file option is
.IR reading_speed .
.TP
.BI "-f " font ", --font=" font
Font for the speech bubble text. Accepts Pango font strings. The
corresponding config file option is
.IR font .
.TP
.BI "-d " file ", --dream=" file
Display an image instead of text in the cow's bubble. The
.I dream_time
config file option sets the numer of milliseconds to display the
image for. The default is 10 seconds.
.TP
.B "--think"
Display a thought bubble instead of a speech bubble.
.TP
.B "--daemon"
Run xcowsay in daemon mode if DBus support has been enabled. See the
description for more information.
.TP
.BI "--cow-size=" size
Size of the cow image. Current choices are
.BR small ", " med ", or " large .
The corresponding config file option is
.IR cow_size .
.TP
.BI "--image=" file
Use a different image instead of the cow. The corresponding config file
option is
.IR alt_image .
.TP
.BI "--monitor=" N
Make the cow appear on monitor N.
.TP
.BI "--at=" X,Y
Force that cow to appear at screen location (X,Y). The config file options
are
.I at_x
and
.IR at_y .
.TP
.BI "--bubble-at=" X,Y
Change position of bubble relative to where it would normally appear. This
is most useful when combined with the
.I alt_image
option to create your own characters. The config file options are
.I bubble_x
and
.IR bubble_y .
.TP
.B "--no-wrap"
Disable word wrapping when the bubble is too wide to fit on the screen.
The config file option
.I wrap
can be set to
.I true
or
.I false
to set this explicitly.
.TP
.B "-l, --left"
Make the bubble appear on the left hand side of the cow. This is useful
if you are using your own image.
.TP
.B "--debug"
Print messages about what
.B xcowsay
is doing. Useful for finding out why the daemon fails.
.TP
.B "-v, --version"
Print version information.
.SH "AUTHOR"
Written by Nick Gasson.
.SH "REPORTING BUGS"
Report all bugs to nick@nickg.me.uk
.BR
The xcowsay home page is <http://www.doof.me.uk/xcowsay>
.SH "SEE ALSO"
.BR cowsay (6)
.SH BUGS
The cow and speech bubble have jagged edges which would be improved by
anti-aliasing. Unfortunately this isn't possible without a compositing
window manager since X can only cut holes in windows using a binary
mask, so I wouldn't expect this any time soon.
Something went wrong with that request. Please try again.