Difference between revisions of "Light"

From ArchWiki
Jump to: navigation, search
(Features)
Line 4: Line 4:
 
== Features ==
 
== Features ==
  
Light is a bit heavier than LightScript, but still pretty minimal. It features:
+
* Works excellent where other software has been proven to be unusable or problematic, thanks to how it operates internally and to the fact that it does not rely on xorg.
 
+
* Can automatically figure out the best controller to use, making full use of underlying hardware.
* Written in ANSI-C89 for ũber-portability and speed!
+
* Possibillity to set a minimum brightness value, as some controllers set the screen to be pitch black at a value of 0 (or higher).
* Automatically finds the controller with the '''best''' resolution, and uses it to set the brightness.
 
* Uses a minimum cap of 5% lightness as standard, which can be easily changed using the /etc/light/minlight file. (Some controllers will turn the screen pitchblack on 0%)
 
* Is very forgiving on "bad systems", while still doing a lot of safety-checks. Also allows you to override the controller-detection and decide what controller you would like to use by the /etc/light/override-file.
 
  
 
== Installation ==
 
== Installation ==
  
It is available on AUR where it goes by the name {{AUR|light}}, the only runtime-dependency it has is glibc, and the only build-dependency it has is git. For manual install, see http://haikarainen.se/light
+
It is available on AUR where it goes by the name {{AUR|light}}, the only runtime-dependency it has is glibc, and the only build-dependency it has is git. For manual install, see https://github.com/haikarainen/light
  
 
== Usage ==
 
== Usage ==
  
To see full usage, just type;
+
For detailed usage instructions:
  $ light --help
+
  $ light -h
  
 
Basic usage follows:
 
Basic usage follows:
  
 
  // Set the brightness of the screen to 30%
 
  // Set the brightness of the screen to 30%
  $ light 30
+
  $ light -S 30
  
  // Increase brightness by 10% and suppress output
+
  // Increase brightness by 10%
  $ light -aq 10
+
  $ light -A 10
  
 
  // Print the current brightness in percent (unprecise)
 
  // Print the current brightness in percent (unprecise)
  $ light -c
+
  $ light -G
 
 
To override the default minimum-cap of 5%, just put an unsigned integer into /etc/light/minlight.
 
 
 
To override the controller-detection and decide what controller to use, put the controllers filename into /etc/light/override, for example if the controller is "/sys/class/backlight/intel_backlight/", you put "intel_backlight" (without quotes) into /etc/light/override.
 
 
 
'''Protip:''' To make light executable by users who aren't root (to replace the auto-sudo lightscript has), issue the following commands as root after it is installed:
 
$ chown root /etc/light/light
 
$ chmod a+xs /etc/light/light
 
  
 
== Bugs/Feedback ==
 
== Bugs/Feedback ==
  
 
Please give bugs/feedback directly on the AUR-page comments.
 
Please give bugs/feedback directly on the AUR-page comments.

Revision as of 21:06, 5 July 2014

Light is a program used to easily control a screens backlight-controllers. It is the successor of LightScript, and is also its official C-port.

Features

  • Works excellent where other software has been proven to be unusable or problematic, thanks to how it operates internally and to the fact that it does not rely on xorg.
  • Can automatically figure out the best controller to use, making full use of underlying hardware.
  • Possibillity to set a minimum brightness value, as some controllers set the screen to be pitch black at a value of 0 (or higher).

Installation

It is available on AUR where it goes by the name lightAUR, the only runtime-dependency it has is glibc, and the only build-dependency it has is git. For manual install, see https://github.com/haikarainen/light

Usage

For detailed usage instructions:

$ light -h

Basic usage follows:

// Set the brightness of the screen to 30%
$ light -S 30
// Increase brightness by 10%
$ light -A 10
// Print the current brightness in percent (unprecise)
$ light -G

Bugs/Feedback

Please give bugs/feedback directly on the AUR-page comments.