From: Oleg Broytman Date: Wed, 9 Feb 2022 23:18:48 +0000 (+0300) Subject: .fvwmrc: Rename terminal macros X-Git-Url: https://git.phdru.name/?a=commitdiff_plain;h=fe633c1514aca202a7da45fd37d638602bf96734;p=dotfiles.git .fvwmrc: Rename terminal macros The structure of new name is: terminal, encoding, geometry, ssh, screen. --- diff --git a/.fvwm/main.m4 b/.fvwm/main.m4 index 7de4966..3fd324d 100644 --- a/.fvwm/main.m4 +++ b/.fvwm/main.m4 @@ -84,54 +84,54 @@ define(`TERM_RU_UTF8_BOTRT', `TERM_RU_UTF8 -geometry TERM_GEOM_BOTRT') define(`SSH', `cgmem_nice 300 ssh') -define(`REMOTE_HOST_TERM', `$1 -e SSH $2') +define(`TERM_SSH', `$1 -e SSH $2') -define(`REMOTE_HOST_TERM_TITLE', `$1 -title "$3" -n "$3" -e SSH $2') +define(`TERM_TITLE_SSH', `$1 -title "$3" -n "$3" -e SSH $2') -define(`REMOTE_HOST_KOI8', -REMOTE_HOST_TERM_TITLE(TERM_KOI8, $1, $2)) +define(`TERM_KOI8_SSH', +TERM_TITLE_SSH(TERM_KOI8, $1, $2)) -define(`REMOTE_SCREEN_KOI8', `-t $1 exec /usr/bin/screen -xRR -S default-koi8') -define(`REMOTE_SCREEN_UTF8', `-t $1 exec /usr/bin/screen -xRR -S default-utf8') +define(`SSH_SCREEN_KOI8', `-t $1 exec /usr/bin/screen -xRR -S default-koi8') +define(`SSH_SCREEN_UTF8', `-t $1 exec /usr/bin/screen -xRR -S default-utf8') -define(`REMOTE_HOST_KOI8_MENU', -"$2 (koi8)" REMOTE_HOST_KOI8($1, $2)) +define(`MENU_TERM_KOI8_SSH', +"$2 (koi8)" TERM_KOI8_SSH($1, $2)) -define(`REMOTE_HOST_KOI8_BOTLT', -REMOTE_HOST_TERM_TITLE(TERM_KOI8_BOTLT, $1, $2)) +define(`TERM_KOI8_BOTLT_SSH', +TERM_TITLE_SSH(TERM_KOI8_BOTLT, $1, $2)) -define(`REMOTE_HOST_KOI8_BOTRT', -REMOTE_HOST_TERM_TITLE(TERM_KOI8_BOTRT, $1, $2)) +define(`TERM_KOI8_BOTRT_SSH', +TERM_TITLE_SSH(TERM_KOI8_BOTRT, $1, $2)) -define(`REMOTE_HOST_KOI8_BOTLT_MENU', -"$2 (koi8,btlt)" REMOTE_HOST_KOI8_BOTLT($1, $2)) +define(`MENU_TERM_KOI8_BOTLT_SSH', +"$2 (koi8,btlt)" TERM_KOI8_BOTLT_SSH($1, $2)) -define(`REMOTE_HOST_KOI8_BOTRT_MENU', -"$2 (koi8,btrt)" REMOTE_HOST_KOI8_BOTRT($1, $2)) +define(`MENU_TERM_KOI8_BOTRT_SSH', +"$2 (koi8,btrt)" TERM_KOI8_BOTRT_SSH($1, $2)) -define(`REMOTE_HOST_UTF8', -REMOTE_HOST_TERM_TITLE(TERM_RU_UTF8, $1, $2)) +define(`TERM_UTF8_SSH', +TERM_TITLE_SSH(TERM_RU_UTF8, $1, $2)) -define(`REMOTE_HOST_UTF8_MENU', -"$2 (utf8)" REMOTE_HOST_UTF8($1, $2)) +define(`MENU_TERM_UTF8_SSH', +"$2 (utf8)" TERM_UTF8_SSH($1, $2)) -define(`REMOTE_HOST_UTF8_BOTLT', -REMOTE_HOST_TERM_TITLE(TERM_RU_UTF8_BOTLT, $1, $2)) +define(`TERM_UTF8_BOTLT_SSH', +TERM_TITLE_SSH(TERM_RU_UTF8_BOTLT, $1, $2)) -define(`REMOTE_HOST_UTF8_BOTRT', -REMOTE_HOST_TERM_TITLE(TERM_RU_UTF8_BOTRT, $1, $2)) +define(`TERM_UTF8_BOTRT_SSH', +TERM_TITLE_SSH(TERM_RU_UTF8_BOTRT, $1, $2)) -define(`REMOTE_HOST_UTF8_BOTLT_MENU', -"$2 (utf8,btlt)" REMOTE_HOST_UTF8_BOTLT($1, $2)) +define(`MENU_TERM_UTF8_BOTLT_SSH', +"$2 (utf8,btlt)" TERM_UTF8_BOTLT_SSH($1, $2)) -define(`REMOTE_HOST_UTF8_BOTRT_MENU', -"$2 (utf8,btrt)" REMOTE_HOST_UTF8_BOTRT($1, $2)) +define(`MENU_TERM_UTF8_BOTRT_SSH', +"$2 (utf8,btrt)" TERM_UTF8_BOTRT_SSH($1, $2)) -define(`REMOTE_HOST_KOI8_BIG', +define(`TERM_KOI8_BIG_SSH', TERM_KOI8 -geometry TERM_GEOM_BIG -title "$2" -n "$2" -e SSH "$1") -define(`REMOTE_HOST_KOI8_BIG_MENU', -"$2 (koi8)" REMOTE_HOST_KOI8_BIG($1, $2)) +define(`MENU_TERM_KOI8_BIG_SSH', +"$2 (koi8)" TERM_KOI8_BIG_SSH($1, $2)) divert @@ -585,27 +585,27 @@ AddToFunc AudioPlayer I GotoDeskAndPage 0 1 1 DestroyFunc Term-Iskra AddToFunc Term-Iskra I GotoDeskAndPage 1 1 2 -+ I REMOTE_HOST_KOI8(REMOTE_SCREEN_KOI8(iskra-aviel.phdru.name), iskra scr) ++ I TERM_KOI8_SSH(SSH_SCREEN_KOI8(iskra-aviel.phdru.name), iskra scr) DestroyFunc Term-Iskra-Big AddToFunc Term-Iskra-Big I GotoDeskAndPage 1 1 2 -+ I REMOTE_HOST_KOI8_BIG(iskra-aviel.phdru.name, ISKRA) ++ I TERM_KOI8_BIG_SSH(iskra-aviel.phdru.name, ISKRA) DestroyFunc Term-Oper AddToFunc Term-Oper I GotoDeskAndPage 1 1 2 -+ I REMOTE_HOST_KOI8_BOTRT(REMOTE_SCREEN_KOI8(oper.med.ru), oper scr) ++ I TERM_KOI8_BOTRT_SSH(SSH_SCREEN_KOI8(oper.med.ru), oper scr) DestroyFunc Term-Oper-Big AddToFunc Term-Oper-Big I GotoDeskAndPage 1 1 2 -+ I REMOTE_HOST_KOI8_BIG(oper.med.ru, OPER) ++ I TERM_KOI8_BIG_SSH(oper.med.ru, OPER) DestroyFunc Term-Phdru AddToFunc Term-Phdru I GotoDeskAndPage 1 0 1 -+ I REMOTE_HOST_KOI8(REMOTE_SCREEN_KOI8(phdru.name), phdru.name scr) ++ I TERM_KOI8_SSH(SSH_SCREEN_KOI8(phdru.name), phdru.name scr) DestroyFunc Term-Phdru-Big AddToFunc Term-Phdru-Big I GotoDeskAndPage 1 0 1 -+ I REMOTE_HOST_KOI8_BIG(phdru.name, phdru.name) ++ I TERM_KOI8_BIG_SSH(phdru.name, phdru.name) DestroyFunc Term3Hosts AddToFunc Term3Hosts I Term-Iskra @@ -613,7 +613,7 @@ AddToFunc Term3Hosts I Term-Iskra + I Term-Oper + I Wait TERM + I GotoDeskAndPage 1 0 1 -+ I REMOTE_HOST_KOI8(REMOTE_SCREEN_KOI8(-D 1080 phdru.name), phdru.name scr) ++ I TERM_KOI8_SSH(SSH_SCREEN_KOI8(-D 1080 phdru.name), phdru.name scr) + I Wait TERM + I GotoDeskAndPage 1 1 2 @@ -723,18 +723,18 @@ AddToMenu TermColors "Term Colors" Title AddToMenu Systems "Systems" Title + "Iskra+Oper+Phdru" Term3Hosts + "" Nop -+ REMOTE_HOST_KOI8_MENU(REMOTE_SCREEN_KOI8(iskra-aviel.phdru.name), iskra scr) -+ REMOTE_HOST_UTF8_BOTLT_MENU(iskra-aviel.phdru.name, iskra) -+ REMOTE_HOST_KOI8_BIG_MENU(iskra-aviel.phdru.name, ISKRA) ++ MENU_TERM_KOI8_SSH(SSH_SCREEN_KOI8(iskra-aviel.phdru.name), iskra scr) ++ MENU_TERM_UTF8_BOTLT_SSH(iskra-aviel.phdru.name, iskra) ++ MENU_TERM_KOI8_BIG_SSH(iskra-aviel.phdru.name, ISKRA) + "" Nop -+ REMOTE_HOST_KOI8_BOTRT_MENU(REMOTE_SCREEN_KOI8(oper.med.ru), oper scr) -+ REMOTE_HOST_UTF8_BOTRT_MENU(oper.med.ru, oper) -+ REMOTE_HOST_KOI8_BIG_MENU(oper.med.ru, OPER) ++ MENU_TERM_KOI8_BOTRT_SSH(SSH_SCREEN_KOI8(oper.med.ru), oper scr) ++ MENU_TERM_UTF8_BOTRT_SSH(oper.med.ru, oper) ++ MENU_TERM_KOI8_BIG_SSH(oper.med.ru, OPER) + "" Nop -+ REMOTE_HOST_KOI8_MENU(REMOTE_SCREEN_KOI8(phdru.name), phdru scr) -+ REMOTE_HOST_KOI8_MENU(REMOTE_SCREEN_KOI8(-D 1080 phdru.name), phdru scr SOCKS5) -+ REMOTE_HOST_UTF8_BOTLT_MENU(phdru.name, phdru) -+ REMOTE_HOST_KOI8_BIG_MENU(phdru.name, PHDRU) ++ MENU_TERM_KOI8_SSH(SSH_SCREEN_KOI8(phdru.name), phdru scr) ++ MENU_TERM_KOI8_SSH(SSH_SCREEN_KOI8(-D 1080 phdru.name), phdru scr SOCKS5) ++ MENU_TERM_UTF8_BOTLT_SSH(phdru.name, phdru) ++ MENU_TERM_KOI8_BIG_SSH(phdru.name, PHDRU) AddToMenu FvwmCommands "Fvwm Commands" Title + "Restart" Restart @@ -918,9 +918,9 @@ pushdef(`TERM_KOI8', `Exec "TERM" LC_CTYPE=ru_RU.KOI8-R exec TERM') pushdef(`TERM_RU_UTF8', `Exec "URxvt" LC_CTYPE=ru_RU.UTF-8 exec TERM -name URxvt') *FvwmButtons: (Title Term, Icon rterm2.xpm, Action TERM_KOI8) *FvwmButtons: (Title UTF-8, Icon rterm2.xpm, Action TERM_RU_UTF8) -*FvwmButtons: (Title "phdru scr", Icon xterm-sgi.xpm, Action REMOTE_HOST_KOI8(REMOTE_SCREEN_KOI8(phdru.name), phdru.name scr)) -*FvwmButtons: (Title "iskra scr", Icon xterm-sgi.xpm, Action REMOTE_HOST_KOI8(REMOTE_SCREEN_KOI8(iskra-aviel.phdru.name), iskra scr)) -*FvwmButtons: (Title "oper scr", Icon xterm-linux.xpm, Action REMOTE_HOST_KOI8_BOTRT(REMOTE_SCREEN_KOI8(oper.med.ru), oper scr)) +*FvwmButtons: (Title "phdru scr", Icon xterm-sgi.xpm, Action TERM_KOI8_SSH(SSH_SCREEN_KOI8(phdru.name), phdru.name scr)) +*FvwmButtons: (Title "iskra scr", Icon xterm-sgi.xpm, Action TERM_KOI8_SSH(SSH_SCREEN_KOI8(iskra-aviel.phdru.name), iskra scr)) +*FvwmButtons: (Title "oper scr", Icon xterm-linux.xpm, Action TERM_KOI8_BOTRT_SSH(SSH_SCREEN_KOI8(oper.med.ru), oper scr)) popdef(`TERM_KOI8', `TERM_RU_UTF8') *FvwmButtons: (Title Wallpaper, Icon find1.xpm, Action Exec "gxmessage" "$HOME"/current/projects/xsetbg/print-filename.py | text-wrap.py -w TEXT_WIDTH -s | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -)