Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- rofi-shutdown-menu.sh
- #!/bin/bash
- icons_dir="$HOME/.config/awesome/icons2"
- shutdown="$icons_dir/system-shutdown.svg";
- reboot="$icons_dir/system-reboot.svg";
- sleep="$icons_dir/system-suspend.svg";
- logout="$icons_dir/system-log-out.svg";
- lock="$icons_dir/system-lock-screen.svg";
- options="shutdown\0icon\x1f$shutdown\nreboot\0icon\x1f$reboot\nsleep\0icon\x1f$sleep\nlogout\0icon\x1f$logout\nlock\0icon\x1f$lock"
- selected="$(echo -e $options | rofi-1.6.1 -font "Helvetica Neue, 18" -show-icons -theme .config/rofi/theme-shutdown.rasi -p " " -dmenu )"
- case $selected in
- shutdown)
- systemctl poweroff
- ;;
- reboot)
- systemctl reboot
- ;;
- sleep)
- systemctl suspend
- ;;
- logout)
- echo "awesome.quit()" | awesome-client
- ;;
- lock)
- #slock
- scrot -m -z /tmp/screen.png
- convert /tmp/screen.png -scale 10% -scale 1000% /tmp/blur.png
- rm /tmp/screen.png
- i3lock -i /tmp/blur.png
- rm /tmp/blur.png
- xset dpms force off
- ;;
- esac
- /*
- * Rofi theme for fullscreen powermenu
- */
- * {
- content-position: 25% 4% 25% 4%;
- space-between-options: 1%;
- /*option-inset-padding: 4.1% 2.6% 2.5% -4.1%;*/
- option-inset-padding: 1%;
- window-bg-color: rgba(15, 15, 15, 0.7);
- title-text-color: rgba(141, 145, 148, 1);
- selected-bg-color: rgba(100, 100, 100, 0.4);
- unselected-bg-color: rgba(100, 100, 100, 0.05);
- selected-text-color: #FFFFFF;
- unselected-text-color: #FFFFFF;
- }
- #window {
- width: 100%;
- height: 100%;
- x-offset: 0%;
- y-offset: 0%;
- padding: @content-position;
- background-color: @window-bg-color;
- children: [ inputbar, horibox ];
- }
- #inputbar {
- children: [ prompt ];
- margin: @title-margins;
- background-color: transparent;
- }
- prompt {
- text-color: @selected-text-color;
- background-color: transparent;
- }
- #horibox {
- background-color: transparent;
- children: [ listview ];
- }
- #listview {
- layout: horizontal;
- background-color: transparent;
- spacing: @space-between-options;
- lines: 5;
- }
- #element {
- text-color: @unselected-text-color;
- padding: 0px;
- border-radius: 50%;
- background-color: @unselected-bg-color;
- }
- #element-icon {
- size: 96;
- padding: 0px;
- }
- #element-text {
- horizontal-align: 0;
- padding: 2%;
- }
- #element.selected {
- text-color: @selected-text-color;
- background-color: @selected-bg-color;
- padding: 0px;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement