英文:
Konsole removing leading whitespace when copy pasting?
问题
不知道是否改变了什么,或者因为更新的版本改变了行为,但每当我复制带有缩进的内容时,剪贴板中的结果文本会去除缩进(每一行的文本都从列0开始)。
这非常令人恼火,因为我经常复制/粘贴YaML和Docker Compose文件之类的内容,需要重新设置缩进。
找不到似乎与此相关的选项。有人有什么想法/建议吗?
我正在运行Manjaro 6.3,使用KDE Plasma 5.27。
英文:
I don't know if I changed something, or because a newer version changed behavior, but whenever I copy something that has indentation, the resulting text in my clipboard has its indentation removed (text on ever new line starts at column 0).
This is extremely annoying, as I regularly copy/paste from things like YaML and docker compose files and need to re-do the indentation.
Can't find an option that seems related to this. Anyone any ideas/tips?
I'm running Manjaro 6.3 with KDE Plasma 5.27
答案1
得分: 2
我一直被这个完全相同的问题困扰着,似乎是最近引入的一个问题。我在设置中四处点击,找到了解决办法。在顶部菜单栏中,依次选择:
设置
=> 编辑当前配置文件
=> 鼠标 - 确保选择了“文本交互”选项卡
=> 取消选中“修剪前导空格”
=> 确定
您的前导空格现在应该得到保留。
英文:
I've been annoyed by this exact same issue, this seems to be something that was introduced recently. I clicked around in the settings and found a solution. In the top menu bar, go to:
Settings
=> Edit Current Profile
=> Mouse - Ensure 'Text interaction' tab is selected
=> Uncheck 'Trim leading spaces'
=> OK
Your leading spaces should be preserved now.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论