How To Set Up Compiz In Xubuntu 12.10 Or 12.04

xubuntu compizThis article shows how to set up Compiz in Xubuntu (w/ Xfce) 12.10 or 12.04. I’ve tested the instructions below on Xubuntu 12.10, but they should work on Xubuntu 12.04 as well – there are some minor differences which I’ve explained below.
Before proceeding, please note that to be able to use Compiz, you’ll obviously need a 3D capable graphics card and drivers.
Let’s get started!

How to use Compiz in Xubuntu (w/ Xfce) 12.10 or 12.04
1. Install Compiz, the main Compiz plugins and CompizConfig Settings Manager:sudo apt-get install compiz compiz-plugins compizconfig-settings-manager
2. You’ll also need a tool to change the window titlebar theme (since Metacity will be used). To keep things light and without the need to add any PPAs, we’ll use dconf-editor / gconf-editor in the steps below.
For Ubuntu 12.10, install dconf-tools:
sudo apt-get install dconf-tools
xubuntu compiz
Then press ALT + F2 and run: “dconf-editor”, navigate to org > gnome > desktop > vm > preferences and change the “theme” value from “Adwaita” to “Greybird”. Remember this because in the same place you can also change the window button layout, among others.
For Ubuntu 12.04, install gconf-editor:
sudo apt-get install gconf-editor
xubuntu compiz
Then press ALT + F2 and run: “gconf-editor”, navigate to apps > metacity > general and set the “theme” value to “Greybird” (assuming that Graybird theme is installed – and it should since it’s the default theme).
Whenever you want to change the Xubuntu window theme, you’ll have to use dconf-editor / gconf-editor like explained above.

3. Some Compiz plugins MUST be enabled before running Compiz:
Open CompizConfig Settings Manager via Xubuntu’s Settings Manager and activate the following plugins (without these plugins enabled, Compiz won’t work properly): Composite, Gnome Compatibility, OpenGL, Window Decoration, Move Window, Resize Window, Place Windows.
xubuntu compiz
I also suggest enabling these plugins: Expo, Desktop Wall (or Cube), Application Switcher (or Static Application Switcher / Ring Swithcher), Grid and of course, enable any other plugins you like (don’t enable the Unity plugin though!).

You can enable/disable more plugins later on, but the important part is to enable the plugins required for Compiz to work properly, which I’ve mentioned above, before running Compiz for the first time.

4. Let’s start Compiz using the following command:
compiz –replace

5. Add Compiz to Xubuntu startup applications:

At this point, Compiz is up and running but it won’t be used after a system restart. So if you’re satisfied with it, add it start when you login to your Xubuntu session.

To do this, run the following commands:
cp /etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-session.xml ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-session.xml
leafpad ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-session.xml
In the newly opened file in Leafpad, look for the following bolded line (should be on line 14 in Xubuntu 12.10): and replace “xfwm4” with “compiz”. Then log out, log back in and that’s it.

If later on you want to go back to using xfwm4 instead of compiz, open the same file again:
leafpad ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-session.xmlAnd replace “compiz” with “xfwm4”, just like above.

Another way to do this is to (this is not the 100% proper way to do it, but I’ve added it in case the above method doesn’t work for you): open Settings Manager > Session and Startup and on the Application Autostart tab, click “Add”, under “Name” enter “Compiz” and under “Command”, enter “compiz –replace” (both without quotes). You can leave the description field empty.
xubuntu compiz
If later on you don’t want to use Compiz any more, simply remove Compiz from Settings Manager > Session and Startup > Applications Autostart tab, then log out and log back in.

Originally published at WebUpd8: Daily Ubuntu / Linux news and application reviews.



Category: Ubuntu | Comments Off on How To Set Up Compiz In Xubuntu 12.10 Or 12.04

Ubuntu Multi-Monitor Tweaks (Full Screen Flash Fixes, Span Wallpaper Across Monitors, More)

If you are using a multi-monitor setup in Ubuntu, here are a few tips which should help you fix some annoyances, like:
get full screen flash videos to be displayed on any monitorget flash videos to remain full screen while working in the other desktopa tweak to move windows to a different display using keyboard shortcutshow to extend the wallpaper across monitors or use a different wallpaper for each monitor

Move window to a specific display using a keyboard shortcut
Ubuntu (with Compiz/Unity) lets you move a window to a specific virtual desktop using keyboard shortcuts, but by default, this doesn’t work if you want to move a window to a specific monitor.
There is, however, an easy way of easily moving windows to a specific display using keyboard shortcuts so here’s what you must do.
Firstly, install CCSM if it’s not already installed:sudo apt-get install compizconfig-settings-manager
Then open CompizConfig Settings Manager, search for the “Put” plugin (it’s under Window Management) and enable it. Then, click the plugin so we can change some of its settings.
ccsm put plugin
On the “Bindings” tab, click on “Disabled” next to the “Put to Next Output” keyboard shortcut, check the “Enabled” box and then assign it a key combination that’s not already in use. I’ve used Ctrl + Tab (click on “Grab key combination” to set a keyboard shortcut). Then click ok and you’re done.
Now, focus a window and press the keyboard combination you’ve used above: the window should move to the other workspace. If you only have to monitors, this should be enough, as it moves any window from one monitor to the other. If you have more than 2 monitors, you can assign keyboard shortcuts for “Viewport Left” and “Viewport Right” and so on, under “Put to adjacent viewport”.

Get full screen flash videos to work on any monitor
In some cases (or maybe always?), full screen Flash videos show up on the primary monitor, even if you’ve clicked the full screen button while using some other monitor. The above solution works with these full screen Adobe Flash videos too: click a video, then press the key combination you’ve set up and the video should move to the other display.
So there you have it, now you can move the full screen flash videos on any monitor you want.

Get Flash videos to remain full screen when working (clicking) in the other desktop
The above solution fixes full screen Flash video showing up on the wrong display, but there’s another annoying issue with Flash: if you’re watching a full screen video on one monitor and want to work on another monitor, the flash video exists full screen. Basically, unless the full-screen flash video is focused, it exists full-screen.
There are some fixes and workarounds for this full screen Flash exiting when it’s unfocused too:
1. The first one is using an extension which resizes Flash videos to fill the whole browser window and you can then set the browser to full screen by pressing F11 or selecting View > Full screen:for Google Chrome / Chromium: MaximizeFlashfor Firefox: Flash Game Maximizer (the button to resize video to fit the whole browser window is on the addon bar so to show it, select View > Toolbars > Addon Bar). This extension doesn’t work properly with YouTube though but you can set YouTube to use HTML5 by going to http://youtube.com/html5firefox flash full windowAfter getting the video to fill the whole browser window, hit F11 or select View > Full screen

2. Below is another solution for this issue, that fixes Adobe Flash for any browser, except Google Chrome.
The reason flash videos exit full screen when clicking anywhere on the other monitor is because that’s the behaviour wanted by Adobe. Adobe Flash is not open source, but we can still modify its code using a tools such as GHex.
To install GHex in Ubuntu, use the following command:sudo apt-get install ghex
Now, find out where your Flash plugin is installed using the following commands:sudo updatedb
locate libflashplayer.so
The “locate” command above should return the full path to libflashplayer.so. Copy it because you’ll need it for the next command:gksu ghex /path/to/libflashplayer.so
Where “/path/to/” is the path to libflashplayer.so you’ve copied above (usually it should be /usr/lib/flashplugin-installer/libflashplayer.so or /usr/lib/adobe-flashplugin/libflashplayer.so)

Now, editing a binary with GHex is tricky, so read everything carefully.

Category: Ubuntu | Comments Off on Ubuntu Multi-Monitor Tweaks (Full Screen Flash Fixes, Span Wallpaper Across Monitors, More)

How To Reset Compiz And Unity In Ubuntu 12.10 Quantal Quetzal [Quick Tip]

unity

In Ubuntu 12.10, Compiz (and Unity) are using Gsettings instead of Gconf and because of this, the “unity –reset” command used to reset Unity in previous Ubuntu versions doesn’t work anymore. In case some settings are messed up and you want to reset Unity and Compiz to their default settings, here’s a new way of doing this that works with Ubuntu 12.10 Quantal Quetzal.

Firstly, install dconf-tools:

sudo apt-get install dconf-tools

Since Compiz in Ubuntu 12.10 is using Gsettings (dconf), you can reset Compiz and Unity using the following command:

dconf reset -f /org/compiz/

The old “unity –reset” command used to restart Unity too, while the command above doesn’t. So to restart Unity after running the above command, use:
setsid unity

You can also run the following command to see the Compiz settings you have:

dconf dump /org/compiz/

And a final note: the old “unity –reset-icons” command which resets the Unity Launcher icons to default still works with Ubuntu 12.10.
Info via Jeremy Bicha

Category: Ubuntu | Comments Off on How To Reset Compiz And Unity In Ubuntu 12.10 Quantal Quetzal [Quick Tip]