特殊:Badtitle/NS100:CompizStandalone
文章出处: |
{{#if: | {{{2}}} | https://help.ubuntu.com/community/CompizStandalone }} |
点击翻译: |
English {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/af | • {{#if: UbuntuHelp:CompizStandalone|Afrikaans| [[::CompizStandalone/af|Afrikaans]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ar | • {{#if: UbuntuHelp:CompizStandalone|العربية| [[::CompizStandalone/ar|العربية]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/az | • {{#if: UbuntuHelp:CompizStandalone|azərbaycanca| [[::CompizStandalone/az|azərbaycanca]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/bcc | • {{#if: UbuntuHelp:CompizStandalone|جهلسری بلوچی| [[::CompizStandalone/bcc|جهلسری بلوچی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/bg | • {{#if: UbuntuHelp:CompizStandalone|български| [[::CompizStandalone/bg|български]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/br | • {{#if: UbuntuHelp:CompizStandalone|brezhoneg| [[::CompizStandalone/br|brezhoneg]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ca | • {{#if: UbuntuHelp:CompizStandalone|català| [[::CompizStandalone/ca|català]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/cs | • {{#if: UbuntuHelp:CompizStandalone|čeština| [[::CompizStandalone/cs|čeština]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/de | • {{#if: UbuntuHelp:CompizStandalone|Deutsch| [[::CompizStandalone/de|Deutsch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/el | • {{#if: UbuntuHelp:CompizStandalone|Ελληνικά| [[::CompizStandalone/el|Ελληνικά]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/es | • {{#if: UbuntuHelp:CompizStandalone|español| [[::CompizStandalone/es|español]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/fa | • {{#if: UbuntuHelp:CompizStandalone|فارسی| [[::CompizStandalone/fa|فارسی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/fi | • {{#if: UbuntuHelp:CompizStandalone|suomi| [[::CompizStandalone/fi|suomi]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/fr | • {{#if: UbuntuHelp:CompizStandalone|français| [[::CompizStandalone/fr|français]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/gu | • {{#if: UbuntuHelp:CompizStandalone|ગુજરાતી| [[::CompizStandalone/gu|ગુજરાતી]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/he | • {{#if: UbuntuHelp:CompizStandalone|עברית| [[::CompizStandalone/he|עברית]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/hu | • {{#if: UbuntuHelp:CompizStandalone|magyar| [[::CompizStandalone/hu|magyar]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/id | • {{#if: UbuntuHelp:CompizStandalone|Bahasa Indonesia| [[::CompizStandalone/id|Bahasa Indonesia]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/it | • {{#if: UbuntuHelp:CompizStandalone|italiano| [[::CompizStandalone/it|italiano]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ja | • {{#if: UbuntuHelp:CompizStandalone|日本語| [[::CompizStandalone/ja|日本語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ko | • {{#if: UbuntuHelp:CompizStandalone|한국어| [[::CompizStandalone/ko|한국어]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ksh | • {{#if: UbuntuHelp:CompizStandalone|Ripoarisch| [[::CompizStandalone/ksh|Ripoarisch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/mr | • {{#if: UbuntuHelp:CompizStandalone|मराठी| [[::CompizStandalone/mr|मराठी]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ms | • {{#if: UbuntuHelp:CompizStandalone|Bahasa Melayu| [[::CompizStandalone/ms|Bahasa Melayu]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/nl | • {{#if: UbuntuHelp:CompizStandalone|Nederlands| [[::CompizStandalone/nl|Nederlands]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/no | • {{#if: UbuntuHelp:CompizStandalone|norsk| [[::CompizStandalone/no|norsk]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/oc | • {{#if: UbuntuHelp:CompizStandalone|occitan| [[::CompizStandalone/oc|occitan]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/pl | • {{#if: UbuntuHelp:CompizStandalone|polski| [[::CompizStandalone/pl|polski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/pt | • {{#if: UbuntuHelp:CompizStandalone|português| [[::CompizStandalone/pt|português]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ro | • {{#if: UbuntuHelp:CompizStandalone|română| [[::CompizStandalone/ro|română]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/ru | • {{#if: UbuntuHelp:CompizStandalone|русский| [[::CompizStandalone/ru|русский]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/si | • {{#if: UbuntuHelp:CompizStandalone|සිංහල| [[::CompizStandalone/si|සිංහල]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/sq | • {{#if: UbuntuHelp:CompizStandalone|shqip| [[::CompizStandalone/sq|shqip]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/sr | • {{#if: UbuntuHelp:CompizStandalone|српски / srpski| [[::CompizStandalone/sr|српски / srpski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/sv | • {{#if: UbuntuHelp:CompizStandalone|svenska| [[::CompizStandalone/sv|svenska]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/th | • {{#if: UbuntuHelp:CompizStandalone|ไทย| [[::CompizStandalone/th|ไทย]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/tr | • {{#if: UbuntuHelp:CompizStandalone|Türkçe| [[::CompizStandalone/tr|Türkçe]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/vi | • {{#if: UbuntuHelp:CompizStandalone|Tiếng Việt| [[::CompizStandalone/vi|Tiếng Việt]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/yue | • {{#if: UbuntuHelp:CompizStandalone|粵語| [[::CompizStandalone/yue|粵語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/zh | • {{#if: UbuntuHelp:CompizStandalone|中文| [[::CompizStandalone/zh|中文]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/zh-hans | • {{#if: UbuntuHelp:CompizStandalone|中文(简体)| [[::CompizStandalone/zh-hans|中文(简体)]]}}|}} {{#ifexist: {{#if: UbuntuHelp:CompizStandalone | UbuntuHelp:CompizStandalone | {{#if: | :}}CompizStandalone}}/zh-hant | • {{#if: UbuntuHelp:CompizStandalone|中文(繁體)| [[::CompizStandalone/zh-hant|中文(繁體)]]}}|}} |
{{#ifeq:UbuntuHelp:CompizStandalone|:CompizStandalone|请不要直接编辑翻译本页,本页将定期与来源同步。}} |
{{#ifexist: :CompizStandalone/zh | | {{#ifexist: CompizStandalone/zh | | {{#ifeq: {{#titleparts:CompizStandalone|1|-1|}} | zh | | }} }} }} {{#ifeq: {{#titleparts:CompizStandalone|1|-1|}} | zh | | }}
Introduction
Many people use Compiz-Fusion in Gnome or KDE, but it is also possible to use it as a standalone window manager like Openbox. It is a very light environment, compared to Gnome or KDE (but still heavier than Openbox). This wiki entry explains how to set up a Compiz standalone session and how to fix some related issues. I assume you already got a standard Ubuntu (Gnome) system available, but it is also possible to setup it from a minimal system.
Installation
Requirements for minimal system
If you have a standard Ubuntu/Gnome system, you don't need to install anything to run Compiz Standalone, so skip to the next section. In a minimal system, you need to install the following packages:
sudo aptitude install xorg xterm compiz gdm jockey-gtk
You'll also need a panel, application launcher, network manager etc, because Compiz alone is only a Window Manager and won't let you do much. There are many options available, and you can see some at the screenshots and issues sections. I'm using GDM as a login manager, but you can replace it with KDM or XDM. To launch GDM, run:
sudo /etc/init.d/gdm start
Login into a xterm session and run jockey-gtk to install your graphical card driver, which is required by Compiz. After restart, open a xterm session again and run the following command to test it:
compiz --replace ccp
If you see window borders around xterm, then it worked. Now we have to create an option to launch a Compiz session from your login manager.
Add a login manager session
First, we'll create a xsession entry in /usr/share/xsessions/compiz-session.desktop. It will add an option to GDM. It is a .desktop file like those that populate your Gnome menu:
[Desktop Entry] Encoding=UTF-8 Name=Compiz Comment=Compiz-Fusion standalone Exec=/usr/local/bin/compiz-session Type=Application
As you can see in the Exec entry, this session will execute the launcher /usr/local/bin/compiz-session. Create this file and make it executable:
#! ignore this line. the wiki is hiding the shebang #!/bin/bash if test -z "$DBUS_SESSION_BUS_ADDRESS"; then eval `dbus-launch --sh-syntax --exit-with-session` fi compiz --replace ccp & wmpid=$! sleep 1 if [ -f ~/.compiz-session ]; then source ~/.compiz-session & else xterm & fi # Wait for WM wait $wmpid
This launcher starts a DBUS session (required by some applications) and the Compiz WM. After starting it, it will run the ~/.compiz-session file. Create this file, launching your panels, monitors, wallpaper, file manager, etc. All the lines on this file should end with the & character. If the file does not exist, the launcher will start xterm, so you can launch other programs. See the screenshots section for some ideas.
Screenshots
This section don't make much sense, because the looks and functionality when you are using Compiz Standalone depends on what you are using. With Compiz itself you'll only see your wallpaper (if the plugin is enabled). This section will show screenshots of different setups, and how to achieve them. Feel free to contribute with your own shots.
Gnome-panel and Nautilus
模板:Http://dl.getdropbox.com/u/550278/scrot/compiz/.thumb.gpanel-nautilus.png With this setup, you'll have the same look as Gnome.
gnome-panel & nautilus -n &
Tint2 and Gmrun
模板:Http://dl.getdropbox.com/u/550278/scrot/compiz/.thumb.tint2-gmrun.png 模板:Http://code.google.com/p/tint2/ is a very customizable and lightweight panel you can use in Compiz. It is not available at Ubuntu repositories, but you can use their PPA. Gmrun is just a plain "run dialog", available at the repositories. You can create a shortcut to start gmrun using CCSM.
tint2 & gmrun &
Gnome-Do
模板:Http://dl.getdropbox.com/u/550278/scrot/compiz/.thumb.gnome-do.png You can also have a panel-less environment, using an application launcher like Gnome-Do. The lack of a notification area and a clock can be fixed with Stalonetray and Conky. You may need to remove both Conky and Stalonetray shadows using CCSM.
gnome-do & conky & stalonetray -t &
Issues and workarounds
Ugly applications
When you are using Compiz Standalone, your Gtk+ applications won't use the same theme used in Gnome, but the theme in your ~/.gtkrc-2.0 file. You can use LXAppearance to change your theme, or tweak the file yourself:
gtk-theme-name="Human" gtk-icon-theme-name="Human" gtk-font-name="Liberation 8" gtk-cursor-theme-name="DMZ-Black" gtk-cursor-theme-size=16
If you prefer, you can still use the Gnome settings if you add to your session launcher the following line:
gnome-settings-daemon &
No wireless/network
You can start NetworkManager if you add this line to your session launcher:
nm-applet --sm-disable &
No wallpaper
The Compiz Wallpaper plugin is disabled by default. Enable it using ccsm. You can instead use nitrogen, feh, or a file manager that can display a wallpaper. I prefer to use the Compiz plugin, because it can handle different pictures in each workspace.
Other issues
If you have questions or suggestions, please post at this Ubuntu Forums thread: http://ubuntuforums.org/showthread.php?t=1274678
References
http://crunchbanglinux.org/forums/topic/2827/howto-run-compiz-as-a-standalone-window-manager/