Merge pull request #6114 from geekpi/master

translating
This commit is contained in:
geekpi 2017-10-08 19:46:00 -05:00 committed by GitHub
commit 1397343f2a
2 changed files with 100 additions and 103 deletions

View File

@ -1,103 +0,0 @@
traslating---geekp
A Window Into the Linux Desktop
============================================================
![linux-desktop](http://www.linuxinsider.com/article_images/story_graphics_xlarge/xl-2016-linux-1.jpg)
![](http://www.linuxinsider.com/images/2015/image-credit-adobe-stock_130x15.gif)
"What can it do that Windows can't?"
That is the first question many people ask when considering Linux for their desktop. While the open source philosophy that underpins Linux is a good enough draw for some, others want to know just how different its look, feel and functionality can get. To a degree, that depends on whether you choose a desktop environment or a window manager.
If you want a desktop experience that is lightning fast and uncompromisingly efficient, foregoing the classic desktop environment for a window manager might be for you.
### What's What
"Desktop environment" is the technical term for a typical, full-featured desktop -- that is, the complete graphical layout of your system. Besides displaying your programs, the desktop environment includes accoutrements such as app launchers, menu panels and widgets.
In Microsoft Windows, the desktop environment consists of, among other things, the Start menu, the taskbar of open applications and notification center, all the Windows programs that come bundled with the OS, and the frames enclosing open applications (with a dash, square and X in the upper right corner).
There are many similarities in Linux.
The Linux [Gnome][3] desktop environment, for instance, has a slightly different design, but it shares all of the Microsoft Windows basics -- from an app menu to a panel showing open applications, to a notification bar, to the windows framing programs.
Window program frames rely on a component for drawing them and letting you move and resize them: It's called the "window manager." So, as they all have windows, every desktop environment includes a window manager.
However, not every window manager is part of a desktop environment. You can run window managers by themselves, and there are reasons to consider doing just that.
### Out of Your Environment
For the purpose of this column, references to "window manager" refer to those that can stand alone. If you install a window manager on an existing Linux system, you can log out without shutting down, choose the new window manager on your login screen, and log back in.
You might not want to do this without researching your window manager first, though, because you will be greeted by a blank screen and sparse status bar that may or may not be clickable.
There typically is a straightforward way to bring up a terminal in a window manager, because that's how you edit its configuration file. There you will find key- and mouse-bindings to launch programs, at which point you actually can use your new setup.
In the popular i3 window manager, for instance, you can launch a terminal by hitting the Super (i.e., Windows) key plus Enter -- or press Super plus D to bring up the app launcher. There you can type an app name and hit Enter to open it. All the existing apps can be found that way, and they will open to full screen once selected.
[![i3 window manager](http://www.linuxinsider.com/article_images/2017/84473_620x388-small.jpg)][4] (Click Image to Enlarge)
i3 is also a tiling window manager, meaning it ensures that all windows expand to evenly fit the screen, neither overlapping nor wasting space. When a new window pops up, it reduces the existing windows, nudging them aside to make room. Users can toggle to open the next window either vertically or horizontally adjacent.
### Features Can Be Friends or Foes
Desktop environments have their advantages, of course. First and foremost, they provide a feature-rich, recognizable interface. Each has its signature style, but overall they provide unobtrusive default settings out of the box, which makes desktop environments ready to use right from the start.
Another strong point is that desktop environments come with a constellation of programs and media codecs, allowing users to accomplish simple tasks immediately. Further, they include handy features like battery monitors, wireless widgets and system notifications.
As comprehensive as desktop environments are, the large software base and user experience philosophy unique to each means there are limits on how far they can go. That means they are not always very configurable. With desktop environments that emphasize flashy looks, oftentimes what you see is what you get.
Many desktop environments are notoriously heavy on system resources, so they're not friendly to lower-end hardware. Because of the visual effects running on them, there are more things that can go wrong, too. I once tried tweaking networking settings that were unrelated to the desktop environment I was running, and the whole thing crashed. When I started a window manager, I was able to change the settings.
Those prioritizing security may want to avoid desktop environments, since more programs means greater attack surface -- that is, entry points where malicious actors can break in.
However, if you want to give a desktop environment a try, XFCE is a good place to start, as its smaller software base trims some bloat, leaving less clutter behind if you don't stick with it.
It's not the prettiest at first sight, but after downloading some GTK theme packs (every desktop environment serves up either these or Qt themes, and XFCE is in the GTK camp) and enabling them in the Appearance section of settings, you easily can touch it up. You can even shop around at this [centralized gallery][5] to find the theme you like best.
### You Can Save a Lot of Time... if You Take the Time First
If you'd like to see what you can do outside of a desktop environment, you'll find a window manager allows plenty of room to maneuver.
More than anything, window managers are about customization. In fact, their customizability has spawned numerous galleries hosting a vibrant community of users whose palette of choice is a window manager.
The modest resource needs of window managers make them ideal for lower specs, and since most window managers don't come with any programs, they allow users who appreciate modularity to add only those they want.
Perhaps the most noticeable distinction from desktop environments is that window managers generally focus on efficiency by emphasizing mouse movements and keyboard hotkeys to open programs or launchers.
Keyboard-driven window managers are especially streamlined, since you can bring up new windows, enter text or more keyboard commands, move them around, and close them again -- all without moving your hands from the home row. Once you acculturate to the design logic, you will be amazed at how quickly you can blaze through your tasks.
In spite of the freedom they provide, window managers have their drawbacks. Most significantly, they are extremely bare-bones out of the box. Before you can make much use of one, you'll have to spend time reading your window manager's documentation for configuration syntax, and probably some more time getting the hang of said syntax.
Although you will have some user programs if you switched from a desktop environment (the likeliest scenario), you also will start out missing familiar things like battery indicators and network widgets, and it will take some time to set up new ones.
If you want to dive into window managers, i3 has [thorough documentation][6] and straightforward configuration syntax. The configuration file doesn't use any programming language -- it simply defines a variable-value pair on each line. Creating a hotkey is as easy as writing "bindsym", the key combination, and the action for that combination to launch.
While window managers aren't for everyone, they offer a distinctive computing experience, and Linux is one of the few OSes that allows them. No matter which paradigm you ultimately go with, I hope this overview gives you enough information to feel confident about the choice you've made -- or confident enough to venture out of your familiar zone and see what else is available. 
--------------------------------------------------------------------------------
作者简介:
**Jonathan Terrasi** has been an ECT News Network columnist since 2017\. His main interests are computer security (particularly with the Linux desktop), encryption, and analysis of politics and current affairs. He is a full-time freelance writer and musician. His background includes providing technical commentaries and analyses in articles published by the Chicago Committee to Defend the Bill of Rights.
-----------
via: http://www.linuxinsider.com/story/84473.html?rss=1
作者:[ ][a]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:
[1]:http://www.linuxinsider.com/story/84473.html?rss=1#
[2]:http://www.linuxinsider.com/perl/mailit/?id=84473
[3]:http://en.wikipedia.org/wiki/GNOME
[4]:http://www.linuxinsider.com/article_images/2017/84473_1200x750.jpg
[5]:http://www.xfce-look.org/
[6]:https://i3wm.org/docs/

View File

@ -0,0 +1,100 @@
进入 Linux 桌面的窗口
============================================================
![linux-desktop](http://www.linuxinsider.com/article_images/story_graphics_xlarge/xl-2016-linux-1.jpg)
![](http://www.linuxinsider.com/images/2015/image-credit-adobe-stock_130x15.gif)
“它能做什么 Windows 不能做的吗?”
这是许多人在考虑使用 Linux 桌面时的第一个问题。虽然支撑 Linux 的开源哲学对于某些人来说就是一个很好的理由,但是一些人想知道它在外观、感受和功能上有多么不同。在某种程度上,这取决于你是否选择桌面环境或窗口管理器。
如果你想要的是闪电般快速的桌面体验且向高效妥协, 那么上述的经典桌面中的窗口管理器可能适合你。
### 什么是什么
“桌面环境”是典型的全功能桌面的技术术语,即系统的完整图形化布局。除了显示你的程序,桌面环境还包括应用程序启动器,菜单面板和小部件等。
在 Microsoft Windows 中,桌面环境包括开始菜单,打开的程序的任务栏和通知中心,还有与操作系统捆绑在一起的所有 Windows 程序,以及打开程序的框架(有破折号、正方形和右上角的 X
Linux 中有很多相似之处。
例如Linux [Gnome][3] 桌面环境的设计略有不同,但它共享了所有的 Microsoft Windows 的基本 - 从应用程序菜单到显示打开的应用程序的面板、通知栏、窗口框架程序。
窗口程序框架依赖于一个组件来绘制它们,并允许你移动并调整大小:它被称为“窗口管理器”。因为它们都有窗口,每个桌面环境都包含一个窗口管理器。
然而,并不是每个窗口管理器都是桌面环境的一部分。你可以只运行窗口管理器,并且有理由考虑这么做。
### 离开你的环境
在本专栏中,对“窗口管理器”的引用指的是可以独立进行的。如果在现有的 Linux 系统上安装了一个窗口管理器,你可以在不关闭的情况下注销,在登录屏幕上选择新的窗口管理器,然后重新登录。
不过, 在研究你的窗口管理器之前,你可能不想这么做,因为你会看到空白屏幕和稀疏的状态栏,这可能可以或不可以点击的。
通常情况下,可以直接在窗口管理器中启动终端,因为这是你编辑其配置文件的方式。在那里你会发现按键和鼠标绑定来启动程序,此时你实际上可以使用你的新设置。
例如,在流行的 i3 窗口管理器中,你可以通过按下 Super即 Windows键加 Enter 键来启动终端,或者按 Super + D 启动应用程序启动器。你可以在其中输入应用程序名称,然后按 Enter 键将其打开。所有现有的应用程序都可以通过这种方式找到,一旦选择后,它们将会全屏打开。
[![i3 window manager](http://www.linuxinsider.com/article_images/2017/84473_620x388-small.jpg)][4] (Click Image to Enlarge)
i3 还是一个平铺的窗口管理器,这意味着它可以确保所有的窗口均匀地扩展到屏幕,既不重叠也不浪费空间。当弹出新窗口时,它会减少现有的窗口,将它们推到一边腾出空间。用户可以以垂直或水平的方式切换到相邻的窗口打开。
### 功能可以是朋友或敌人
当然,桌面环境有其优点。首先,它们提供功能丰富,可识别的界面。每个都有其签名风格,但总体而言,它们提供了不引人注目的默认设置,这使得桌面环境从一开始就可以使用。
另一个优点是桌面环境有一组程序和媒体编解码器,允许用户立即完成简单的任务。此外,它们还包括便携式功能,如电池监视器、无线小部件和系统通知。
如桌面环境一样完善,大型软件基础和用户体验理念独一无二,这就意味着它们能走多远都是有限度的。这意味着它们并不总是非常可配置。桌面环境强调的是漂亮的外表,很多时候你所见并不是你所得的。
许多桌面环境对系统资源的要求是众所周知的,所以它们对低端硬件不友善。因为在它们身上运行的视觉效果,还有更多的事情可能会出错。我曾经尝试调整与我正在运行的桌面环境无关的网络设置,但系统崩溃了。当我打开一个窗口管理器,我就可以改变设置。
那些优先考虑安全性的人可能希望避免桌面环境,因为更多的程序意味着更大的攻击面 - 也就是恶意角色可以突破的入口点。
然而如果你想尝试一下桌面环境XFCE 是一个很好的开始,因为它的较小的软件基础删除了一些膨胀,如果你不坚持使用,可以留下更少的混乱。
乍一看,它不是最漂亮的,但在下载了一些 GTK 主题包(每个桌面环境都可以提供这些或 Qt 主题XFCE 在 GTK 阵营中),并且在“外观”部分的设置中,你可以轻松地修改。你甚至可以在这个[集中式画廊][5]中找到你最喜欢的主题。
### 你可以节省大量的时间..如果你把时间放在第一位
如果你想了解桌面环境之外可以做什么,你会发现窗口管理器有足够的空间来操纵。
无论如何,窗口管理器都是关于定制的。事实上,它们的可定制性已经催生了无数的画廊, 承载着一个充满活力的社区用户,他们选择的调色板是窗口管理器。
窗口管理器的少量资源需求使它们成为较低规格硬件的理想选择,并且由于大多数窗口管理器不附带任何程序,因此允许喜欢模块化的用户只添加所需的程序。
与桌面环境最为显著的区别可能是,窗口管理器通常通过鼠标移动和键盘热键来打开程序或启动器来聚焦效率。
键盘驱动的窗口管理器特别精简,因为你可以启动新的窗口、输入文本或更多的键盘命令、移动它们,并再次关闭它们,这一切无需将手从主页移开。一旦你符合设计逻辑,你会惊讶于你能够快速地完成任务。
尽管它们提供了自由,窗口管理器也有其缺点。最显著的是,它们是赤裸裸的开箱即用。在你可以使用其中一个之前,你必须花时间阅读窗口管理器的文档以获取配置语法,可能还需要更多的时间来获取所说语法的窍门。
如果你从桌面环境(最可能的情况)切换过来,尽管你会有一些用户程序,你也将缺少熟悉的东西,如电池指示器和网络小部件,并且需要一些时间来设置新的。
如果你想深入窗口管理器i3 有[完整的文档][6]和简单的配置语法。配置文件不使用任何编程语言 - 它只是在每行上定义一个变量值对。创建热键只要输入 “bindsym”它是键盘绑定以及该组合启动的动作。
虽然窗口管理器不适合每个人,但它们提供独特的计算体验,而 Linux 是少数允许使用的操作系统之一。无论你最终采用哪种模式,我希望这个概述能够给你足够的信息,以便对你所做的选择感到自信 - 或者有足够的信心跨出您熟悉的区域来看看还有什么可用的。
--------------------------------------------------------------------------------
作者简介:
** Jonathan Terrasi ** 自 2017 年以来一直是 ECT 新闻网专栏作家。他的主要兴趣是计算机安全(特别是 Linux 桌面)、加密和分析政治和时事。他是全职自由作家和音乐家。他的背景包括在芝加哥委员会发表的关于维护人权法案的文章中提供技术评论和分析。
-----------
via: http://www.linuxinsider.com/story/84473.html?rss=1
作者:[ ][a]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:
[1]:http://www.linuxinsider.com/story/84473.html?rss=1#
[2]:http://www.linuxinsider.com/perl/mailit/?id=84473
[3]:http://en.wikipedia.org/wiki/GNOME
[4]:http://www.linuxinsider.com/article_images/2017/84473_1200x750.jpg
[5]:http://www.xfce-look.org/
[6]:https://i3wm.org/docs/