PDA

View Full Version : [SOLVED] 12.04 Unity: create link to a file to open it from the launchbar.



finny388
September 14th, 2012, 01:06 AM
Sorry if this has been asked before
I searched thread titles with
file
shortcut
symlink
link
with unity and came up with nothing

I just want to open a file from the Unity launchbar.

I wish it was as easy dragging a file to the launchbar.

I have a pdf I open most every day. How do I open it with an icon on the launchbar? :)

Anyone's help very appreciated.

finny388
September 16th, 2012, 03:44 PM
^

vexorian
September 16th, 2012, 04:16 PM
No it is not as easy as dragging it to the launchbar.

But you can have a manual, very complicated way.

- First, install menulibre (sudo apt-get install menulibre)
- Then use the menulibre program to create a launcher.

The command should be like:

evince /home/whateverusername/path/yourfile.pdf

Then pick an icon . The "name" for the icon would be "application-pdf" (no quotes)

finny388
September 16th, 2012, 05:41 PM
Thanks! This looks like a cool menu editor.

I've created the launcher in the menu editor (actually modified the Evince launcher)

But how do I get it onto the Unity bar? Or anywhere else?

also, what file formats are accepted for the icon?

vexorian
September 16th, 2012, 05:52 PM
The icon seems to admit svg or png. Maybe it admits more things, but those should cover all needs.

Go to the dash (The menu that appears when you click the ubuntu icon). This is the moment in which you can drag and drop an app launcher to the side bar.

PaulInBHC
September 16th, 2012, 05:57 PM
When you start an app, the icon appears in the launcher. Right click it and select Lock to Launcher.

finny388
September 16th, 2012, 06:06 PM
Oh wow
This works great.

When I opened dash, the menu editor got covered and I thought how can I drag? Then typed in the title I gave it and there it was. Dragged to unity bar :)

It errored at first b/c there are spaces in the filename so I put the whole path in quotes.

Now it works like a charm! Thanks vexorian

and good tip PaulInBHC