Menu

Compton Compositor

Anonymous

Installing compton
Compton is an X compositor which supports xrender and glx (opengl) backends.
sudo apt install compton

Configuring compton
Compton can be configured by editing the config file and place ~/.config/compton/compton.conf

backend = "glx";
glx-no-stencil = true;
vsync = true;
unredir-if-possible = true;
# Shadow
shadow = true; # Enabled client-side shadows on windows.
shadow-radius = 7; # The blur radius for shadows. (default 12)
shadow-offset-x = -7; # The left offset for shadows. (default -15)
shadow-offset-y = -7; # The top offset for shadows. (default -15)
shadow-exclude = [
 "n:e:Notification",
 "n:e:Docky",
 "g:e:Synapse",
 "g:e:Conky",
 "n:w:*Firefox*",
 "n:w:*Chromium*",
 "n:w:*dockbarx*",
 "class_g ?= 'Cairo-dock'",
 "class_g ?= 'Xfce4-notifyd'",
 "class_g ?= 'Xfce4-power-manager'",
 "class_g ?= 'Notify-osd'",
 "_GTK_FRAME_EXTENTS@:c"
];
# Opacity
detect-client-opacity = true;
# Window type settings
wintypes:
{
 dock = { shadow = false; };
 dnd = { shadow = false; };
 tooltip = { shadow = false; };
};

Disabling xfwm4 compositor and enabling compton
The following command can be used to turn off xfwm4's compositing feature
xfconf-query -c xfwm4 -p /general/use_compositing -s false

Autostart
The following content can be pasted into the compton.desktop file at ~/.config/autostart/compton.desktop

[Desktop Entry]
Encoding=UTF-8
Version=0.9.4
Type=Application
Name=Compton
Comment=X11 compositor
Exec=compton -b
OnlyShowIn=XFCE;
StartupNotify=false
Terminal=false
Hidden=false

Check if activated
Logout and login again to see if compton has been activated.
To check if compton is working following command can be used:
pgrep -l compton

Novice terminal Guide

In your home directory press both these keys together Ctrl & H this opens the hidden directories and files marked as .directory and .file .

Then click on the .config directory and open this directory, then right click on this page, when the right-click menu appears, select Open a terminal here, then type mkdir compton into the terminal. Once new directory appears, open this directory and inside use the right-click function to call up the menu and select Open a terminal here and type touch compton.conf you now have your blank compton configuration file, copy the configs from above into this file. Then save and close this file.

Now right-click the compton config file and from the menu chose Properties then go to the Permissions tab and check the box where it says Allow this file to run as a program . You have now activated this file to act as a program.

Then apply the same method (as you did in the .config directory) but this time in the .autostart directory to create a file called compton.desktop then copy the autostart code from above into this blank file then save it. Don't forget to activate it by ticking the Allow this file to run as a program . Now log out and login back in. The compton compositor will start shortly after every new login.

To check and confirm compton is functioning run this command in a terminal pgrep -l compton.