20

I am using Ubuntu 12.04 LTS.

I have Google Chrome in my launcher and I want to add the parameter --scroll-pixels=50 when I open it.

However, I don't get any option to set the command line options of the link.

Any ideas?

3 Answers 3

22

The easiest thing to do is:

  1. Remove your existing Chrome icon from the Unity launcher
  2. Open the Unity Dash and make it non-maximized

enter image description here

  1. Type "chrome"
  2. Drag the Chrome icon to your desktop
  3. Right-click on the Chrome icon on your desktop and choose "Properties"
  4. Modify "Command" to insert --scroll-pixels=50 before %U and close the window
  5. Move the icon from your desktop to some folder (where it will stay)
  6. Drag the icon from the folder to your Unity launcher
2
  • 1
    Wow, that definitely wasn't intuitive. Thanks for these steps!
    – Bolo
    Nov 30, 2014 at 22:36
  • 1
    Would you know how to do the same for Ubuntu 18.04?
    – zwolin
    Sep 26, 2018 at 16:57
7
  1. Type "chrome"
  2. Drag the Chrome icon to your desktop
  3. Find the name of chrome which is 'google-chrome.desktop' in my PC
  4. sudo find / -name google-chrome.desktop, I found the location of the launch in /usr/share/applications/google-chrome.desktop
  5. Modify the 'Exec' value
  6. save and exit, rm the Chrome icon in your desktop
1
  • 1
    On 18:10, the file is /usr/share/applications/chromium-browser.desktop Mar 11, 2019 at 9:51
6

A simple way is to install alacarte, which is the old menu editor for Ubuntu.

sudo apt-get install alacarte

Simply run it, find the shortcut (Applications -> Internet -> Google Chrome), click Proprties, and add your argument to the command.

*note, this will change the shortcut both in the dash and launcher, which may or may not be what you want.

1
  • 1
    Doesn't seem to work anymore. Adding a space to the command text field disables the "OK" button
    – ecnepsnai
    Jun 2, 2015 at 20:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .