在其中一个工作区上隐藏gnome-panel

我目前在Ubuntu 10.10上使用2个工作区,并且compiz。

是否可以从其中一个工作区完全移除gnome面板? 我想在第二个工作区上使用干净的桌面,在第一个工作区上使用带有面板的常规桌面。 那可能吗?

(更新)…我刚修复了一个“bug”,其中脚本(下面) 只会查找“panel_6”
…此外,该脚本仅用于单监视器系统……
…但是,进一步研究它,可能有双/多显示器。
…这是第二台显示器上面板的链接……
… 移动面板(屏幕之间)
…我不确定这是不是你想要的,但似乎更适合多台显示器。

假设没有“内置”的方式来实现它,就像在这种情况下一样,我拼凑了一个脚本来“排序”做它……它只是将您选择的面板设置为自动-hide …你可以通过args选择哪个工作区。

您可以将脚本绑定到Compiz当前用于切换工作空间的相同键…

如果您使用任何其他方法进入下一个工作区,它将无法工作,但您也可以使用该脚本来打开/关闭面板…(ooops!我今天没有时间完成那一点…… 🙁

我还没有对其进行微调,但它有效(直到某一点)。 它可能适合您,也可能不适合您。
(你需要wmctrl 安装wmctrl

这是目前的脚本:


#!/bin/bash # Arg1: A capital letter; L or R .. to indicate the Left or Right direction for next work-space # # Arg[*]: Each arg, after the first, is the number (1-based) of a work-space for which you wish to hide the panel(s) # If no args are supplied, the current state will be toggled; show/hide ... hide/show # # Choose your panel identifiers by opening gconf-editor with this command: # # gconf-editor /apps/panel/toplevels/ # # You can test each of the listed panels by clicking in the "Value" checkbox # of the "auto-hide" item... # # Then add the Panel-IDs which you want to be hidden, # as shown here panels="panel_6 panel_6" # I only use one panel, so I've just repeated it to make an "example" list ###### dir=$1; valids="LR" if [ "${valids/${dir}/}" != "$valids" ] then shift 1 else exit 1 fi eval $(wmctrl -d |sed -n "s/.*DG: \([0-9]\+\)x[0-9]\+ \+VP: \([0-9]\+\),.* \([0-9]\+\)x[0-9]\+ .*/wmax=\$(((\1\/\3))); wcur=\$(((\2\/\3)+1)); wide=\3; hide=false/p") if [ "$wcur" -eq "$wmax" ] ; then if [ "$dir" == "R" ] ; then wnew=1 else wnew=$((wcur-1)) fi elif [ "$wcur" -eq "1" ] ; then if [ "$dir" == "L" ] ; then wnew=$wmax else wnew=$((wcur+1)) fi else if [ "$dir" == "R" ] ; then wnew=$((wcur+1)) else wnew=$((wcur-1)) fi fi wmctrl -o $(((wnew-1)*wide)),0 for w in $@ ; do if [ "$w" -eq "$wnew" ] ; then hide=true break fi done for panel in $panels ; do gconftool-2 --set /apps/panel/toplevels/$panel/auto_hide --type bool $hide done exit ############################################################################### 

我认为这是不可能的。 所有gnome-panel设置对于“所有工作空间”都是通用的。

编辑:我试图谷歌一些信息,在我看来,没有“替代面板”,不同的工作区有不同的设置。 (我尝试过xfce4-panel,fbpanel和pypanel。)