xclock(1X)
NAME
xclock - X Window System analog or digital clock
SYNTAX
xclock [ options ] [ geometry ] [ display ]
ARGUMENTS
geometrySpecifies the width, length, and location of the xclock window. If the geometry argument is not specified, xclock uses mouse input. For further information, see DESCRIPTION.
The geometry argument has the format =[width][xlength][x][y].
widthSpecifies the number of pixels of the window’s horizontal dimension.
lengthSpecifies the number of pixels of the window’s vertical dimension.
xSpecifies the x screen coordinate (pixel value) for the starting corner of the window.
ySpecifies the y screen coordinate (pixel value) for the starting corner of the window.
Depending on which corner of the screen each is relative to, both the x and y coordinates must be preceded by a plus (+) or a minus (−). For more information about the screen coordinate system, see X(.).
In digital mode, if either the width or length is not specified, they are both determined by the font size. In analog mode, if either the width or length is not specified, they both default to 164 pixels.
displaySpecifies the display screen on which the xclock displays its window. If the display argument is not specified, xclock uses the display screen specified by your DISPLAY environment variable. The display argument has the format hostname:number.
hostnameSpecifies the name of the host machine on which the display is connected. You can specify the name local to use shared memory, the name unix to use UNIX IPC, or the name of your host machine to use TCP.
numberSpecifies the number of the display on that host machine.
DESCRIPTION
The xclock command creates a window that continuously displays the X Window System clock in a format specified on the command line. The specified format can be either analog or digital.
If the geometry argument is not specified, position and size the xclock window with the mouse by pressing one of the following mouse buttons:
LeftPositions the upper left corner of the window at the mouse pointer and sizes the window with a default width and length (164x164).
MiddlePositions the starting point of the window at the mouse pointer and sizes the window to a width and length determined by mouse movement.
RightPositions the lower right corner of the window at −0−0 and sizes the window with a default width and length (164x164).
To remove the xclock window, place the mouse pointer in the xclock window and type CTRL-C.
OPTIONS
−analog Specifies that xclock display an analog clock with a 12-hour clock face (ticks for each minute, stroke marks for each hour). If not specified, a digital clock is displayed.
−bg color Specifies the color of the window’s background (color displays only). The default color is white.
−bd color Specifies the color of the window’s border (color displays only). The default color is black.
−bw pixels Specifies the width (in pixels) of the window’s border.
−digital Specifies that xclock display a digital clock (default).
−fg color Specifies the color of the text in digital mode and the color of the tick marks in analog mode (color displays only). The default color is black.
−fn font Specifies the font used as the output font in digital mode. Any fixed-width font may be used. The default is 6x10.
−hd color Specifies the color of the hands of the clock (color displays only).
−help Displays a brief summary of the calling syntax and options of xclock.
−hl color Specifies the color of the hands in analog mode (color displays only). The default is the foreground color.
−padding pixels Specifies the width (in pixels) of the padding or white space between the window border and anything xclock displays. In digital mode, the default padding is 10. In analog mode, the default padding is 8.
−rv Reverses the default color values (for example, black becomes white and white becomes black).
−update seconds Specifies the frequency in seconds with which xclock updates its display. If the xclock window is obscured and then exposed, xclock overrides this setting and redisplays immediately. The default update frequency is 60 seconds. The specification of an update frequency greater than 30 seconds disables the display of the second hand in analog mode.
−chime Specifies that the clock chimes once on the half hour and twice on the hour.
RESTRICTIONS
When specifying the window size manually, in digital mode, the string is not centered automatically.
X DEFAULTS
Like most X-based applications, xclock reads the .Xdefaults file during start-up and uses the appropriate resource specification to customize the appearance or characteristics of its displayed xclock window. The format for a resource specification in the .Xdefaults file is: [name.]resource:value
nameSpecifies the application name or, in the case of X Toolkit-based applications, the name string that restricts the resource assignment to that application or to a component of an application. If this argument is not specified, the resource assignment is globally available to all X applications.
resourceSpecifies the X resource.
valueSpecifies the value that is to be assigned to the resource.
For xclock, the available name is xclock.
For xclock, the available resources are:
Foreground Specifies the foreground color of the window (color displays only).
Background Specifies the background color of the window (color displays only).
Hands Specifies the color of the hands (color displays only).
Border Specifies the border color of the window (color displays only).
BorderWidth Specifies the border width of the window.
BodyFont Specifies the digital clock display font.
Highlight Specifies the highlight color (color displays only).
InternalBorder Specifies the internal padding value.
Mode Specifies if analog or digital mode is the default.
ReverseVideo Specifies that, when set to on, xclock reverses the default colors (monochrome displays only).
Update Specifies the update period.