Is it possible to 'enclose' more than one application in a single Unity icon/button? In order to keep under control the number of buttons on launcher, it will be very useful to me to store some applications of the same type (e.g. small accessory applications like take screenshot or web application etc. ) in a single button as that is possible with the xfce panel...

enter image description here

link|improve this question
1  
Can you confirm Ubuntu 11.10 and Unity (3D), vs. some other variant. – david6 Nov 24 '11 at 20:30
yes Ubuntu Oneiric & Unity 3D – Gingalone Nov 28 '11 at 13:52
feedback

5 Answers

up vote 10 down vote
+100

Graphical Quicklists

The creation of quicklist using a graphical method is work-in-progress - for example - the Unity Launcher Editor

enter image description here

This works in Natty (ubuntu 11.04) - but due to the python version change, does not work (as at the time of writing this) in oneiric (ubuntu 11.10)

to install

cd ~/Downloads
sudo apt-get install bzr
bzr branch lp:unity-launcher-editor

to run

cd ~/Downloads/unity-launcher-editor
./ule

Manual creation of quicklists

Fortunately, it is simple to create quicklists manually. A quicklist is a .desktop file containing at the minimum the following:

[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Icon=adressbook
Name=Sample Menu
Exec=example_application1

X-Ayatana-Desktop-Shortcuts=example_app2;

[example_apps Shortcut Group]
Name=Name of Application 2
Exec=example_application2
TargetEnvironment=Unity

Let's break this down to the areas you should change (working from top to bottom of the example).

  • Icon=: this is the graphical picture file found in /usr/share/icons
  • Name=: this is the tooltip you see when you hover over the launcher icon
  • Exec=: this is the default executable run when you left click the launcher icon
  • X-Ayatana-Desktop-Shortcuts=: this is a semi-colon separated list of groups.

Each group is a quick-list menu option under the entry [group_name Shortcut Group]

  • example_apps this is the name of the group in the X-Ayatana-Desktop-Shortcuts field
  • Name=: this is the quicklist menu text
  • Exec=: this is the executable run when choosing the quicklist entry

.desktop files should exist in the local folder ~/.local/share/applications

If it doesn't already exist create this folder:

mkdir -p ~/.local/share/applications

Create a file in the folder - for example myquicklist.desktop and drag-and-drop this file from Nautilus into the Unity Launcher.

mimic XFCE launcher

The default XFCE action when clicking on the launcher button is to run an executable. For our launcher you could default to the calculator

Name=My Quicklist
Exec=gcalctool

The other action possible in the XFCE launcher is to just display the list of launcher items. Unfortunately in Unity you cannot do this - it must be a right-click.

The default Exec= must run something - for example you could use this to display a quick pop-up dialog reminding you to right click:

Name=My Quicklist
Exec=zenity --title="action" --info --text="Right-Click for quicklist" --height=50 --width=275 --timeout=2

Example

You gave the following examples that you wanted:

  • Screenshot: Exec=gnome-screenshot -i
  • Dictionary: Exec=xfce4-dict
  • Calculator: Exec=gcalctool

enter image description here

Thus your example .desktop file would look like:

[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Icon=addressbook
Name=My Quicklist
Exec=zenity --title="action" --info --text="Right-Click for quicklist" --height=50 --width=275 --timeout=2

X-Ayatana-Desktop-Shortcuts=screenshot;dictionary;calculator

[screenshot Shortcut Group]
Name=Gnome Screenshot
Exec=gnome-screenshot -i
TargetEnvironment=Unity

[dictionary Shortcut Group]
Name=XFCE Dictionary
Exec=xfce4-dict
TargetEnvironment=Unity

[calculator Shortcut Group]
Name=Gnome Calculator
Exec=gcalctool
TargetEnvironment=Unity
link|improve this answer
feedback

Yes, you can use Launcher quicklists to add applications to the right click menu of a launcher icon. Look at this question:

Specifically the libreoffice example can be modified to just run whatever applications you want under the same icon.

link|improve this answer
Thanx Jorge, but in my Ubuntu Oneiric there is not any *.desktop file in /usr/share/applications/ moreover I can't follow the LibreOffice example because it has a starting centre while I'd like to create a new botton in launcher (with a chosen icon) which contains some useful 'small' applications (Screenshot, Dictionary, Calculator, Force quit ecc.)... Is that possible? – Gingalone Nov 24 '11 at 15:52
If you're looking at that folder with Nautilus, the names displayed are different than the file names for .desktop files. On the CLI the ls command will show the real file names which you need to edit those files. – fragos Nov 25 '11 at 3:02
feedback

For Ubuntu 11.10 (Oneiric) and Unity (3D)

Example: "Ubuntu Toolbox" multi-purpose icon

Description: A single 'toolbox' icon, replacing multiple Unity launcher icons, for: Systems Settings (default), Ubuntu Tweak, Ubuntu Software Center, and Software Updates.

enter image description here

Comments: I did make some compromises on icons (not custom), file naming, and the default item. Other alternatives might clash or could be confused with existing items. (be warned)

mkdir ~/.local/share/applications  (if required)

gedit ~/.local/share/applications/toolbox.desktop &

Note: The ampersand '&' releases the command line immediately.

My custom 'toolbox.desktop' file: (can be easily edited)

[Desktop Entry]
Name=Ubuntu Toolbox
Comment=System Settings
Exec=gnome-control-center --overview
Icon=redhat-tools
Terminal=false
Type=Application
StartupNotify=true
Categories=GNOME;GTK;System;
OnlyShowIn=GNOME;Unity;
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=gnome-control-center
X-GNOME-Bugzilla-Component=shell
X-GNOME-Bugzilla-Version=3.2.1
X-Ubuntu-Gettext-Domain=gnome-control-center-2.0

X-Ayatana-Desktop-Shortcuts=UbuntuTweak;SoftwareCenter;SoftwareUpdates;

[UbuntuTweak Shortcut Group]
Name=Ubuntu Tweak
Exec=ubuntu-tweak
TargetEnvironment=Unity

[SoftwareCenter Shortcut Group]
Name=Ubuntu Software Center
Exec=software-center
TargetEnvironment=Unity

[SoftwareUpdates Shortcut Group]  
Name=Update Manager  
Exec=update-manager -c  
TargetEnvironment=Unity
link|improve this answer
feedback

I think both david6 & fossfreedom's answers are quite good, this is just to show you a variation of the same.

In this case it's a 'Utility' icon I have for various actions, it uses standard app's, some shell scripts & commands. Because I use synaptic the most i've set the left click on the icon to run synaptic, everything else is off of the right click quicklists.

One additional point of interest - in custom .desktops with quicklists the 'X-Ayatana-Desktop-Shortcuts=' line determines what is shown in the quicklist & the order shown.

Ex. - You could have 10 [whatever Shortcut Group] entries but only show some of them by what's in the 'X-Ayatana-Desktop-Shortcuts=' line

[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Exec=synaptic-pkexec
Name=Utilities
Icon=/usr/share/icons/Humanity/categories/48/applications-other.svg
X-Ayatana-Desktop-Shortcuts=UpdateManager;CompizConfig;Htop;GetUpdates;NautilusActions;DconfEditor;GconfEditor;ForceQuit;ScreenShot;SeachFiles;Gksu;

[UpdateManager Shortcut Group]
Name=Update Manager
Exec=/usr/bin/update-manager
TargetEnvironment=Unity

[Htop Shortcut Group]
Name=Htop
Exec=htop1
TargetEnvironment=Unity

[GetUpdates Shortcut Group]
Name=Update Sources
Exec=update1
TargetEnvironment=Unity

[NautilusActions Shortcut Group]
Name=Nautilus Actions
Exec=nautilus-actions-config-tool
TargetEnvironment=Unity

[CompizConfig Shortcut Group]
Name=Compiz Settings
Exec=ccsm
TargetEnvironment=Unity

[GconfEditor Shortcut Group]
Name=Gconf Editor
Exec=gconf-editor
TargetEnvironment=Unity

[ForceQuit Shortcut Group]
Name=Force Quit
Exec=xkill
TargetEnvironment=Unity

[ScreenShot Shortcut Group]
Name=Screen Shots
Exec=gnome-screenshot --interactive
TargetEnvironment=Unity

[SeachFiles Shortcut Group]
Name=Search For Files
Exec=gnome-search-tool
TargetEnvironment=Unity

[DconfEditor Shortcut Group]
Name=Dconf Editor
Exec=dconf-editor
TargetEnvironment=Unity

[Gksu Shortcut Group]
Name=Root Nautilus
Exec=gksudo nautilus
TargetEnvironment=Unity

To give Ex. of small scripts, Exec=htop1 is just a file named htop1 in a bin in my $PATH (~/bin

#!/bin/bash
gnome-terminal --command  htop 

Exec=update1 is one named update1

#!/bin/bash
gnome-terminal --command "sudo apt-get update"

In a .desktop with extensive quicklists if one wanted to save space on the X-Ayatana-Desktop-Shortcuts= line you could name your shortcut groups in a simpler fashion, using something like Scg1;Scg2;Scg3; ect, so

X-Ayatana-Desktop-Shortcuts=Scg1;Scg2;Scg3; ect.

As an example taking my first entry

[Scg1 Shortcut Group]
Name=Update Manager
Exec=/usr/bin/update-manager
TargetEnvironment=Unity

Lots of things & variations of how you can do with your launcher icons, quicklists, ect.,

link|improve this answer
feedback

I know that this is not an answer to your question, but i think it is the same as launcher do(or simply alternatives).

1) try Gnome-Pie (an application launcher with some really cool effects) Gnome-Pie


2) Using docks, such as Glx-Dock/Cairo-Dock(such as dock in mac) and docky(they are in the software-center).

Cairo-Dock


3) Using shortcuts to open programs(write keyboard in the dash and open it >> go to shortcuts tap >> go to custom shortcuts >> press the + button >> write the program you want to open with the shortcut >> apply >> assign a shortcut to it)

shortcuts

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.