mirror of
https://github.com/LCTT/TranslateProject.git
synced 2025-02-03 23:40:14 +08:00
commit
f9776b1c36
@ -1,91 +0,0 @@
|
||||
[#]: subject: "3 delightful features of the Linux QtFM file manager"
|
||||
[#]: via: "https://opensource.com/article/22/12/linux-file-manager-qtfm"
|
||||
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
|
||||
[#]: collector: "lkxed"
|
||||
[#]: translator: "geekpi"
|
||||
[#]: reviewer: " "
|
||||
[#]: publisher: " "
|
||||
[#]: url: " "
|
||||
|
||||
3 delightful features of the Linux QtFM file manager
|
||||
======
|
||||
|
||||
QtFM is a simple file manager that aims to provide the basic features of file management through a fast and intuitive interface. It's available for Linux, BSD, and macOS.
|
||||
|
||||
QtFM, as its name suggests, uses the Qt (canonically pronounced "cute") programming toolkit. I've worked with the Qt toolkit both in C++ and Python, and using it is always a pleasure. It's cross-platform, it's got multiple levels of useful abstraction so developers don't have to interact directly with vendor-specific SDKs, and it's highly configurable. From a user's perspective, it's a "natural" and fast experience, whether you're on the latest hardware or on an [old computer][1].
|
||||
|
||||
### Using QtFM
|
||||
|
||||
There's not much to QtFM. It focuses on being exactly what its name claims: a file manager (FM) for Qt. The layout is what you probably expect from a file manager: a list of common places and devices on the left and a list of files on the right.
|
||||
|
||||
![QtFM file manager][2]
|
||||
|
||||
It's got just four menus.
|
||||
|
||||
- **File**: Create a new file or folder, open a new tab or window, or exit the application.
|
||||
- **Edit**: Copy, paste, move to trash, or create a new bookmark in the left panel.
|
||||
- **View**: Toggle between the list and icon views, adjust the layout.
|
||||
- **Help**: Licensing information, and links to online documentation.
|
||||
|
||||
Interacting with QtFM is largely the same experience you're probably used to with any standard-issue file manager. You can click around to navigate, open files in its default application, drag-and-drop files and folders, copy and paste files and folders, launch applications, and whatever else you do when you're interacting with the contents of your computer. It's familiar, so there's basically no learning curve and no unpleasant surprises.
|
||||
|
||||
There are, however, several pleasant surprises. Here are three of my favorites.
|
||||
|
||||
### 1. Put a command into a contextual menu
|
||||
|
||||
With QtFM, you can add any command you can run in a terminal to the right-click contextual menu. For instance, suppose you want an option to convert an image into the [webp format][3] to the right-click menu. There's no complex framework or scripting language to learn, you don't need to develop a plugin. You can do it in just 3 steps:
|
||||
|
||||
- Go to the **Edit** menu and select **Settings**
|
||||
- Click on the **Custom actions tab**
|
||||
- Click the **Add** button and enter the command you want to run, using `%f` for the source file and `%n` for the new file
|
||||
|
||||
![QtFM custom actions][4]
|
||||
|
||||
The action now appears in your QtFM contextual menu.
|
||||
|
||||
### 2. Flexible layout
|
||||
|
||||
One of the built-in features of the Qt toolkit is that many of its components are ("widgets") detachable. QtFM takes advantage of this and allows you to unlock its layout from the **View** menu. Once unlocked, you can drag toolbars and side panels, anchoring them in new positions around your window. I was able to combine the menu bar, navigation toolbar, and the URI field into a unified panel, and I placed a file tree on the right side of the window for convenience.
|
||||
|
||||
![QtFM unlocking the layout][5]
|
||||
|
||||
This requires no special knowledge of application design or even configuration. You just unlock, drag and drop, and lock.
|
||||
|
||||
### 3. Tabbed view
|
||||
|
||||
Many Linux file managers offer tabs the same way as most web browsers do. It's a simple interface trick that lets you keep several locations handy. I don't know whether it actually saves time, but I always feel like it does. QtFM offers tabs, too, and there are two things I particularly enjoy about the way it implements them.
|
||||
|
||||
First of all, the tabs are at the bottom of the window by default (you can change that in **Settings**.) Because I tend to read from left to right and top to bottom, I usually prefer to have "extra" information at the bottom and right ends of a window. Of course, what constitutes "extra" information varies from user to user, so I don't blame any developer for placing widgets and panels in places I wouldn't put widgets and panels. It's nice, though, when a developer accidentally agrees with my preferences.
|
||||
|
||||
Secondly, the tabs are responsive. You can drag a file or folder from one tab into another just by hovering over your target tab. It feels as natural as dragging and dropping from one window to another.
|
||||
|
||||
### Install QtFM
|
||||
|
||||
On Linux, your distribution may package QtFM in its software repository. If so, you can use your package manager to install. For example, on Debian and Debian-based systems:
|
||||
|
||||
```
|
||||
$ sudo apt install qtfm
|
||||
```
|
||||
|
||||
If your distribution doesn't offer QtFM, you may find a package for it on its [website][6], or you can download the source code from its [Git repository][7].
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/22/12/linux-file-manager-qtfm
|
||||
|
||||
作者:[Seth Kenlon][a]
|
||||
选题:[lkxed][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://opensource.com/users/seth
|
||||
[b]: https://github.com/lkxed
|
||||
[1]: https://opensource.com/article/22/10/obsolete-computer-linux-opportunity
|
||||
[2]: https://opensource.com/sites/default/files/2022-12/qtfm.webp
|
||||
[3]: https://opensource.com/article/20/4/webp-image-compression
|
||||
[4]: https://opensource.com/sites/default/files/2022-12/qtfm-custom-action.webp
|
||||
[5]: https://opensource.com/sites/default/files/2022-12/qtfm-layout-unlock.webp
|
||||
[6]: https://qtfm.eu/
|
||||
[7]: https://github.com/rodlie/qtfm/
|
@ -0,0 +1,90 @@
|
||||
[#]: subject: "3 delightful features of the Linux QtFM file manager"
|
||||
[#]: via: "https://opensource.com/article/22/12/linux-file-manager-qtfm"
|
||||
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
|
||||
[#]: collector: "lkxed"
|
||||
[#]: translator: "geekpi"
|
||||
[#]: reviewer: " "
|
||||
[#]: publisher: " "
|
||||
[#]: url: " "
|
||||
|
||||
# Linux QtFM 文件管理器的 3 个令人愉快的功能
|
||||
|
||||
QtFM 是一个简单的文件管理器,旨在通过快速直观的界面提供文件管理的基本功能。它适用于 Linux、BSD 和 macOS。
|
||||
|
||||
QtFM,顾名思义,使用 Qt(规范发音为 “cute”)编程工具包。我在 C++ 和 Python 中使用过 Qt 工具包,使用它总是一种乐趣。它是跨平台的,具有多个有用的抽象级别,因此开发人员不必直接与特定于供应商的 SDK 交互,而且它具有高度可配置性。从用户的角度来看,无论你使用的是最新的硬件还是[旧计算机][1],这都是一种“自然”且快速的体验。
|
||||
|
||||
### 使用 QtFM
|
||||
|
||||
QtFM 没有太多内容。它专注于实现其名称所声称的:Qt 的文件管理器 (FM)。布局可能是你对文件管理器的期望:左侧是常用位置和设备的列表,右侧是文件列表。
|
||||
|
||||
![QtFM file manager][2]
|
||||
|
||||
它只有四个菜单。
|
||||
|
||||
- **文件**:创建新文件或文件夹,打开新选项卡或窗口,或退出应用。
|
||||
- **编辑**:在左侧面板中复制、粘贴、移至垃圾箱或创建新书签。
|
||||
- **视图**:在列表视图和图标视图之间切换,调整布局。
|
||||
- **帮助**:许可信息和在线文档链接。
|
||||
|
||||
与 QtFM 交互与你可能习惯使用的任何标准文件管理器的体验大致相同。你可以点击导航、在其默认应用中打开文件、拖放文件和文件夹、复制和粘贴文件和文件夹、启动应用,以及你在与计算机内容交互时执行的任何其他操作。它很熟悉,所以基本上没有学习曲线,也没有不愉快的惊喜。
|
||||
|
||||
然而,也有一些惊喜。这是我最喜欢的三个。
|
||||
|
||||
### 1. 将命令放入上下文菜单
|
||||
|
||||
使用 QtFM,你可以将可以在终端中运行的任何命令添加到右键单击上下文菜单中。例如,假设你想要一个将图像转换为 [webp 格式][3]的选项到右键菜单。无需学习复杂的框架或脚本语言,无需开发插件。你只需 3 个步骤即可完成:
|
||||
|
||||
- 转到**编辑**菜单并选择**设置**。
|
||||
- 单击**自定义操作选项卡**。
|
||||
- 单击**添加**按钮并输入要运行的命令,对源文件使用 `%f`,对新文件使用 `%n`。
|
||||
|
||||
![QtFM custom actions][4]
|
||||
|
||||
该操作现在出现在你的 QtFM 上下文菜单中。
|
||||
|
||||
### 2. 灵活的布局
|
||||
|
||||
Qt 工具包的内置功能之一是它的许多组件(“小部件”)是可分离的。QtFM 利用了这一点,并允许你从**视图**菜单中解锁其布局。解锁后,你可以拖动工具栏和侧面板,将它们固定在窗口周围的新位置。我能够将菜单栏、导航工具栏和 URI 字段组合到一个统一的面板中,并且为了方便,我在窗口的右侧放置了一个文件树。
|
||||
|
||||
![QtFM unlocking the layout][5]
|
||||
|
||||
这不需要应用设计甚至配置的特殊知识。你只需解锁、拖放和锁定。
|
||||
|
||||
### 3. 标签视图
|
||||
|
||||
许多 Linux 文件管理器提供选项卡的方式与大多数 Web 浏览器相同。这是一个简单的界面技巧,可让你方便地保留多个位置。我不知道它是否真的节省了时间,但我总觉得它确实如此。QtFM 也提供选项卡,我特别喜欢它实现选项卡的方式有两点。
|
||||
|
||||
首先,选项卡默认位于窗口底部(你可以在**设置**中更改它)。因为我倾向于从左到右、从上到下阅读,所以我通常更喜欢在窗口的底部和右端设置“额外”信息。当然,“额外”信息的构成因用户而异,因此我不会责怪任何开发人员将小部件和面板放置在我不会放置小部件和面板的地方。不过,当开发人员不小心同意我的偏好时,这很好。
|
||||
|
||||
其次,标签是响应式的。只需将鼠标悬停在目标选项卡上,即可将文件或文件夹从一个选项卡拖动到另一个选项卡中。感觉就像从一个窗口拖放到另一个窗口一样自然。
|
||||
|
||||
### 安装 QtFM
|
||||
|
||||
在 Linux 上,你的发行版可能会将 QtFM 打包在它的软件仓库中。如果是这样,你可以使用包管理器进行安装。例如,在 Debian 和基于 Debian 的系统上:
|
||||
|
||||
```
|
||||
$ sudo apt install qtfm
|
||||
```
|
||||
|
||||
如果你的发行版不提供 QtFM,你可以在其[网站][6]上找到它的软件包,或者你可以从它的 [Git 仓库][7]下载源码。
|
||||
|
||||
---
|
||||
|
||||
via: https://opensource.com/article/22/12/linux-file-manager-qtfm
|
||||
|
||||
作者:[Seth Kenlon][a]
|
||||
选题:[lkxed][b]
|
||||
译者:[geekpi](https://github.com/geekpi)
|
||||
校对:[校对者 ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux 中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://opensource.com/users/seth
|
||||
[b]: https://github.com/lkxed
|
||||
[1]: https://opensource.com/article/22/10/obsolete-computer-linux-opportunity
|
||||
[2]: https://opensource.com/sites/default/files/2022-12/qtfm.webp
|
||||
[3]: https://opensource.com/article/20/4/webp-image-compression
|
||||
[4]: https://opensource.com/sites/default/files/2022-12/qtfm-custom-action.webp
|
||||
[5]: https://opensource.com/sites/default/files/2022-12/qtfm-layout-unlock.webp
|
||||
[6]: https://qtfm.eu/
|
||||
[7]: https://github.com/rodlie/qtfm/
|
Loading…
Reference in New Issue
Block a user