IceWM - 共通事項 - メニュー - jgmenu PCLinuxOS

 クラウディア
1. 概要
2. インストール
3. toolbar
4. preferences
5. jgmenurc

1. 概要

 「PCLinuxOS 2021.02」でも、「jgmenu」を使うことにしました。  だって、デフォルトのメニューが見にくいんだもの・・・。

2. インストール

 「root」ユーザ権限で。

apt install -y jgmenu
 ログインユーザで、コンフィグレーションファイルを作成しておきます。

jgmenu_run init

3. toolbar

 左端に、「jgmenu」を表示します。  ログインユーザ用のファイルがないので、コピーして編集します。  ログインユーザで。

cp /usr/share/icewm/toolbar ~/.icewm/toolbar
vi ~/.icewm/toolbar

# This is an example for icewm 2.1.2 toolbar definition file.
# It will be installed as /usr/share/icewm/toolbar.
# Place your variants in /etc/icewm or in $HOME/.icewm since
# modifications to this file will be overwritten when you reinstall icewm.
#
prog "File Manager" file_tools_section.png emelfm
prog "Text Editor" editors_section.png xeditor
prog Terminal terminals_section.png xterm
prog "Web Browser" web_browser_section.png xdg-open http://www.pclinuxos.com/forum
prog PCC drakconf.png pcc
prog Synaptic synaptic.png synaptic
 5、6行の間に 1行追加します。

#
prog "jgmenu" /usr/share/icewm/taskbar/icewm.xpm jgmenu_run
prog "File Manager" file_tools_section.png emelfm

4. preferences

 バーを上に表示、現在左端に表示されている、デフォルトのメニューと「デスクトップ一覧表示」「ウィンドウ一覧表示」を非表示にします。  これもログインユーザ用のファイルがないので、コピーして編集します。  ただし、デフォルトの表示内容は、ワークスペース名以外の設定がコメントアウトされているだけなので、末尾に設定を追加することにします。  ログインユーザで。

cp /usr/share/icewm/preferences ~/.icewm/preferences

sh
cat << 'EOF' >> ~/.icewm/preferences

TaskBarAtTop=1
TaskBarShowShowDesktopButton=0
TaskBarShowStartMenu=0
TaskBarShowWindowListMenu=0
ConfirmLogout=0

TitleFontName="Migu 1M:size=10"
TitleFontNameXft="Migu 1M:size=10"
MenuFontName="Migu 1M:size=10:bold"
MenuFontNameXft="Migu 1M:size=10:bold"
StatusFontName="Migu 1M:size=10:bold"
StatusFontNameXft="Migu 1M:size=10:bold"
QuickSwitchFontName="Migu 1M:size=10:bold"
QuickSwitchFontNameXft="Migu 1M:size=10:bold"
NormalButtonFontName="Migu 1M:size=10"
NormalButtonFontNameXft="Migu 1M:size=10"
ActiveButtonFontName="Migu 1M:size=10:bold"
ActiveButtonFontNameXft="Migu 1M:size=10:bold"
NormalTaskBarFontName="Migu 1M:size=10"
NormalTaskBarFontNameXft="Migu 1M:size=10"
ActiveTaskBarFontName="Migu 1M:size=10:bold"
ActiveTaskBarFontNameXft="Migu 1M:size=10:bold"
ToolButtonFontName="Migu 1M:size=10"
ToolButtonFontNameXft="Migu 1M:size=10"
NormalWorkspaceFontName="Migu 1M:size=10"
NormalWorkspaceFontNameXft="Migu 1M:size=10"
ActiveWorkspaceFontName="Migu 1M:size=10"
ActiveWorkspaceFontNameXft="Migu 1M:size=10"
MinimizedWindowFontName="Migu 1M:size=10"
MinimizedWindowFontNameXft="Migu 1M:size=10"
ListBoxFontName="Migu 1M:size=10"
ListBoxFontNameXft="Migu 1M:size=10"
ToolTipFontName="Migu 1M:size=10"
ToolTipFontNameXft="Migu 1M:size=10"
ClockFontName="Migu 1M:size=10"
ClockFontNameXft="monospace:size=10"
ApmFontName="Migu 1M:size=10"
ApmFontNameXft="monospace:size=10"
InputFontName="Migu 1M:size=10"
InputFontNameXft="monospace:size=10"
LabelFontName="Migu 1M:size=10"
LabelFontNameXft="Migu 1M:size=10"
EOF
exit

5. jgmenurc

 ログインユーザで。

vi ~/.config/jgmenu/jgmenurc

# item_height = 25
 行間を狭くします。

 item_height = 23

# font =
 わたしの好みのフォントへ。

 font = Migu 1M 12.5px

# csv_name_format = %n (%g)
 項目名が冗長なので、括弧内のコメントは日非表示へ。

 csv_name_format = %n
 終了メニューを追加します。

sh
cat << 'EOF' >> ~/.config/jgmenu/append.csv
^sep()
ログアウト,pkill icewm,system-log-out
再起動,sudo /sbin/reboot,system-reboot
シャットダウン,sudo /sbin/poweroff,system-shutdown
EOF
exit
 「再起動」「シャットダウン」には、「sudo」権限が必要になります。  「sudo」の設定に関しては、「メンテナンス・トラブルシュート - コマンド・ユーティリティ - sudo」をご参照ください。
earthcar(アースカー)
世界最大級のオンライン英会話EF English Live