summaryrefslogtreecommitdiff
path: root/src/lib.rs
Commit message (Collapse)AuthorAgeFilesLines
* bin: implement led revertPhilipp Gesang2021-12-121-0/+3
| | | | | | | | | | | | Command: $ vtcol leds set --revert Implementing this detail of KDSETLED: [I]f a higher order bit is set, the LEDs revert to normal: displaying the state of the keyboard functions of caps lock, num lock, and scroll lock.
* bin: implement “leds set” subcommandPhilipp Gesang2021-12-121-1/+27
| | | | | | | Currently only supports setting the raw state from an integer value: $ vtcol leds set -8 2
* add KDGETLED subcommand to vtcol-binPhilipp Gesang2021-12-081-1/+27
| | | | | | | | | Actually we add both subcommand and sub-subcommand. Example: [*] 15:52:40 phg@acheron vtcol $ vtcol leds get Caps: false, Num: true, Scroll: false
* add ioctl wrappers for KDGETLED / KDSETLEDPhilipp Gesang2021-12-081-5/+119
|
* move base64 handling out of PalettePhilipp Gesang2021-11-251-14/+19
| | | | | Try and not encumber the lower level types with more dependencies than needed.
* don’t panic!() on open(2) failurePhilipp Gesang2021-11-241-10/+10
|
* add base64 input for ‘set’Philipp Gesang2021-11-241-0/+31
|
* add base64 output for ‘get’Philipp Gesang2021-11-241-1/+5
|
* optionally clear after each fade stepPhilipp Gesang2021-11-231-3/+13
|
* implement fadingPhilipp Gesang2021-11-231-1/+98
| | | | vtcol fade --ms 1000 --frequency 10 --to solarized & dmesg
* get rid of useless lifetimesPhilipp Gesang2021-11-221-5/+5
|
* switch RawPalette to integer representationPhilipp Gesang2021-11-161-48/+93
| | | | | Introducing a simple type for RGB colors. That awkward string representation for RawPalette got unwieldy quick.
* add KDGKBTYPE wrapperPhilipp Gesang2021-11-151-8/+14
|
* namespace ioctl related symbolsPhilipp Gesang2021-11-151-45/+53
|
* move console handling into libPhilipp Gesang2021-11-151-5/+152
| | | | | All operations are now exposed through wrappers that are member functions of ``vtcol::Console``.
* use idiomatic syscall error wrappersPhilipp Gesang2021-11-151-24/+48
| | | | | A simplified version of the function used in std which aren’t made public.
* turn Fd into proper wrapperPhilipp Gesang2021-11-151-5/+25
|
* lib: split out libraryPhilipp Gesang2021-11-151-0/+528
Not really a satisfactorily clean split as of yet but it’s a start. Error types have been changed from anyhow to io::Error in ``lib.rs`` so as to not force an error handling crate on downstream users.