Makefile.am | 17 --- configure.ac | 16 ++- man/Makefile.am | 12 ++ man/xbacklight.man | 58 +++++++++++ xbacklight.c | 278 +++++++++++++++++++++++++++++++---------------------- xbacklight.man | 58 ----------- 6 files changed, 248 insertions(+), 191 deletions(-)
New commits: commit 8e0f47c1971f17ac37c89fb49a8f1807d25923a5 Author: Matt Turner <matts...@gmail.com> Date: Mon Oct 7 20:43:34 2013 -0700 xbacklight 1.2.1 Signed-off-by: Matt Turner <matts...@gmail.com> diff --git a/configure.ac b/configure.ac index a811f5e..f97497d 100644 --- a/configure.ac +++ b/configure.ac @@ -23,7 +23,7 @@ dnl Process this file with autoconf to create configure. # Initialize Autoconf AC_PREREQ([2.60]) -AC_INIT([xbacklight], [1.2.0], +AC_INIT([xbacklight], [1.2.1], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [xbacklight]) AC_CONFIG_SRCDIR([Makefile.am]) commit a4c00b2662a4c7291627899021f10c6a6d4716f3 Author: Julien Cristau <jcris...@debian.org> Date: Thu Jul 11 12:03:40 2013 +0200 man: replace hyphens with minus signs Reported-by: Gianfranco Costamagna <costamagnagianfra...@yahoo.it> Signed-off-by: Julien Cristau <jcris...@debian.org> diff --git a/man/xbacklight.man b/man/xbacklight.man index 2983637..c3aa48e 100644 --- a/man/xbacklight.man +++ b/man/xbacklight.man @@ -24,32 +24,32 @@ xbacklight \- adjust backlight brightness using RandR extension .SH SYNOPSIS .B "xbacklight" -[-help] [-display \fIdisplay\fP] -[-get] -[-set percent] -[-inc percent] -[-dec percent] +[\-help] [\-display \fIdisplay\fP] +[\-get] +[\-set percent] +[\-inc percent] +[\-dec percent] .SH DESCRIPTION .I Xbacklight is used to adjust the backlight brightness where supported. It finds all outputs on the X server supporting backlight brightness control and changes them all in the same way. -.IP -get +.IP \-get Print out the current backlight brightness of each output with such a control. The brightness is represented as a percentage of the maximum brightness supported. -.IP "-set \fIpercent\fP" +.IP "\-set \fIpercent\fP" Sets each backlight brightness to the specified level. -.IP "-inc \fIpercent\fP" +.IP "\-inc \fIpercent\fP" Increases brightness by the specified amount. -.IP "-dec \fIpercent\fP" +.IP "\-dec \fIpercent\fP" Decreases brightness by the specified amount. -.IP -help +.IP \-help Print out a summary of the usage and exit. -.IP "-time \fImilliseconds\fP" +.IP "\-time \fImilliseconds\fP" Length of time to spend fading the backlight between old and new value. Default is 200. -.IP "-steps \fInumber\fP" +.IP "\-steps \fInumber\fP" Number of steps to take while fading. Default is 20. .SH "SEE ALSO" Xrandr(__libmansuffix__) commit 5d7642ffd0de1d6037f6f98b8733e8a8161e24d3 Author: Edward Sheldrake <ejsheldr...@gmail.com> Date: Sat Apr 6 13:39:38 2013 +0100 Fix reading backlight level on 64-bit systems (bug 63205) obviously incorrect output of "xbacklight -get": 51671552015166906368.000000 valgrind reports an invalid read of size 8 at xbacklight.c:91 https://bugs.freedesktop.org/show_bug.cgi?id=63205 Reviewed-by: Julien Cristau <jcris...@debian.org> Signed-off-by: Alan Coopersmith <alan.coopersm...@oracle.com> diff --git a/xbacklight.c b/xbacklight.c index 0614f03..214bd32 100644 --- a/xbacklight.c +++ b/xbacklight.c @@ -87,7 +87,7 @@ backlight_get (xcb_connection_t *conn, xcb_randr_output_t output) prop_reply->format != 32) { value = -1; } else { - value = *((long *) xcb_randr_get_output_property_data (prop_reply)); + value = *((int32_t *) xcb_randr_get_output_property_data (prop_reply)); } free (prop_reply); commit 36ffc5e0eb50fdda93af3dd7dc3899622e80d3be Author: Alan Coopersmith <alan.coopersm...@oracle.com> Date: Sat Apr 6 09:45:22 2013 -0700 Combine usage message strings Signed-off-by: Alan Coopersmith <alan.coopersm...@oracle.com> diff --git a/xbacklight.c b/xbacklight.c index 2189095..0614f03 100644 --- a/xbacklight.c +++ b/xbacklight.c @@ -40,17 +40,16 @@ static xcb_atom_t backlight, backlight_new, backlight_legacy; static void usage (void) { - fprintf(stderr, "usage: %s [options]\n", program_name); - fprintf(stderr, " where options are:\n"); - fprintf(stderr, " -display <display> or -d <display>\n"); - fprintf(stderr, " -help\n"); - fprintf(stderr, " -set <percentage> or = <percentage>\n"); - fprintf(stderr, " -inc <percentage> or + <percentage>\n"); - fprintf(stderr, " -dec <percentage> or - <percentage>\n"); - fprintf(stderr, " -get\n"); - fprintf(stderr, " -time <fade time in milliseconds>\n"); - fprintf(stderr, " -steps <number of steps in fade>\n"); - /*NOTREACHED*/ + fprintf(stderr, "usage: %s [options]\n%s", program_name, + " where options are:\n" + " -display <display> or -d <display>\n" + " -help\n" + " -set <percentage> or = <percentage>\n" + " -inc <percentage> or + <percentage>\n" + " -dec <percentage> or - <percentage>\n" + " -get\n" + " -time <fade time in milliseconds>\n" + " -steps <number of steps in fade>\n"); exit (1); } commit cc2a24b51637e8f21c9c0aed73394db67a965b62 Author: Alan Coopersmith <alan.coopersm...@oracle.com> Date: Sat Apr 6 09:40:53 2013 -0700 config: Add missing AC_CONFIG_SRCDIR Regroup AC statements under the Autoconf initialization section. Regroup AM statements under the Automake initialization section. Signed-off-by: Alan Coopersmith <alan.coopersm...@oracle.com> diff --git a/configure.ac b/configure.ac index d7eab36..a811f5e 100644 --- a/configure.ac +++ b/configure.ac @@ -21,10 +21,15 @@ dnl PERFORMANCE OF THIS SOFTWARE. dnl dnl Process this file with autoconf to create configure. +# Initialize Autoconf AC_PREREQ([2.60]) AC_INIT([xbacklight], [1.2.0], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [xbacklight]) +AC_CONFIG_SRCDIR([Makefile.am]) +AC_CONFIG_HEADERS([config.h]) + +# Initialize Automake AM_INIT_AUTOMAKE([foreign dist-bzip2]) AM_MAINTAINER_MODE @@ -34,8 +39,6 @@ m4_ifndef([XORG_MACROS_VERSION], XORG_MACROS_VERSION(1.8) XORG_DEFAULT_OPTIONS -AC_CONFIG_HEADERS([config.h]) - # Checks for pkg-config packages PKG_CHECK_MODULES(XRANDR, [xcb-randr >= 1.2 xcb-atom xcb-aux xcb]) commit 059c60e7a6ae7f6cdcf51b06ac733bb2392c2ec2 Author: Matt Turner <matts...@gmail.com> Date: Tue Sep 11 14:37:18 2012 -0700 xbacklight 1.2.0 Signed-off-by: Matt Turner <matts...@gmail.com> diff --git a/configure.ac b/configure.ac index 87c7b26..d7eab36 100644 --- a/configure.ac +++ b/configure.ac @@ -22,7 +22,7 @@ dnl dnl Process this file with autoconf to create configure. AC_PREREQ([2.60]) -AC_INIT([xbacklight], [1.1.2], +AC_INIT([xbacklight], [1.2.0], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [xbacklight]) AM_INIT_AUTOMAKE([foreign dist-bzip2]) commit 6f2668f2cede3598bad3feb1cae9e8de473d2531 Author: Jon Lund Steffensen <jon...@gmail.com> Date: Sun Aug 12 10:04:08 2012 -0700 Port xbacklight to XCB Signed-off-by: Matt Turner <matts...@gmail.com> diff --git a/configure.ac b/configure.ac index 2c67604..87c7b26 100644 --- a/configure.ac +++ b/configure.ac @@ -37,7 +37,7 @@ XORG_DEFAULT_OPTIONS AC_CONFIG_HEADERS([config.h]) # Checks for pkg-config packages -PKG_CHECK_MODULES(XRANDR, xrandr >= 1.2.0 x11) +PKG_CHECK_MODULES(XRANDR, [xcb-randr >= 1.2 xcb-atom xcb-aux xcb]) AC_CONFIG_FILES([ Makefile diff --git a/xbacklight.c b/xbacklight.c index 9b68ce8..2189095 100644 --- a/xbacklight.c +++ b/xbacklight.c @@ -21,9 +21,11 @@ */ #include <stdio.h> #include <stdlib.h> -#include <X11/Xatom.h> -#include <X11/Xlib.h> -#include <X11/extensions/Xrandr.h> + +#include <xcb/xcb.h> +#include <xcb/xcb_util.h> +#include <xcb/xproto.h> +#include <xcb/randr.h> #include <ctype.h> #include <string.h> @@ -33,7 +35,7 @@ typedef enum { Get, Set, Inc, Dec } op_t; static char *program_name; -static Atom backlight, backlight_new, backlight_legacy; +static xcb_atom_t backlight, backlight_new, backlight_legacy; static void usage (void) @@ -53,58 +55,75 @@ usage (void) } static long -backlight_get (Display *dpy, RROutput output) +backlight_get (xcb_connection_t *conn, xcb_randr_output_t output) { - unsigned long nitems; - unsigned long bytes_after; - unsigned char *prop; - Atom actual_type; - int actual_format; - long value; + xcb_generic_error_t *error; + xcb_randr_get_output_property_reply_t *prop_reply = NULL; + xcb_randr_get_output_property_cookie_t prop_cookie; + long value; backlight = backlight_new; - if (!backlight || - XRRGetOutputProperty (dpy, output, backlight, - 0, 4, False, False, None, - &actual_type, &actual_format, - &nitems, &bytes_after, &prop) != Success) { - backlight = backlight_legacy; - if (!backlight || - XRRGetOutputProperty (dpy, output, backlight, - 0, 4, False, False, None, - &actual_type, &actual_format, - &nitems, &bytes_after, &prop) != Success) - return -1; + if (backlight != XCB_ATOM_NONE) { + prop_cookie = xcb_randr_get_output_property (conn, output, + backlight, XCB_ATOM_NONE, + 0, 4, 0, 0); + prop_reply = xcb_randr_get_output_property_reply (conn, prop_cookie, &error); + if (error != NULL || prop_reply == NULL) { + backlight = backlight_legacy; + if (backlight != XCB_ATOM_NONE) { + prop_cookie = xcb_randr_get_output_property (conn, output, + backlight, XCB_ATOM_NONE, + 0, 4, 0, 0); + prop_reply = xcb_randr_get_output_property_reply (conn, prop_cookie, &error); + if (error != NULL || prop_reply == NULL) { + return -1; + } + } + } } - if (actual_type != XA_INTEGER || nitems != 1 || actual_format != 32) + if (prop_reply == NULL || + prop_reply->type != XCB_ATOM_INTEGER || + prop_reply->num_items != 1 || + prop_reply->format != 32) { value = -1; - else - value = *((long *) prop); - XFree (prop); + } else { + value = *((long *) xcb_randr_get_output_property_data (prop_reply)); + } + + free (prop_reply); return value; } static void -backlight_set (Display *dpy, RROutput output, long value) +backlight_set (xcb_connection_t *conn, xcb_randr_output_t output, long value) { - XRRChangeOutputProperty (dpy, output, backlight, XA_INTEGER, 32, - PropModeReplace, (unsigned char *) &value, 1); + xcb_randr_change_output_property (conn, output, backlight, XCB_ATOM_INTEGER, + 32, XCB_PROP_MODE_REPLACE, + 1, (unsigned char *)&value); } int main (int argc, char **argv) { char *dpy_name = NULL; - Display *dpy; - int screen; - int major, minor; op_t op = Get; int value = 0; int i; int total_time = 200; /* ms */ int steps = 20; + xcb_connection_t *conn; + xcb_generic_error_t *error; + + xcb_randr_query_version_cookie_t ver_cookie; + xcb_randr_query_version_reply_t *ver_reply; + + xcb_intern_atom_cookie_t backlight_cookie[2]; + xcb_intern_atom_reply_t *backlight_reply; + + xcb_screen_iterator_t iter; + program_name = argv[0]; for (i = 1; i < argc; i++) @@ -177,97 +196,133 @@ main (int argc, char **argv) } usage (); } - dpy = XOpenDisplay (dpy_name); - if (!dpy) - { - fprintf (stderr, "Cannot open display \"%s\"\n", - XDisplayName (dpy_name)); + conn = xcb_connect (dpy_name, NULL); + ver_cookie = xcb_randr_query_version (conn, 1, 2); + ver_reply = xcb_randr_query_version_reply (conn, ver_cookie, &error); + if (error != NULL || ver_reply == NULL) { + int ec = error ? error->error_code : -1; + fprintf (stderr, "RANDR Query Version returned error %d\n", ec); exit (1); } - if (!XRRQueryVersion (dpy, &major, &minor)) - { - fprintf (stderr, "RandR extension missing\n"); + if (ver_reply->major_version != 1 || + ver_reply->minor_version < 2) { + fprintf (stderr, "RandR version %d.%d too old\n", + ver_reply->major_version, ver_reply->minor_version); exit (1); } - if (major < 1 || (major == 1 && minor < 2)) - { - fprintf (stderr, "RandR version %d.%d too old\n", major, minor); + free (ver_reply); + + backlight_cookie[0] = xcb_intern_atom (conn, 1, strlen("Backlight"), "Backlight"); + backlight_cookie[1] = xcb_intern_atom (conn, 1, strlen("BACKLIGHT"), "BACKLIGHT"); + + backlight_reply = xcb_intern_atom_reply (conn, backlight_cookie[0], &error); + if (error != NULL || backlight_reply == NULL) { + int ec = error ? error->error_code : -1; + fprintf (stderr, "Intern Atom returned error %d\n", ec); exit (1); } - backlight_new = XInternAtom (dpy, "Backlight", True); - backlight_legacy = XInternAtom (dpy, "BACKLIGHT", True); - if (backlight_new == None && backlight_legacy == None) - { + backlight_new = backlight_reply->atom; + free (backlight_reply); + + backlight_reply = xcb_intern_atom_reply (conn, backlight_cookie[1], &error); + if (error != NULL || backlight_reply == NULL) { + int ec = error ? error->error_code : -1; + fprintf (stderr, "Intern Atom returned error %d\n", ec); + exit (1); + } + + backlight_legacy = backlight_reply->atom; + free (backlight_reply); + + if (backlight_new == XCB_NONE && backlight_legacy == XCB_NONE) { fprintf (stderr, "No outputs have backlight property\n"); exit (1); } - for (screen = 0; screen < ScreenCount (dpy); screen++) - { - Window root = RootWindow (dpy, screen); - XRRScreenResources *resources = XRRGetScreenResources (dpy, root); - int o; - - if (!resources) continue; - for (o = 0; o < resources->noutput; o++) + + iter = xcb_setup_roots_iterator (xcb_get_setup (conn)); + while (iter.rem) { + xcb_screen_t *screen = iter.data; + xcb_window_t root = screen->root; + xcb_randr_output_t *outputs; + + xcb_randr_get_screen_resources_cookie_t resources_cookie; + xcb_randr_get_screen_resources_reply_t *resources_reply; + + resources_cookie = xcb_randr_get_screen_resources (conn, root); + resources_reply = xcb_randr_get_screen_resources_reply (conn, resources_cookie, &error); + if (error != NULL || resources_reply == NULL) { + int ec = error ? error->error_code : -1; + fprintf (stderr, "RANDR Get Screen Resources returned error %d\n", ec); + continue; + } + + outputs = xcb_randr_get_screen_resources_outputs (resources_reply); + for (int o = 0; o < resources_reply->num_outputs; o++) { - RROutput output = resources->outputs[o]; - XRRPropertyInfo *info; + xcb_randr_output_t output = outputs[o]; double cur, new, step; double min, max; double set; - cur = backlight_get (dpy, output); + cur = backlight_get (conn, output); if (cur != -1) { - info = XRRQueryOutputProperty (dpy, output, backlight); - if (info) - { - if (info->range && info->num_values == 2) - { - min = info->values[0]; - max = info->values[1]; - if (op == Get) { - printf ("%f\n", (cur - min) * 100 / (max - min)); - } else { - set = value * (max - min) / 100; - switch (op) { - case Set: - new = min + set; - break; - case Inc: - new = cur + set; - break; - case Dec: - new = cur - set; - break; - default: - XSync (dpy, False); - return 1; - } - if (new > max) new = max; - if (new < min) new = min; - step = (new - cur) / steps; - for (i = 0; i < steps && step != 0; i++) - { - if (i == steps - 1) - cur = new; - else - cur += step; - backlight_set (dpy, output, (long) cur); - XFlush (dpy); - usleep (total_time * 1000 / steps); - } + xcb_randr_query_output_property_cookie_t prop_cookie; + xcb_randr_query_output_property_reply_t *prop_reply; + + prop_cookie = xcb_randr_query_output_property (conn, output, backlight); + prop_reply = xcb_randr_query_output_property_reply (conn, prop_cookie, &error); + + if (error != NULL || prop_reply == NULL) continue; + + if (prop_reply->range && + xcb_randr_query_output_property_valid_values_length (prop_reply) == 2) { + int32_t *values = xcb_randr_query_output_property_valid_values (prop_reply); + min = values[0]; + max = values[1]; + + if (op == Get) { + printf ("%f\n", (cur - min) * 100 / (max - min)); + } else { + set = value * (max - min) / 100; + switch (op) { + case Set: + new = min + set; + break; + case Inc: + new = cur + set; + break; + case Dec: + new = cur - set; + break; + default: + xcb_aux_sync (conn); + return 1; + } + if (new > max) new = max; + if (new < min) new = min; + step = (new - cur) / steps; + for (i = 0; i < steps && step != 0; i++) + { + if (i == steps - 1) + cur = new; + else + cur += step; + backlight_set (conn, output, (long) cur); + xcb_flush (conn); + usleep (total_time * 1000 / steps); } } - XFree (info); } + free (prop_reply); } } - - XRRFreeScreenResources (resources); + + free (resources_reply); + xcb_screen_next (&iter); } - XSync (dpy, False); + xcb_aux_sync (conn); return 0; } commit a18911abb94ef0cfa55282b96027f501a82652a6 Author: Gaetan Nadon <mems...@videotron.ca> Date: Wed Jan 19 10:06:55 2011 -0500 config: move man pages into their own directory Use services provided by XORG_MANPAGE_SECTIONS. Use standard Makefile for man pages. Signed-off-by: Gaetan Nadon <mems...@videotron.ca> diff --git a/Makefile.am b/Makefile.am index 7d85683..4b67745 100644 --- a/Makefile.am +++ b/Makefile.am @@ -21,6 +21,7 @@ AUTOMAKE_OPTIONS = foreign +SUBDIRS = man bin_PROGRAMS = xbacklight AM_CFLAGS = $(CWARNFLAGS) $(XRANDR_CFLAGS) @@ -29,23 +30,7 @@ xbacklight_LDADD = $(XRANDR_LIBS) xbacklight_SOURCES = \ xbacklight.c -appman_PRE = \ - xbacklight.man - -appmandir = $(APP_MAN_DIR) - -appman_DATA = $(appman_PRE:man=@APP_MAN_SUFFIX@) - -EXTRA_DIST = $(appman_PRE) MAINTAINERCLEANFILES = ChangeLog INSTALL -CLEANFILES = $(appman_DATA) - -SUFFIXES = .$(APP_MAN_SUFFIX) .man - -# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure -.man.$(APP_MAN_SUFFIX): - $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@ - .PHONY: ChangeLog INSTALL diff --git a/configure.ac b/configure.ac index ed690c5..2c67604 100644 --- a/configure.ac +++ b/configure.ac @@ -39,4 +39,7 @@ AC_CONFIG_HEADERS([config.h]) # Checks for pkg-config packages PKG_CHECK_MODULES(XRANDR, xrandr >= 1.2.0 x11) -AC_OUTPUT([Makefile]) +AC_CONFIG_FILES([ + Makefile + man/Makefile]) +AC_OUTPUT diff --git a/man/Makefile.am b/man/Makefile.am new file mode 100644 index 0000000..9505afd --- /dev/null +++ b/man/Makefile.am @@ -0,0 +1,12 @@ + +appmandir = $(APP_MAN_DIR) +appman_PRE = xbacklight.man +appman_DATA = $(appman_PRE:man=$(APP_MAN_SUFFIX)) + +EXTRA_DIST = $(appman_PRE) +CLEANFILES = $(appman_DATA) +SUFFIXES = .$(APP_MAN_SUFFIX) .man + +# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure +.man.$(APP_MAN_SUFFIX): + $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@ diff --git a/man/xbacklight.man b/man/xbacklight.man new file mode 100644 index 0000000..2983637 --- /dev/null +++ b/man/xbacklight.man @@ -0,0 +1,58 @@ +.\" +.\" Copyright © 2007 Keith Packard.\" +.\" Permission to use, copy, modify, distribute, and sell this software and its +.\" documentation for any purpose is hereby granted without fee, provided that +.\" the above copyright notice appear in all copies and that both that +.\" copyright notice and this permission notice appear in supporting +.\" documentation, and that the name of Keith Packard not be used in +.\" advertising or publicity pertaining to distribution of the software without +.\" specific, written prior permission. Keith Packard makes no +.\" representations about the suitability of this software for any purpose. It +.\" is provided "as is" without express or implied warranty. +.\" +.\" KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, +.\" INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO +.\" EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR +.\" CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, +.\" DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER +.\" TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +.\" PERFORMANCE OF THIS SOFTWARE. +.\" +.\" +.TH XBACKLIGHT __appmansuffix__ __vendorversion__ +.SH NAME +xbacklight \- adjust backlight brightness using RandR extension +.SH SYNOPSIS +.B "xbacklight" +[-help] [-display \fIdisplay\fP] +[-get] +[-set percent] +[-inc percent] +[-dec percent] +.SH DESCRIPTION +.I Xbacklight +is used to adjust the backlight brightness where supported. It finds all +outputs on the X server supporting backlight brightness control and changes +them all in the same way. +.IP -get +Print out the current backlight brightness of each output with such a +control. The brightness is represented as a percentage of the maximum +brightness supported. +.IP "-set \fIpercent\fP" +Sets each backlight brightness to the specified level. +.IP "-inc \fIpercent\fP" +Increases brightness by the specified amount. +.IP "-dec \fIpercent\fP" +Decreases brightness by the specified amount. +.IP -help +Print out a summary of the usage and exit. +.IP "-time \fImilliseconds\fP" +Length of time to spend fading the backlight between old and new value. +Default is 200. +.IP "-steps \fInumber\fP" +Number of steps to take while fading. Default is 20. +.SH "SEE ALSO" +Xrandr(__libmansuffix__) +.SH AUTHORS +Keith Packard, +Open Source Technology Center, Intel Corporation. diff --git a/xbacklight.man b/xbacklight.man deleted file mode 100644 index 2983637..0000000 --- a/xbacklight.man +++ /dev/null @@ -1,58 +0,0 @@ -.\" -.\" Copyright © 2007 Keith Packard.\" -.\" Permission to use, copy, modify, distribute, and sell this software and its -.\" documentation for any purpose is hereby granted without fee, provided that -.\" the above copyright notice appear in all copies and that both that -.\" copyright notice and this permission notice appear in supporting -.\" documentation, and that the name of Keith Packard not be used in -.\" advertising or publicity pertaining to distribution of the software without -.\" specific, written prior permission. Keith Packard makes no -.\" representations about the suitability of this software for any purpose. It -.\" is provided "as is" without express or implied warranty. -.\" -.\" KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, -.\" INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO -.\" EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR -.\" CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, -.\" DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER -.\" TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR -.\" PERFORMANCE OF THIS SOFTWARE. -.\" -.\" -.TH XBACKLIGHT __appmansuffix__ __vendorversion__ -.SH NAME -xbacklight \- adjust backlight brightness using RandR extension -.SH SYNOPSIS -.B "xbacklight" -[-help] [-display \fIdisplay\fP] -[-get] -[-set percent] -[-inc percent] -[-dec percent] -.SH DESCRIPTION -.I Xbacklight -is used to adjust the backlight brightness where supported. It finds all -outputs on the X server supporting backlight brightness control and changes -them all in the same way. -.IP -get -Print out the current backlight brightness of each output with such a -control. The brightness is represented as a percentage of the maximum -brightness supported. -.IP "-set \fIpercent\fP" -Sets each backlight brightness to the specified level. -.IP "-inc \fIpercent\fP" -Increases brightness by the specified amount. -.IP "-dec \fIpercent\fP" -Decreases brightness by the specified amount. -.IP -help -Print out a summary of the usage and exit. -.IP "-time \fImilliseconds\fP" -Length of time to spend fading the backlight between old and new value. -Default is 200. -.IP "-steps \fInumber\fP" -Number of steps to take while fading. Default is 20. -.SH "SEE ALSO" -Xrandr(__libmansuffix__) -.SH AUTHORS -Keith Packard, -Open Source Technology Center, Intel Corporation. commit 8bc2e5a8888de4d457870986f442b628e4795364 Author: Gaetan Nadon <mems...@videotron.ca> Date: Thu Jan 13 17:15:36 2011 -0500 man: replace hard coded man page section with substitution strings Signed-off-by: Gaetan Nadon <mems...@videotron.ca> diff --git a/xbacklight.man b/xbacklight.man index e415035..2983637 100644 --- a/xbacklight.man +++ b/xbacklight.man @@ -52,7 +52,7 @@ Default is 200. .IP "-steps \fInumber\fP" Number of steps to take while fading. Default is 20. .SH "SEE ALSO" -Xrandr(3) +Xrandr(__libmansuffix__) .SH AUTHORS Keith Packard, Open Source Technology Center, Intel Corporation. commit ae1445b4ce52ecc739faee1e69ab9f51d0ad90f3 Author: Gaetan Nadon <mems...@videotron.ca> Date: Wed Jan 12 16:28:02 2011 -0500 config: replace deprecated AM_CONFIG_HEADER with AC_CONFIG_HEADERS This silences an Autoconf warning diff --git a/configure.ac b/configure.ac index 85ebde4..ed690c5 100644 --- a/configure.ac +++ b/configure.ac @@ -34,7 +34,7 @@ m4_ifndef([XORG_MACROS_VERSION], XORG_MACROS_VERSION(1.8) XORG_DEFAULT_OPTIONS -AM_CONFIG_HEADER(config.h) +AC_CONFIG_HEADERS([config.h]) # Checks for pkg-config packages PKG_CHECK_MODULES(XRANDR, xrandr >= 1.2.0 x11) commit 3d55286af9f597d81099f58c7236a920d02c7519 Author: Gaetan Nadon <mems...@videotron.ca> Date: Mon Apr 5 20:42:20 2010 -0400 config: the file COPYING in EXTRA_DIST is redundant COPYING is a filename known to Automake and does not need to be on EXTRA_DIST. Signed-off-by: Gaetan Nadon <mems...@videotron.ca> diff --git a/Makefile.am b/Makefile.am index bd25ded..7d85683 100644 --- a/Makefile.am +++ b/Makefile.am @@ -36,7 +36,7 @@ appmandir = $(APP_MAN_DIR) appman_DATA = $(appman_PRE:man=@APP_MAN_SUFFIX@) -EXTRA_DIST = $(appman_PRE) COPYING +EXTRA_DIST = $(appman_PRE) MAINTAINERCLEANFILES = ChangeLog INSTALL CLEANFILES = $(appman_DATA) -- To UNSUBSCRIBE, email to debian-x-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: https://lists.debian.org/e1x60pl-0001tm...@moszumanska.debian.org