diff --git a/man/xrandr.man b/man/xrandr.man index a0b9129..b32ce4e 100644 --- a/man/xrandr.man +++ b/man/xrandr.man @@ -24,7 +24,7 @@ xrandr \- primitive command line interface to RandR extension .SH SYNOPSIS .B "xrandr" -[\-help] [\-display \fIdisplay\fP] +[\-\-help] [\-\-display \fIdisplay\fP] [\-q] [\-v] [\-\-verbose] [\-\-dryrun] @@ -81,7 +81,7 @@ There are a few global options. Other options modify the last output that is specified in earlier parameters in the command line. Multiple outputs may be modified at the same time by passing multiple \-\-output options followed immediately by their corresponding modifying options. -.IP \-help +.IP \-\-help Print out a summary of the usage and exit. .IP "\-v, \-\-version" Print out the RandR version reported by the X server and exit. @@ -101,7 +101,7 @@ Performs all the actions specified except that no changes are made. Apply the modifications without grabbing the screen. It avoids to block other applications during the update but it might also cause some applications that detect screen resize to receive old values. -.IP "\-d, \-display \fIname\fP" +.IP "\-d, \-\-display \fIname\fP" This option selects the X display to use. Note this refers to the X screen abstraction, not the monitor (or output). .IP "\-\-screen \fIsnum\fP" diff --git a/xrandr.c b/xrandr.c index bcaf247..6ba07a9 100644 --- a/xrandr.c +++ b/xrandr.c @@ -95,8 +95,8 @@ usage(void) { fprintf(stderr, "usage: %s [options]\n", program_name); fprintf(stderr, " where options are:\n"); - fprintf(stderr, " -display or -d \n"); - fprintf(stderr, " -help\n"); + fprintf(stderr, " --display or -d \n"); + fprintf(stderr, " --help\n"); fprintf(stderr, " -o \n"); fprintf(stderr, " or --orientation \n"); fprintf(stderr, " -q or --query\n"); @@ -2258,12 +2258,12 @@ main (int argc, char **argv) program_name = argv[0]; for (i = 1; i < argc; i++) { - if (!strcmp ("-display", argv[i]) || !strcmp ("-d", argv[i])) { + if (!strcmp ("-display", argv[i]) || !strcmp ("--display", argv[i]) || !strcmp ("-d", argv[i])) { if (++i>=argc) usage (); display_name = argv[i]; continue; } - if (!strcmp("-help", argv[i])) { + if (!strcmp("-help", argv[i]) || !strcmp("--help", argv[i])) { usage(); action_requested = True; continue;