25

Here is how my launcher looks:

My latest launcher And here is how I want the launcher to look like:
I want to look like this

Kindly let me know what I can do to have a launcher icon in center as shown in the figure.

5
  • I assume this is on a task bar. try adding a spacer before the launcher
    – ravery
    Sep 14, 2017 at 7:51
  • @ravery please guide me how to do that Sep 14, 2017 at 8:01
  • I don't use unity desktop but the basic steps are -- be sure your taskbars are unlocked. right click on the bar to edit it. add a spacer before the menu button. then drag them over. Note: the launcher itself may be hard to grab, click between icons or at the leading edge.
    – ravery
    Sep 14, 2017 at 8:09
  • @ravery I could not make a right on the task bar or launcher. Hence, I won't be able to make the changes in the task bar. It 16.04. I guess there is not right click for task bar. Can you suggest me if there is any other way around? Sep 14, 2017 at 10:23
  • I do not use unity. I do not know where to unlock them,. but they should be editable
    – ravery
    Sep 14, 2017 at 10:24

5 Answers 5

40

Try the following setting changes in dconf-editor (works on 18.04)

gsettings set org.gnome.shell.extensions.dash-to-dock extend-height false
gsettings set org.gnome.shell.extensions.dash-to-dock dock-position BOTTOM
gsettings set org.gnome.shell.extensions.dash-to-dock transparency-mode FIXED
gsettings set org.gnome.shell.extensions.dash-to-dock dash-max-icon-size 64
gsettings set org.gnome.shell.extensions.dash-to-dock unity-backlit-items true

The property you want to modify to keep the dock only as big as its contents is the extend-height. Set it to false

Source https://linuxconfig.org/how-to-customize-dock-panel-on-ubuntu-18-04-bionic-beaver-linux

3
  • 2
    Remember to install d-conf editor Sep 30, 2020 at 16:15
  • 2
    This is actually great :D and works on 20.04
    – simultsop
    Jun 18, 2021 at 8:59
  • Just for convenience: the command line could be sudo apt-get -y install dconf-editor.
    – zx485
    Apr 27 at 16:50
7

To bring dock to the bottom

$ gsettings set org.gnome.shell.extensions.dash-to-dock dock-position BOTTOM

To bring dock to the center

$ gsettings set org.gnome.shell.extensions.dash-to-dock extend-height false

result

2
  • Your answer does not provide any additional value compared to the most upvoted answer.
    – zx485
    Oct 1, 2021 at 22:40
  • @zx485 most upvoted answer was useful but not clear to me which cmd is for what purpose, so I created another answer which is less and might be more clear to someone who is not cleared. Apr 27 at 9:56
5

I don't know, how to customize default Unity dock, but I think, It must be really difficult. The only tool I found is unity-tweak-tool, but it behaves very strangely and there isn't setting for icons align.

Fortunately there are many alternative docks. I can show you, how to install and customize Plank (Default dock from Elementary OS) and use it together with default Unity dock.

Plank preview

I tested this on Ubuntu 17.04. I hope that it will work on 16.04 as well.

1. Install

Plank is available from official repositories.

sudo apt install plank

2. Set autostart

Hit Alt + F2 and run command: gnome-session-properties. Than Add and fill inputs:

Name: what you want
Command: plank
Comment: what you want

Now close your session and login again.

3. Add Dash to Plank

Plank as default hasn't Dash launcher so you can add it if you want.

I use xdotool key super command to simulate the Super key press. Read this for more info.

sudo apt install xdotool

Plank works with .desktop files so create one. Open Gedit, insert this:

[Desktop Entry]
Name=Dash
GenericName=Open Ubuntu Dash
Exec=xdotool key super
Terminal=false
Type=Application
Icon=/usr/share/unity/icons/launcher_bfb.png
StartupNotify=false

Check if the icon exists or use your own icon.

Save as Dash.desktop to your home folder. Open nautilus (Files), find this file and in Properties/Permissions allow executing file as program.

Drag file from Nautilus and drop it to Plank dock.

4. Customize

For Plank customization hit Alt + F2 and run command: plank --preferences.

Plank preferences

Finally, I suggest you enable auto-hiding for default Unity dock and set it to left side, because in some cases it may overlap Plank.

5

For ubuntu 22 I was able to move the doc to the bottom and center in 2 steps:

  1. Settings > Appearance > Dock > Position on screen > Bottom.

Dock Panel

  1. We'll need to use terminal like the other answers, but only one command:
gsettings set org.gnome.shell.extensions.dash-to-dock extend-height false
2
  • 2
    Thank you for you attempt and sharing knowledge. It was great to know this information. But my friend, the query was related to Ubuntu 16.04. There was no such Dock Panel available to me at that time. Hence, I asked this query. But your information did gave me extra. Always keep helping. Jun 4, 2022 at 7:50
  • it worked well, tks
    – nofomopls
    Aug 25, 2022 at 2:31
0

Can I suggest an alternative ? Install Cairo Dock instead

enter image description here

Try these commands one by one on the terminal

sudo add-apt-repository ppa:cairo-dock-team/ppa

sudo apt-get update

sudo apt-get install cairo-dock cairo-dock-plug-ins

Source :

http://howtoubuntu.org/how-to-install-cairo-dock-3-in-ubuntu

Additional info :

Cairo Dock is available through Ubuntu Software Center as well.

7
  • Will this not affect the Ubuntu functionality? Because adding this last time had made my ubuntu performance worst. Sep 14, 2017 at 8:02
  • I have personally used it sometime back. Worked fine for me. You can remove it if it's still not working as you intended. There are a few more apps that can add Dock ( Plank, for eg.). Try a search on Google.
    – user227495
    Sep 14, 2017 at 8:04
  • @user227495 Is there a repo for xenial as this is the complain I am getting testing this! Sep 14, 2017 at 8:12
  • @George there is a launchpad option which you can use launchpad.net/~cairo-dock-team/+archive/ubuntu/ppa
    – user227495
    Sep 14, 2017 at 8:16
  • There is no xenial version there @user227495! Sep 14, 2017 at 8:18

You must log in to answer this question.

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