.twmrc 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189
  1. #---------------------------------
  2. # CPI # PROJ. : DT.R01.twmrc
  3. # # FILE : .twmrc
  4. # + # VER. : 20220228.0718UTC
  5. # + # EMAIL : hal@clockworkpi.com
  6. # +++ # HOST : clockworkpi.com
  7. #---------------------------------
  8. NoGrabServer
  9. RestartPreviousState
  10. DecorateTransients
  11. RandomPlacement
  12. BorderWidth 2
  13. NoHighlight
  14. OpaqueMove
  15. MenuBorderWidth 1
  16. NoMenuShadows
  17. NoDefaults
  18. LeftTitleButton "~/.twm/close" = f.delete
  19. RightTitleButton "~/.twm/iconify" = f.iconify
  20. RightTitleButton "~/.twm/resize" = f.resize
  21. RightTitleButton "~/.twm/fullsize" = f.fullzoom
  22. TitleFont "-adobe-helvetica-bold-r-normal--*-100-*-*-*-*-*-*"
  23. ResizeFont "-adobe-helvetica-bold-r-normal--*-100-*-*-*-*-*-*"
  24. MenuFont "-misc-fixed-medium-r-normal--15-*-*-*-*-*-*-*"
  25. IconFont "-adobe-helvetica-bold-r-normal--*-100-*-*-*-*-*-*"
  26. IconManagerFont "-adobe-helvetica-bold-r-normal--*-100-*-*-*"
  27. Color
  28. {
  29. BorderColor "grey30"
  30. DefaultBackground "rgb:5/5/5"
  31. DefaultForeground "gray80"
  32. TitleBackground "rgb:5/5/5"
  33. TitleForeground "gray80"
  34. MenuBackground "rgb:5/5/5"
  35. MenuForeground "gray80"
  36. MenuTitleBackground "gray80"
  37. MenuTitleForeground "rgb:5/5/5"
  38. MenuBorderColor "gray60"
  39. IconBackground "rgb:4/4/4"
  40. IconForeground "gray80"
  41. IconBorderColor "gray70"
  42. IconManagerBackground "rgb:5/5/5"
  43. IconManagerForeground "gray80"
  44. }
  45. Cursors
  46. {
  47. Menu "hand2"
  48. }
  49. ForceIcons
  50. Icons
  51. {
  52. "xterm" "~/.twm/xlogo32"
  53. "vmplayer" "~/.twm/xlogo32"
  54. "thunderbird" "~/.twm/xlogo32"
  55. "org.remmina.Remmina" "~/.twm/xlogo32"
  56. }
  57. MoveDelta 3
  58. Function "move-or-lower" { f.move f.deltastop f.lower }
  59. Function "move-or-raise" { f.move f.deltastop f.raise }
  60. Function "move-or-iconify" { f.move f.deltastop f.iconify }
  61. Button1 = : root : f.menu "main"
  62. Button3 = : root : f.menu "exec"
  63. Button1 = m : window|icon : f.function "move-or-raise"
  64. Button2 = m : window|icon : f.iconify
  65. Button3 = m : window|icon : f.resize
  66. Button1 = : title : f.function "move-or-raise"
  67. Button2 = : title : f.raiselower
  68. Button1 = : icon : f.function "move-or-iconify"
  69. Button2 = : icon : f.iconify
  70. Button1 = : iconmgr : f.iconify
  71. Button2 = : iconmgr : f.iconify
  72. NoTitle
  73. {
  74. "gkrellm"
  75. }
  76. menu "main"
  77. {
  78. ":: Dphys ::" f.title
  79. "Raise..." f.raise
  80. "Lower..." f.lower
  81. "Focus..." f.focus
  82. "Unfocus..." f.unfocus
  83. "Show Iconmgr" ("gray80":"#445255") f.showiconmgr
  84. "Hide Iconmgr" ("gray80":"#445255") f.hideiconmgr
  85. "Kill..." f.destroy
  86. "Restart TWM" f.restart
  87. "Exit" ("gray80":"#773333") f.menu "exit"
  88. }
  89. menu "exit"
  90. {
  91. "Are you sure ?" ("gray80":"#773333") f.title
  92. "Shutdown" f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -bc -T 'Warning! System Shutdown' -fs 12 -geometry 80x12 -bg '#332211' -fg '#dc8700' -e sudo /usr/sbin/halt -p &"
  93. "No" f.nop
  94. "Yes" f.quit
  95. }
  96. menu "exec"
  97. {
  98. ":: Applications ::" f.title
  99. " Xterm (Ctrl-Alt-t)" ("gray80":"#20404b") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 80x24 &"
  100. " Xterm in Orange" ("gray80":"#864b2d") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 80x24 -fg '#dc8700' &"
  101. " CRT terminal" ("gray80":"#664400") f.exec "exec /usr/bin/cool-retro-term&"
  102. " CMUS (Ctrl-Alt-m)" ("gray80":"#445255") f.exec "exec xterm +sb -fa 'fixed' -fs 12 -geometry 80x24 -e cmus &"
  103. " ALSA Mixer" ("gray80":"#445255") f.exec "alsamixergui &"
  104. " Network... (Ctrl-Alt-n)" ("gray80":"#2a3639") f.exec "exec /usr/bin/xterm +sb -T 'Network Manager' -fa 'fixed' -fs 12 -geometry 80x24 -e sudo /usr/bin/nmtui &"
  105. " Bluetooth (Ctrl-Alt-b)" ("gray80":"#2a3639") f.exec "exec /usr/bin/xterm +sb -T 'Bluetoothctl' -fa 'fixed' -fs 12 -geometry 80x24 -e /usr/bin/bluetoothctl &"
  106. " Chromium (Ctrl-Alt-c)" ("gray80":"#3a4649") f.exec "exec /usr/bin/chromium --incognito &"
  107. " Chrome (Ctrl-Alt-g)" ("gray80":"#3a4649") f.exec "exec /usr/bin/google-chrome --incognito &"
  108. " ELinks (Ctrl-Alt-e)" ("gray80":"#3a4649") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 100x24 -e /usr/bin/elinks &"
  109. " Remmina (Ctrl-Alt-r)" ("gray80":"#3a4649") f.exec "exec /usr/bin/remmina &"
  110. " VIM" ("gray80":"#445255") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 100x24 -e /usr/bin/vim &"
  111. " Emacs" ("gray80":"#445255") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 100x24 -e /usr/bin/emacs -nw &"
  112. " Tilde" ("gray80":"#445255") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 100x24 -e /usr/bin/tilde &"
  113. " Sublime (Ctrl-Alt-s)" ("gray80":"#445255") f.exec "exec /home/cpi/bin/sublime &"
  114. " Obsidian (Ctrl-Alt-o)" ("gray80":"#445255") f.exec "exec /usr/bin/obsidian &"
  115. " VSCode (Ctrl-Alt-v)" ("gray80":"#445255") f.exec "exec /home/cpi/bin/code &"
  116. " Basic Calc" ("gray80":"#314852") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 80x24 -e /usr/bin/bc -l &"
  117. " Gnuplot" ("gray80":"#314852") f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 80x24 -e /usr/bin/gnuplot &"
  118. " DosBox" ("gray80":"#20404b") f.exec "exec /usr/bin/dosbox &"
  119. " Chocolate-Doom" ("gray80":"#20404b") f.exec "SDL_RENDER_DRIVER=software /usr/games/chocolate-doom &"
  120. " Blender" ("gray80":"#445255") f.exec "exec ~/bin/blender &"
  121. " GIMP" ("gray80":"#445255") f.exec "exec /usr/bin/gimp &"
  122. " Inkscape" ("gray80":"#445255") f.exec "exec /usr/bin/inkscape &"
  123. " Xfig" ("gray80":"#445255") f.exec "exec /usr/bin/xfig &"
  124. " Utilities" ("gray80":"#335533") f.menu "Utilities"
  125. }
  126. menu "Utilities"
  127. {
  128. ":: Utilities ::" f.title
  129. " Nedit" f.exec "exec /usr/bin/nedit &"
  130. " Xpdf" f.exec "exec /usr/bin/xpdf &"
  131. " Xcalc" ("gray80":"#314852") f.exec "exec /usr/bin/xcalc &"
  132. " Xaos" ("gray80":"#314852") f.exec "exec /usr/bin/xaos &"
  133. " XClock" f.exec "exec /usr/bin/xclock &"
  134. " OClock" f.exec "exec /usr/bin/oclock &"
  135. " Xeyes" f.exec "exec /usr/bin/xeyes &"
  136. " Xmag" f.exec "exec /usr/bin/xmag &"
  137. " aRandr" f.exec "exec /usr/bin/arandr &"
  138. " Gkrellm" f.exec "/usr/bin/gkrellm &"
  139. }
  140. WindowRing
  141. {
  142. "xterm"
  143. "xpdf"
  144. }
  145. "t" = m | c: all : f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 80x24 &"
  146. "m" = m | c: all : f.exec "exec xterm +sb -fa 'fixed' -fs 12 -geometry 80x24 -e cmus &"
  147. "n" = m | c: all : f.exec "exec /usr/bin/xterm +sb -T 'Network Manager' -fa 'fixed' -fs 12 -geometry 80x24 -e sudo /usr/bin/nmtui &"
  148. "b" = m | c: all : f.exec "exec /usr/bin/xterm +sb -T 'Bluetoothctl' -fa 'fixed' -fs 12 -geometry 80x24 -e /usr/bin/bluetoothctl &"
  149. "c" = m | c: all : f.exec "exec /usr/bin/chromium --incognito &"
  150. "g" = m | c: all : f.exec "exec /usr/bin/google-chrome --incognito &"
  151. "e" = m | c: all : f.exec "exec /usr/bin/xterm +sb -fa 'fixed' -fs 12 -geometry 100x24 -e /usr/bin/elinks &"
  152. "s" = m | c: all : f.exec "exec /home/cpi/bin/sublime &"
  153. "o" = m | c: all : f.exec "exec /usr/bin/obsidian &"
  154. "v" = m | c: all : f.exec "exec /home/cpi/bin/code &"
  155. "r" = m | c: all : f.exec "exec /usr/bin/remmina &"
  156. "i" = m | s: all : f.iconify
  157. "x" = m | s: all : f.delete
  158. "F12" = : all : f.fullzoom
  159. "F9" = : all : f.focus
  160. "Tab" = m : all : f.warpring "next"
  161. "f" = m | s: all: f.focus
  162. "u" = m | s: all: f.unfocus
  163. "n" = m : all : f.warpring "next"
  164. "n" = m|s : all : f.warpring "prev"
  165. "XF86MonBrightnessUp" = : all : f.exec "exec /usr/local/bin/cpi-backlight up"
  166. "XF86MonBrightnessDown" = : all : f.exec "exec /usr/local/bin/cpi-backlight down"
  167. "XF86AudioLowerVolume" = : all : f.exec "exec pactl set-sink-volume @DEFAULT_SINK@ -10%"
  168. "XF86AudioRaiseVolume" = : all : f.exec "exec pactl set-sink-volume @DEFAULT_SINK@ +10%"
  169. "Print" = : all : f.exec "exec import -window root screenshot.`date +\"%Y.%m.%d.%H%M%S\"`.png"