ほぼ覚え書きの不親切さ。
archbangのデフォルトデスクトップは、
openbox。それですでに使っている
環境下で、デスクトップ環境を変えた
ということで、ござる。
$ sudo pacman -S blackbox bbpager
$ sudo cp -rf /usr/share/blackbox ~/.blackbox
$ nano ~/.blackboxrc
.blackboxrcの雛形をネットから拾ってきて貼る。
----------------------------------------------------------
session.screen0.slit.placement: CenterRight
session.screen0.slit.direction: Vertical
session.screen0.slit.onTop: False
session.screen0.slit.autoHide: False
session.screen0.toolbar.onTop: False
session.screen0.toolbar.autoHide: False
session.screen0.toolbar.placement: BottomCenter
session.screen0.toolbar.widthPercent: 66
session.screen0.enableToolbar: True
session.screen0.workspaces: 4
session.screen0.workspaceNames: Workspace 1,Workspace 2,Workspace 3,Workspace 4
session.screen0.strftimeFormat: %I:%M %p
session.windowPlacement: RowSmartPlacement
session.colPlacementDirection: TopToBottom
session.shadeWindowWithMouseWheel: True
session.windowSnapThreshold: 0
session.doubleClickInterval: 250
session.opaqueResize: True
session.autoRaiseDelay: 400
session.edgeSnapThreshold: 0
session.toolbarActionsWithMouseWheel: True
session.placementIgnoresShaded: True
session.styleFile: /home/izm/.blackbox/styles/Gray
session.focusNewWindows: True
session.rowPlacementDirection: LeftToRight
session.menuFile: /home/izm/.blackbox/menu
session.focusLastWindow: True
session.focusModel: ClickToFocus
session.maximumColors: 0
session.opaqueMove: True
session.disableBindingsWithScrollLock: False
session.changeWorkspaceWithMouseWheel: True
session.fullMaximization: False
session.imageDither: OrderedDither
----------------------------------------------------------
$ nano ~/.blackbox/menu
example以下を消して、やっぱりネットから雛形を
拾ってきて貼る。(reboot,poweroff、screenshotの設定、
使うアプリの追加など、あれこれ修正済み)
----------------------------------------------------------
[begin] (b l a c k b o x )
[exec] (Eterm) {Eterm -x -0 --trans --scrollbar=off --buttonbar 0 --geometry 79x35+13+495 --font-fx none -f lightgrey}
[nop] ()
[submenu] (terminals) {terminals}
[exec] (lxterminal) {lxterminal}
[exec] (aterm) {aterm -tr -bg black -fg lightgrey -fn 7x14 -fb 7x14 +vb +sb -geometry 79x32+13+495}
[exec] (gterm) {gnome-terminal}
[exec] (kterm) {konsole}
[exec] (xterm) {xterm -ls}
[end]
[submenu] (file manager) {}
[exec] (spacefm) {spacefm}
[end]
[submenu] (editor) {}
[exec] (leafpad) {leafpad}
[end]
[submenu] (gnome) {gnome}
[exec] (nautilus) {nautilus --no-desktop}
[exec] (gnome-theme-manager) {gnome-theme-manager}
[exec] (gnome-settings-daemon) {gnome-settings-daemon}
[end]
[submenu] (audio) {}
[exec] (xmms) {xmms}
[exec] (gnome-volume) {gnome-volume-manager}
[end]
[submenu] (internet) {}
[exec] (chromium) {chromium}
[exec] (firefox) {firefox}
[exec] (gaim) {gaim}
[exec] (gftp) {gftp}
[exec] (bluefish) {bluefish}
[exec] (firestarter) {gksudo /usr/sbin/firestarter}
[exec] (virus scanner) {aegis-virus-scanner}
[end]
[submenu] (graphics) {}
[exec] (the gimp) {gimp}
[end]
[submenu] (office apps) {}
[exec] (oo.o writer) {ooffice2}
[end]
[submenu] (video) {}
[exec] (gmplayer) {gmplayer}
[exec] (vlc) {vlc}
[exec] (xine) {xine}
[end]
[submenu] (system monitor) {}
[exec] (monitor start) {conky}
[exec] (monitor stop) {killall conky}
[end]
[nop] ()
[workspaces] (workspace list)
[config] (configuration)
[nop] ()
[submenu] (startup) {}
[exec] (gnome-settings-daemon ) {gnome-settings-daemon &}
[exec] (fcitx) {fcitx}
[exec] (conky) {conky &}
[exec] (Esetroot) {Esetroot .blackbox/backgrounds/Complex_2.jpg}
[exec] (wmbutton) {wmbutton &}
[exec] (wmweather) {wmweather -w -s KROC &}
[exec] (wmcpuload ) {wmcpuload &}
[exec] (wmclock) {wmclock -12 -led white &}
[end]
[nop] ()
[submenu] (take screenshot) {}
[exec] (Now) {scrot '%Y-%m-%d--%s_$wx$h_scrot.png' -e 'mv $f ~/ & gpicview ~/$f'}
[exec] (In 10 seconds...) {scrot -d 10 '%Y-%m-%d--%s_$wx$h_scrot.png' -e 'mv $f ~/ & gpicview ~/$f'}
[exec] (Selected Area...) {scrot -s '%Y-%m-%d--%s_$wx$h_scrot.png' -e 'mv $f ~/ & gpicview ~/$f'}
[end]
[nop] ()
[reconfig] (reconfigure)
[restart] (restart) {reboot}
[exec] (poweroff) {poweroff}
[exit] (exit)
[end]
----------------------------------------------------------
で、一等最初に示したblackboxrcの記述のように、
blackboxの表現系をGray(ほかにBlue,Green,
Purple,Redが用意されている)に設定した。
そして、日本語の文字化けを防ぐためフォントを変更。
$ nano ~/.blackbox/Gray
----------------------------------------------------------
*button.pressed.appearance: sunken solid
*button.pressed.backgroundColor: darkgrey
*button.appearance: parentrelative
*button.foregroundColor: black
*backgroundColor: rgb:dd/dd/d7
*color1: rgb:dd/dd/d7
*color2: rgb:ee/ee/e7
*font: Bitstream Vera Sans-9
*borderColor: black
*borderWidth: 1
*marginWidth: 2
menu.title.appearance: flat solid border
menu.title.backgroundColor: grey
menu.title.foregroundColor: black
menu.title.textColor: black
menu.title.alignment: center
menu.title.font: Bitstream Vera Sans-9:style=Bold
menu.frame.appearance: raised gradient border
menu.frame.textColor: black
menu.frame.foregroundColor: grey40
menu.frame.disabledColor: darkgrey
menu.frame.alignment: left
menu.active.appearance: flat solid border
menu.active.backgroundColor: rgb:77/77/74
menu.active.foregroundColor: white
menu.active.textColor: white
rootCommand: bsetroot -solid rgb:aa/aa/aa
slit.appearance: raised solid
slit.backgroundColor: rgb:aa/aa/aa
slit.marginWidth: 3
toolbar.appearance: raised gradient border
toolbar.alignment: center
toolbar*textColor: black
toolbar.label.appearance: parentrelative
toolbar.clock.appearance: parentrelative
toolbar.windowLabel.appearance: parentrelative
##toolbar.font: Swis721 Cn BT D-Type
toolbar.font: VL ゴシック-9
window.title.focus.appearance: raised gradient border
window.title.focus.color1: rgb:66/66/63
window.title.focus.color2: rgb:88/88/84
window.title.unfocus.appearance: raised gradient border
window.label.focus.appearance: parentrelative
window.label.focus.textColor: white
window.label.unfocus.appearance: parentrelative
window.label.unfocus.textColor: darkgrey
window.label.marginWidth: 1
window.button.focus.appearance: parentrelative
window.button.focus.foregroundColor: white
window.button.unfocus.appearance: parentrelative
window.button.unfocus.foregroundColor: darkgrey
window.handle.focus.appearance: raised solid border
window.handle.unfocus.appearance: raised solid border
window.grip.focus.appearance: raised solid border
window.grip.focus.backgroundColor: rgb:77/77/74
window.grip.unfocus.appearance: raised solid border
window*alignment: center
##window.font: Bitstream Vera Sans-9:style=Bold
window.font: VL ゴシック-9:style=Bold
window.handleHeight: 8
rootCommand: bsetbg -f ~/.blackbox/background/blackbox.jpg
----------------------------------------------------------
すぐ上の最終行は、壁紙の表示。お好みの壁紙は、
$ mkdir ~/.blackbox/background
として、以下に保存。
$ rootCommand: bsetbg -f
という書き方で表示できる。
openboxを止めて、blacboxを起動させる。
$ nano ~/.xinitrc
----------------------------------------------------------
#!/bin/bash
##export DE=openbox
exec blackbox
# Dbus fix
if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
eval "$(dbus-launch --sh-syntax --exit-with-session)"
fi
/usr/bin/xdg-user-dirs-update
# configure obmenu user
##sed -i 's/live/'$(whoami)'/' ~/.config/obmenu-generator/schema.pl \
## ~/.config/obmenu-generator/config.pl
# start openbox
##/usr/bin/openbox-session > ~/.openbox_startup.log 2>&1
#exec i3
----------------------------------------------------------
赤字はコメントアウトしたところ。
緑字は追記。exec i3が在るのは、
このバージョンのarchbangには、
デスクトップ環境として搭載されているから。
いまのところ、numlock,volumeicon,conky,fcitxの
自動起動はできていないです。fcitxとconkyの起動は、
メニューから。conkyなんか、systemdで、
conky.serviceを作ってやろうとしたけど、撃沈。
壁紙表示が要らないなら、
rootCommand: conky で、自動起動させられます。
openbox、fluxboxとの大きな違いは、
アプリのautostartの機能がない、ということ。
※お断り、grayだったり、greyだったりは、現物がそうなので。
2014年11月18日
この記事へのコメント
コメントを書く