This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* dependencies */ | |
| #pragma comment(lib, "dxva2") | |
| #pragma comment(lib, "user32") | |
| #include <lowlevelmonitorconfigurationapi.h> | |
| typedef struct _MONITORPOWERPARAM | |
| { | |
| LPCWSTR szPhysicalMonitorDescription; | |
| BOOL bPowerOn; | |
| } MONITOR_POWER_PARAM, *PMONITOR_POWER_PARAM; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # | |
| # rotate_desktop.sh | |
| # | |
| # Rotates modern Linux desktop screen and input devices to match. Handy for | |
| # convertible notebooks. Call this script from panel launchers, keyboard | |
| # shortcuts, or touch gesture bindings (xSwipe, touchegg, etc.). | |
| # | |
| # Using transformation matrix bits taken from: | |
| # https://wiki.ubuntu.com/X/InputCoordinateTransformation |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #! /bin/sh | |
| # static icon, easier to set as a bash alias or directly use as a single command instead of creating a script file. | |
| amixer set Capture toggle | gawk 'match($0, /Front Left.*\[(.*)\]/, a) {print a[1]}' | xargs notify-send --hint=int:transient:1 -i "audio-input-microphone" "Mic switched: $1" |