在你的 Linux 桌面嵌入终端窗口

除了我们曾经介绍过的 Tilda 和 Yakuake 终端具有嵌入桌面的效果之外,使用 Devil's Pie 这个小程序你同样可以将终端窗口嵌入到你的 Linux 桌面。

Devil's Pie

下面就以 GNOME Terminal 为例来说明嵌入到桌面的过程:

  1. 安装 Devil's Pie: 在 Debian/Ubuntu 中可以通过执行下列指令安装 Devil's Pie: sudo apt-get install devilspie 如果你使用其他 Linux 发行版,那么可以获取 Devil's Pie 的源代码编译安装: ./configure && make && make install
  2. 创建 Devil's Pie 的配置文件: 在终端中执行: mkdir ~/.devilspie nano ~/.devilspie/DesktopConsole.ds 然后添加下列内容:
    
    (if
            (matches (window_name) "DesktopConsole")
            (begin
                    (set_workspace 4)
                    (below)
                    (undecorate)
                    (skip_pager)
                    (skip_tasklist)
                    (wintype "utility")
                    (geometry "+50+50")
                    (geometry "924x668")
            )
    )
    
    此时,你可以根据自己的需要作出适当调整,如使用哪一个工作区、终端窗口的位置及大小等。
  3. 创建名为“DesktopConsole”的 GNOME Terminal 配置文件: 取消选择“常规”标签中的默认显示菜单栏,在“滚动”标签中将滚动栏禁用,切换到“效果”标签可以设置为透明背景。
  4. 将 Devil's Pie 和 GNOME Terminal 添加到会话中: 这样可以让 Devil's Pie 和 GNOME Terminal 随机自动运行。你需要在“启动程序”中添加: devilspie gnome-terminal --window-with-profile=DesktopConsole

注销并重新登录系统即可让上述设置生效。

其实,Devil's Pie 是一个蛮有意思的程序,它还有很多其它玩法,你不妨参阅它的详细说明

[via]

Read More:

10 Comments

  1. 1 gordon Commented @ 2007-08-24 16:45Reply to this comment

    有点花哨,不过用来换换心情还是蛮不错的。 支持一下。

  2. 2 nacre Commented @ 2007-08-24 18:04Reply to this comment

    Devil's Pie最有用的是把不同类型的程序自动放在不同的桌面上,例如firefox和thunderbird放在desk1,vim放在desk2,mplayer放在desk3……

  3. 3 zhan Commented @ 2007-08-24 20:10Reply to this comment

    哇,竟然是 lisp 的配置文件..

  4. 4 zhuqin_83 Commented @ 2007-08-25 10:09Reply to this comment

    用compiz也可以做到这种效果。

  5. 5 食古不化 Commented @ 2007-08-25 14:33Reply to this comment

    fvwm可以非常方便的做到任意位置/任意desk(page)启动程序。

  6. 6 wjs272 Commented @ 2007-08-26 11:46Reply to this comment

    并不是真正意义上的嵌入桌面,我用win+D快捷键切换到桌面,她就消失了 :(

  7. 7 anton Commented @ 2007-08-26 23:34Reply to this comment

    (跟食古不化握手。) 而且畢竟是假透明,不是真透明。所以難免會發現一些很奇怪的現象。 (把 layer 切到 desktop + 無框無標題就是一樣的效果了) 所以很多 wm 都可以做到同樣的效果。

  8. 8 links for 2007-08-31 « membo Pingbacked @ 2007-08-31 16:22Reply to this comment

    [...] 在你的 Linux 桌面嵌入终端窗口 - LinuxTOY (tags: ubuntu) [...]

  9. 9 ee Commented @ 2007-09-12 14:20Reply to this comment

    fvwm才是桌面管理的终极武器。bs 老说cf的。 :D

  10. 10 zhuqin Commented @ 2007-09-17 20:42Reply to this comment

    bs ee