Enlightenment DR 17 User Guide
This is the Get-E.org E17 user guide. Please note that this guide only covers the E17 windowmanager and its dependencies. For information on other EFL based programs, consult the EFL user guide instead.
3.8 - Background
E17 uses binary EDJ format files for backgrounds. These files may
also contain animations and various effects. Please check our
EDJ backgrounds sections (animated and static) if you want to download
some animated or normal static EDJ background files.
By default E17 uses four virtual desktops. There are two ways to change backgrounds:
- By using the graphical background selector from the E17 control panel
- By using the commandline tool "enlightenment_remote"
Setting a background via the E17 control panel:
The E17 background selector can be found from the control panel
(under "Configuration" in the main E17 menu). It displays all
background EDJ files that are placed in the directory
"~/.e/e/backgrounds" - in other words you will need to convert your
background images to EDJ files first (see "Compiling Backgrounds").
Also note that it is currently impossible to set invidual backgrounds
for each desktop via this tool: in order to achieve that, you will need
to use the commandline tool "enlightenment_remote" instead.
![[Configuration] Background Selector [Configuration] Background Selector](http://get-e.org/E17_User_Guide/English/_images/background_selector.png)
Setting an individual background for each desktop:
Each desktop can have an
individual background. Individual desktop backgrounds are currently
only selectable via the commandline tool "enlightenment_remote". If
your using the default amount of virtual
desktops (4x1), you can set individual
backgrounds to each of the desktops with the following commands. The
first command is for setting the background for the first virtual
desktop, the second for the next one, and so on.
enlightenment_remote -desktop-bg-add 0 0 0 0 /path/to/background.edj
enlightenment_remote -desktop-bg-add 0 0 1 0 /path/to/background.edj
enlightenment_remote -desktop-bg-add 0 0 2 0 /path/to/background.edj
enlightenment_remote -desktop-bg-add 0 0 3 0 /path/to/background.edj
There
is a nice animation every time you switch to a desktop that has a
different background. For more information about the
"enlightenment_remote -desktop-bg-add" command, check
"enlightenment_remote --help".
Compiling Backgrounds:
You can create background EDJ files with the commandline "edje_cc" compiler. For more information regarding Edje, check http://enlightenment.sourceforge.net/Libraries/Edje/index.html.
There will eventually be a graphical tool for creating background EDJ
files, so having to compile them via the commandline is temporary.
In order to compile a background EDJ with "edje_cc", you'll need to
create a directory where you place two files: background.edc and an
image file. Use the following example for background.edc and edit it to
suit your needs:
images{ image, "image.jpg" LOSSY 95;// } collections { // Customize away ;) group{ name, "desktop/background"; parts { part { name, "background_image"; mouse_events, 0; description { state, "default" 0.0; rel1 { relative, 0.0 0.0; offset, 0 0; } rel2 { relative, 1.0 1.0; offset, -1 -1; } image { normal, "image.jpg"; } fill { origin { relative, 0.0 0.0; offset, 0 0; } size { relative, 1.0 1.0; offset, 0 0; } } } } } }
Then make sure the image filename matches the name in background.edc and run:
$ edje_cc -id ./ -fd ./ background.edc background.edj
This should create a file called background.edj, which you'll
probably want to rename and move to ~/.e/e/backgrounds for example.
Setting Up Fake Transparency (experimental):
Fake transparency is not supported in E17. In other words
if you load an EDJ background, programs that use fake transparency (for
example most terminals) will not "see" the background. It is possible
to force fake transparency support by using Esetroot (from Eterm) to
select a "fake" background. This is just an ugly hack
though, and there's no guarantee that the programs that use fake
transparency will work correctly. Forcing fake transparency usage like
this is not recommended (or supported by E17) and may cause various
problems. Even if it works, it will only work with static images -
animated EDJ backgrounds are impossible to get to work with fake
transparency.
For those that want to use fake transparency
(for example for various terminals) or just want to have a normal image
of the background contained inside the EDJ, there is a tool called
edje_thumb that allows you to make thumbnails of any resolution, out of
EDJ files. This is useful in particular if your using an EDJ file that
deep down consists of more than just one image file that's resized (for
example it may have various images that are used to construct the
background) to fit the screen. Most backgrounds on this site for
example are like this. To create a thumbnail out of an EDJ image:
edje_thumb INPUT_EDJE GROUP_TO_LOAD OUT_FILE [OPTIONS]
Where required parameters are: INPUT_EDJE the edje file to look at GROUP_TO_LOAD the group name in the edge
OUT_FILE the output file or format (for multiple frames include
a %i format to accept the number of the frame - same as printf) Where optional OPTIONS are: -h this help -g WxH rendering geometry -og WxH output file geometry -fps N frames per second if capturing an animation -n NUM number of frames to capture if capturing an animation
So for example you could use the following command:
edje_thumb /home/username/background.edj desktop/background /home/username/your_new_image_file.png -og 1600x1200 -g 1600x1200
This
would create a 1600x1200 image from an .edj file - and the geometry
will also be calculated correctly. Now you can easily set this
background to be the one that the applications that use fake
transparency "see" - note though that you need to have Eterm installed
as it includes the Esetroot tool:
Esetroot -s /home/username/image.png
You
can find some EDJ background files on this site, check the
"Backgrounds" link in the site menu. If you already have EDJ background
files and don't want to use Esetroot (or don't have Eterm
installed), you can also load background files with the commandline
tool enlightenment_remote:
enlightenment_remote -default-bg-set /path/to/background.edj
|