在 Ubuntu 里如何下载、安装和配置 Plank Dock
Dock Plank
一个众所周知的事实就是，Linux 是一个用户可以高度自定义的系统，有很多选项可以选择 —— 作为操作系统，有各种各样的发行版，而对于单个发行版来说，又有很多桌面环境可以选择。与其他操作系统的用户一样，Linux 用户也有不同的口味和喜好，特别是对于桌面来说。


一些用户并非很在意他们的桌面，而其他一些则非常关心，要确保他们的桌面看起来很酷，很有吸引力，对于这种情况，有很多不错的应用可以派上用场。有一个应用可以给你的桌面带来活力 —— 特别是当你常用一个全局菜单的时候 —— 这就是 dock 。Linux 上有很多 dock 应用可选用；如果你希望是一个最简洁的，那么就选择 [Plank](https://launchpad.net/plank) 吧，文章接下来就要讨论这个应用。


**注意**：接下提到的例子和命令都已在 Ubuntu（版本 14.10）和 Plank（版本 0.9.1.1383）上测试通过。


### Plank


![](/data/attachment/album/201509/22/073547itudzff6fz7xu3sm.jpg)


官方的文档描述 Plank 是“这个星球上最简洁的 dock”。该项目的目的就是仅提供一个 dock 需要的功能，尽管这是很基础的一个库，却可以被扩展，创造其他的含更多高级功能的 dock 程序。


这里值得一提的就是，在 elementary OS 里，Plank 是预装的。并且 Plank 是 Docky 的基础，Docky 也是一个非常流行的 dock 应用，在功能上与 Mac OS X 的 Dock 非常相似。


### 下载和安装


通过在终端里执行下面的命令，可以下载并安装 Plank：



```
sudo add-apt-repository ppa:docky-core/stable
sudo apt-get update
sudo apt-get install plank

```

安装成功后，你就可以在 Unity Dash（见下面图片）里通过输入 Plank 来打开该应用，或者从应用菜单里面打开，如果你没有使用 Unity 环境的话。


![](/data/attachment/album/201509/22/073549pvu9jfkvzf771u3r.png)


### 特性


当 Plank 启用后，你会看见它停靠在你桌面的底部中间位置。


![](/data/attachment/album/201509/22/073549gjeiggmg8zmggp5k.jpg)


正如上面图片显示的那样，dock 包含许多带橙色标示的应用图标，这表明这些应用正处于运行状态。无需说，你可以点击一个图标来打开那个应用。同时，右击一个应用图标会给出更多的选项，你可能会感兴趣。举个例子，看下面的屏幕快照：


![](/data/attachment/album/201509/22/073550vgqi5imlkiwiizcf.jpg)


为了获得配置的选项，你需要右击一下 Plank 的图标（左数第一个），然后点击 Preferences 选项。这就会出现如下的窗口。


![](/data/attachment/album/201509/22/073550scz7y31kcc1aqcfs.png)


如你所见，Preferences 窗口包含两个标签：Apperance 和 Behavior，前者是默认选中的。Appearance 标签栏包含 Plank 主题相关的设置，dock 的位置，对齐，还有图标相关的，而 Behavior 标签栏包含 dock 本身相关的设定。


![](/data/attachment/album/201509/22/073550ydf8koopoe112rgp.png)


举个例子，我在 Appearance 里改变 dock 的位置为右侧，在 Behavior 里锁定图标（这表示右击选项中不再有 “Keep in Dock”）。


![](/data/attachment/album/201509/22/073551i79gz6d7t297o9m7.jpg)


如你所见的上面屏幕快照一样，改变生效了。类似地，根据你个人需求，改变任何可用的设定。


### 结论


如我开始所说的那样，使用 dock 不是强制的。尽管如此，使用一个会让事情变得方便，特别是你习惯了 Mac，而最近由于一些原因切换到了 Linux 系统。就其本身而言，Plank 不仅提供简洁性，还有可信任和稳定性 —— 该项目一直被很好地维护着。




---


via: <https://www.maketecheasier.com/download-install-configure-plank-dock-ubuntu/>


作者：[Himanshu Arora](https://www.maketecheasier.com/author/himanshu/) 译者：[wi-cuckoo](https://github.com/wi-cuckoo) 校对：[wxy](https://github.com/wxy)


本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译，[Linux中国](https://linux.cn/) 荣誉推出


OK
![Plank Dock In Ubuntu Featured](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-featured.jpg)

Macs may have popularized launcher docks, but it’s Linux where they were perfected. Apps like [Plank](https://launchpad.net/plank) allow you to have such a dock on your desktop. From there, you can launch your favorite apps, juggle the active ones, and check out useful information.

Let’s see how you can install, use, and configure Plank in Ubuntu for quick and snazzy-looking access to your favorite apps.

## Installation

If you’re on Ubuntu or a compatible distribution like Mint, you can find Plank in the default repositories. To bring it on-board, fire up your favorite terminal and enter:

sudo apt install plank

![Plank Dock In Ubuntu Installation](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-installation.jpg)

When Plank is installed, locate it among the rest of your software and run it.

![Plank Dock In Ubuntu Run](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-run.jpg)

This may very well be the last time you’re launching your apps “the official way.”

## Usage

Plank’s use is straightforward and doesn’t differ from any typical toolbar-with-icons on any desktop or any operating system. The program comes pre-configured with some of the most popular apps stuck on it, out of which you’re probably using at least one or two. You can click their icon there to launch them.

![Plank Dock In Ubuntu Plank](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-plank.jpg)

If you don’t recognize some icons, Plank doesn’t display labels by default. However, it will show the name of each app if you hover your cursor over its icon.

![Plank Dock In Ubuntu Labels](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-labels.jpg)

Plank supports dynamic menus that expose some functionality of each app. For example, by right-clicking on an icon for the terminal, you can open a new window or access its preferences.

![Plank Dock In Ubuntu Right Click Terminal](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-right-click-terminal.jpg)

By right-clicking the icon of a media player app, though, you’ll be able to pause or resume playing, skip tracks, etc.

![Plank Dock In Ubuntu Right Click Media](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-right-click-media.jpg)

To rearrange the icons on Plank, click on one of them and keep the mouse button pressed. Then, drag the icon where you want it on the dock.

![Plank Dock In Ubuntu Re Arrange Icons](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-re-arrange-icons.jpg)

To remove an icon from the dock, either left-click and drag it outside the dock or right-click and uncheck “Keep in Dock.”

## Configuration

Right-clicking to quickly access your apps’ functions without having to visit their windows is fantastic. However, if the right-click shows each app’s menu, how can you access Plank’s options?

Theoretically, you can right-click directly in the empty space to the left or right of the dock, and, supposedly, its menu will pop up.

This practically never worked for me, so I’m using the easier shortcut instead: keep `Ctrl` held down and right-click anywhere on the dock. Plank’s menu will appear. Choose Preferences from this menu to access the program’s options.

![Plank Dock In Ubuntu Menu Preferences](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-menu-preferences.jpg)

There aren’t many options available, but those that exist can radically change how Plank looks and performs. You’ll find them in three groups: Appearance, Behaviour, and Docklets.

### Appearance

In Appearance, you can change Plank’s Theme and its Position on the screen (top, right, bottom, or left). You can disable the default restriction that keeps it on your Primary Display to have it show up on your other monitors.

![Plank Dock In Ubuntu Appearance](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-appearance.jpg)

Plank appears by default at the center of the screen. You can change that with the Alignment drop-down menu and fine-tune its position with the slider on the right.

There’s also some control over how the icons look. You can change the Icon Alignment and the Icon Size. Plank might not be the fanciest dock, but it does offer a zoom effect that you can enable. When enabled, it will make the icons larger when you hover over them. There’s a slider that controls the zoom level, too. However, when we tried the largest value, it made the icons look somewhat fuzzy.

### Behaviour

In the Behaviour tab, you can choose how Plank will hide when a window tries to share the same screen space. There are different ways it can respond to an approaching window, and you can also add a Hide Delay and Unhide Delay. Or you can disable the feature altogether and have Plank always stay on your screen – even if that means it will overlap with window content.

![Plank Dock In Ubuntu Behaviour](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-behaviour.jpg)

The subtitle Item Management doesn’t clarify that the options underneath it refer to the icons that appear on Plank.

By disabling “Show Unpinned” (that’s on by default), you can force Plank only to show the apps you’ve manually pinned on it and ignore everything else. Take heed, though; if you disable all other toolbars on your desktop and this option in Plank, you’ll have to jump between your active windows using shortcuts.

Enabling “Lock Icons” will stick the current icons where they are and forbid any tweaks to their placement.

Finally, “Restrict to Workspace” will have Plank only show the apps that are active on the current workspace and ignore the rest.

## Docklets

The last group, Docklets, allows you to add the functionality of a proper toolbar to Plank. Instead of only presenting icons for pinned and active apps, you can add a “start menu” equivalent for instant access to all your installed software, a battery indicator, a clock, etc.

![Plank Dock In Ubuntu Docklets](https://www.maketecheasier.com/assets/uploads/2020/12/plank-dock-in-ubuntu-docklets.jpg)

Plank might not be the most impressive dock, but it offers a perfect balance between looks, functionality, and customizability. Meanwhile, do also [check out some other dock applications for Linux](https://www.maketecheasier.com/linux-dock-roundup/).

Our latest tutorials delivered straight to your inbox