目录

Using Sessions

Reload All

书签

注释(注释嵌套)、等快捷键

技巧:将 Find窗口 1当成临时的剪切板来使用

删除空白行,删除行末空白

显示/自动限制代码的宽度

KDE文本编辑器使用方法 附加:https://blog.csdn.net/ken2232/article/details/129605167

删除与关闭的区别

已经安装的默认插件

Reload /Reload All /Auto Reload Document 的区别 (*)

Replace Checked

用后感:从编辑器的角度而言,kate 比 Qt Creator IDE中内置的编辑器好用。毕竟它们所关注的焦点是不一样的。

特别注意:kate 与其他编辑器(含内嵌在 IDE中的编辑器)同时使用时;kate 有多种防止冲突的机制,如果使用不当,将会造成源文件在修改上的混乱、或错乱。因此,

在切换到 kate后,在使用之前,一定要首先执行一次: “Reload All”。

当 kate作为辅助的编辑器,IDE中的作为主要编辑器时:"Auto Reload Document"

------------------------------------

Replace All 会出现的问题:在使用这个操作之前,最好要做备份。

void Abc::ttt_slot(){
    //qDebug()<<" RunTable::ttt_slot  对话框弹出";   ;}

“qDebug()<<" :直接Replace All 为 “//qDebug()<” ;由于函数的右侧 "}" 也被注释掉了,于是,产生错误。

=============================

Replace Checked

在 多文件 Find --> search之后,

检查搜索的结构,将不符合的结果排除,然后,再点击 “Replace Checked”。

特别注意:否则,将不应该被替换的字符串,也替换了。导致错误!

参考:Kate  一款功能丰富的文本编辑器(可能是目前最好的开源跨平台轻量编辑器 之一)

https://blog.csdn.net/ken2232/article/details/129605167

参考:

kate 跨平台KDE文本编辑器使用方法 汇集
kate 跨平台KDE文本编辑器使用方法 汇集_kate编辑器_ken2232的博客-CSDN博客

Kate 20.12 导出:官方默认的全部快捷键

http://t.csdn.cn/lKLpG

------------

Qt creator 最常用的快捷键 和书签功能 (**
https://blog.csdn.net/ken2232/article/details/130010588

官方默认:Qt Creator 所有的快捷键。及常用快捷键 (***)
https://blog.csdn.net/ken2232/article/details/131608520

Qt Creator常用快捷键及技巧提升编码效率
https://blog.csdn.net/luoyayun361/article/details/105431913

==============================================

The Kate Handbook

https://docs.kde.org/stable5/en/kate/kate/

Using Sessions (会话):这是一个方便的常用功能

https://docs.kde.org/stable5/en/kate/kate//fundamentals-using-sessions.html

使用要点

  1. 直接打开src目录下所有的所需文件;或者,以后再批量、或个别添加,也行。
  2. Sessions -- Manage Sessions -- 保存会话(或/会话另存为)-- -- // OK
  • 注意:在多种编辑器同时打开一个文件都在进行修改时,注意使用 “Reload All”功能。<< 不建议这样做(在多种编辑器同时打开一个文件都在进行修改,最好只有一个编辑器在修改,其他的为只读;但有时难以避免。),因为一不小心,就会导致修改恢复原样。
  • 直接执行 “新建会话”,似乎没有反应?或者是操作有问题的原因?// NG ?
  • Sessions 的保存目录:估计是 kate默认的,并不再用户的 src目录下?(没有/不必深究)

Sessions is how Kate lets you keep more than one list of files and GUI configuration around. You can have as many named sessions as you want, and you can use unnamed or anonymous sessions for files you want to use only once.

Currently Kate can save the list of open files, and the general window configuration in the session; future versions of Kate may add more features that can be saved in sessions.

With the introduction of sessions, Kate also allows you to open any number of instances of the application instead of just one as it used to do as the default behavior.

Sessions are supported in three areas:

  • Command line options that lets you select and start sessions when launching Kate from the command line.

  • The Sessions menu that lets you switch, save, start and manage your sessions.

  • Configuration options that lets you decide how sessions generally should behave.

When starting a new session, the GUI configuration of Default Session is loaded.

To save window configuration in the default session, you need to enable saving window configuration in the sessions configuration page of the configuration dialog and then load the default session, set up the window as desired and save the session again.

快捷键设置

Reload All: 这是一个常用的功能,为其设置快捷键。

按下 F2键,就可将 F2设置为其快捷键。

注意:如有快捷键冲突,会自动出现错误提示。

Auto Reload Document:

好像只能当次有效?重新打开 kate,不能保存这个选项?::>>

参考:Reload /Reload All /Auto Reload Document 的区别 (*)

下面的 2张图,"Auto Reload Document" 和 “Enable Auto Reload”是同一个功能,在不同菜单位置的展现。

功能:当 kate被激活为当前窗口时,会发生 “Auto Reload”操作。

kate作为辅助的编辑器IDE中的作为主要编辑器时:使用 "Auto Reload Document",似乎很好?

下图:只能启动 Auto Reload

下图,可以设置:启动/关闭 Auto Reload 功能

kate 打开的 “Reload All”

kate 打开多个文件时,在其他编辑器中修改,在 kate中提示 “Reload”的只是当前窗口的文件,因此,仍然需要执行 “Reload All”。

Reload /Reload All /Auto Reload Document 的区别 (*)

注意: 所谓的区别:目前只是估计,还没有经过验证??????

区别:

Reload:重装当前 项目文件。

Reload:重装当前 所有的项目文件。在同时打开几个项目的场景。

Auto Reload Document:只是设置 重装当前激活的文件。也就是说:只能一个一个文件,单独地来设置该功能。

特别注意:即使设置了“Auto Reload Document”,但是,“Reload” F2 的操作,还是必须的。

原因:没有被设置成“Auto Reload Document”,并且不是处在当前激活窗口的场景下,这些文件被外部编辑器更新之后,在 kate中不会自动提示文件的更新信息。

重装整个项目的操作:只能手动完成??

Save As 快捷键修改注意:

1. 需要与日常所用 IDE,或其他编辑软件的快捷键相一致;这样才方便自己使用。

2. 不同的 IDE,或编辑软件,其默认快捷键的定义是不一样的。

Qt creator 默认为:Save All >> Ctrl + Shift + S;

Notepad++ 默认为: Save All >> Ctrl + Shift + S;

VScode 默认为:Save As >> Ctrl + Shift + S;

书签

注意:

1. IDE中的编辑器,有些功能并不强大,有时需要使用更加强大的外部编辑器来辅助。

2. 内部编辑器和外部编辑器同时使用时。会导致一些私有数据异常。比如:书签的行号错乱,但这种错乱有些是可以接受的。

注释(注释嵌套)、等快捷键

注释:Ctrl + D:适用注释代码块中,已经 包含有注释符号“//”的场景。

Ctrl + /:适用注释代码块中,不 包含有注释符号“//”的场景。

连续不断取消,直到没有注释符号:Ctrl + / ,连续多次有效的按压 。

Ctrl +Shift +D:似乎效果 ? 等效于 Ctrl + / 。

/*...*/ 注释风格:选择的代码块,包含顶部一个空行:Ctrl + /

注释嵌套:

1. 先用 //注释:实现内层的注释。执行:Ctrl + / 或 Ctrl + D

2. 再用 /*...*/注释:实现外层的注释。必须是执行:Ctrl + D ( 注意:不能是执行:Ctrl + / )

关键操作:需要包含 代码块 顶部至少 1个空行。

技巧:将 Find窗口 1当成临时的剪切板来使用

运用于下面的 2个窗口中,简单方便。

==================================

显示/自动限制代码的宽度

以下是 Qt Creator IDE的功能:只能显示代码宽度

==================================

删除与关闭的区别

delect: 删除文件:

文件没有了。

x号:将由 sessions管理的文件,关闭掉

文件还存在;只是在 session中没有显示了。

如果要在 sessions中显示,则需要重新添加文件。

删除空白行,删除行末空白

https://www.lostsaloon.com/technology/how-to-remove-empty-lines-from-text-file-in-linux/

要点:

1. tools--切换到命令行(F7);

2. 运行命令:

rtrim 

rmblank

Kate Editor

Kate is another graphical editor. It is more or less the default text editor for KDE. You can of course delete the blank lines manually one after another as in any text editor, but Kate does provide some easy to use commands to let you do this.

Kate supports a Editor Component Command Line feature that you can access from View->Switch to Command Line in the menu bar or by using the shortcut F7.

rmblank: In the command line, type in the command rmblank to remove all empty lines in the current document. This will not however remove any lines with blanks or white spaces in them.

rtrim: This will trim the lines and get rid of any trailing spaces from the end of the lines. Doing a rtrim before rmblank will allow you to remove both the empty lines as well as the blank lines.

Many other advanced text editors such as UltraEdit support search and replace functionality using regular expressions. It is very likely that you can do this replacement using regex expressions as well in these editors.

Using command line utilities

Although using text editor is a good option, using a command line utility is faster and easier. It is also very useful if you many different files to process. There are several utilities in Linux that can be used to remove empty lines in text files. The most popular and commonly used ones are awk, sed, and grep.

awk

bash$ awk '/./' filename.txt > newfile.txt

awk is a very versatile command. The above command removes all the empty lines in a file and prints the result out to the standard output. You can redirect the output to a file to save the result as a new file. The above command will remove all the empty lines in a file named filename.txt and saves it to newfile.txt.

The above command will not remove lines that has white spaces in them such as spaces or other non-printable characters. If you want to remove both the empty lines as well as the lines with spaces, then try the following command.

bash$ awk NF filename.txt > newfile.txt

sed

sed is another popular utility for processing text. This follows a similar pattern to what was mentioned earlier in the vi editor section. The expressions used are very similar, mostly because as with most Linux commands it uses the regular expressions to match the input text.

bash$ sed '/^$/d' filename.txt > newfile.txt

The above command will remove empty lines but not the lines that may contain spaces or other non-printable characters. In order to remove the empty lines as well as the blank lines use the following sed command.

bash$ sed '/^\s*$/d' filename.txt > newfile.txt

The following command is actually just a negation of the first sed command. This will not remove (notice the !d) any lines that matches the regular expression, which matches all lines with any character in them.

bash$ sed '/./!d' filename.txt > newfile.txt

grep

grep is more of a matcher utility compared to the sed command mentioned earlier. Both will take similar regular expressions to match the empty and blank lines in a file. You will need to use the -v option with grep to negate the expression and print out the non-matching lines.

The example below will delete all the empty lines in text file filename.txt, but not the ones with whitespaces.

bash$ grep '.' filename.txt > newfile.txt

In order to remove empty lines and as well all the lines with just white spaces in them, use the following grep command.

bash$ grep -v '^\s*$' filename.txt > newfile.txt

All of the above utilities gets the job done pretty much the same way by using very similar expressions to match the empty or blank lines in the file. You can now extend these to remove any matching lines not just the empty lines.  For example, if you wish to remove all comments in a script file, you can use the following variation.

Assuming that the comments in the script file always occur in a single line by itself and starts  with a # (hash or pound), the following command will remove all of those lines.

bash$ sed '/^\s*#/d' filename.txt > newfile.txt

You may further modify the expression to suit your needs.

已经安装的默认插件(用户没有更改勾选项)

只要勾选,即可。

外部工具:需要用户安装

参考:

Qtcreator保存IDE上一次退出前的状态 Sessions (*)
https://blog.csdn.net/ken2232/article/details/130009144

qt creator : Managing Sessions (****) session sessions
https://blog.csdn.net/ken2232/article/details/130019802

kate 跨平台KDE文本编辑器使用方法 汇集: Using Sessions
https://blog.csdn.net/ken2232/article/details/130167973

kate 跨平台KDE文本编辑器使用方法 汇集
https://blog.csdn.net/ken2232/article/details/130167973

Kate  一款功能丰富的文本编辑器(可能是目前最好的开源跨平台轻量编辑器 之一)
https://blog.csdn.net/ken2232/article/details/129605167

kate 跨平台KDE文本编辑器使用方法 汇集相关推荐

  1. 服务器上txt文件编辑器,网站后台文本编辑器使用方法

    网站后台文本编辑器使用方法 Excel电子表格导入 利用Excel电子表格导入功能,您可以把已写好的Excel电子表格中指定的工作表一次性的导入编辑器中.Excel电子表格中的图片.图表等文件将自动上 ...

  2. ssh 使用 wangeditor3 富文本编辑器上传图片方法

    这段时间在搞一个小网站的项目,其中有个功能是可以网页上编辑文字和图片,能一起上传到数据库然后在页面上展现,当然还可以上传附件,不过我现在还没弄好,先把上传图片的功能记录一下. 说到这个wangedit ...

  3. ios开发 html编辑器,iOS实现富文本编辑器的方法详解

    前言 富文本编辑器不同于文本编辑器,国内做的比较好的比如有百度的UEditor和kindEditor.但是这两个也有它的缺点:界面过于复杂.不够简洁.UI设计也比较落后.不够轻量化,这篇文章我们将给大 ...

  4. Vue项目中使用 tinymce 富文本编辑器的方法,附完整源码

    来源 | https://blog.csdn.net/xingmeiok/article/deta 1.tinymce相关参考资料 tinymce版资料: http://tinymce.ax-z.cn ...

  5. 百度富文本编辑器使用方法 html,配置使用百度提供的富文本编辑器ueditor(以项目实例图文步骤演示具体配置步骤)...

    一.对比分析 下面来具体研究分析下百度提供的富文本编辑器,个人主要觉得对于代码语言嵌入及模拟word文本编辑相比于其他编辑器还是可以得,对于xwood里面涉及的代码嵌入使用的就是其功能,缺点在手机浏览 ...

  6. linux atom编辑器下载,Atom 1.7.0 发布下载,跨平台开源文本编辑器

    Atom 1.7.0 发布下载,作为目前全球范围内影响力最大的代码仓库/开源社区,GitHub 的程序员们并不满足于此.他们使用目前最先进流行的技术重新打造了一款称为"属于21世纪" ...

  7. nodejs 创建html文本编辑器,node使用UEditor富文本编辑器的方法实例

    大部分编辑器的后台是基于java.PHP.asp等,很少有基于node.js的.今天就做一个基于node的 最近在做一个微信素材编辑器的小项目,使用到了UEditor编辑器,使用中出现了许多问题. 1 ...

  8. 晨风机器人插件编辑器_晨风机器人文本编辑器使用方法

    软件功能:晨风QQ群机器人是一款操作简单,功能强大的QQ群聊天工具,通过晨风QQ群机器人,用户可以跟QQ群里的好友进行对话或收发图片.语音等,非常适合QQ营销人员使用.晨风qq群机器人实现与qq好友聊 ...

  9. Kate  一款功能丰富的文本编辑器(可能是目前最好的开源跨平台轻量编辑器 之一)

    参考:kate 跨平台KDE文本编辑器使用方法 汇集 https://blog.csdn.net/ken2232/article/details/130167973 有网络消息说:这款编辑器停止了更新 ...

最新文章

  1. 团队作业4——第一次项目冲刺(Alpha版本)4.28
  2. 利用套接字实现进程通信一例
  3. sql server 的 money类型
  4. Python学习笔记:常用内建模块4:hmac
  5. 【NLP】GitHub 上有哪些有趣的关于 NLP 的Python项目?
  6. RT-Thread pin设备驱动代码结构剖析
  7. 2135亿!2018 双11阿里数据库技术战报新鲜出炉
  8. java使用itext填充pdf模板,超简单教学,有手就行
  9. 应用 | Redis实现 主从,单例,集群,哨兵,配置应用
  10. JPA-save()方法会将字段更新为null的解决方法
  11. Flex4的可视化显示对象
  12. 笔记本风扇噪音太大,最简单操作风扇降噪
  13. SOUI实例之扫雷一
  14. Mysql 省市区字典(带层级,带经纬度,带拼音)
  15. 虚拟机安装win7出现错误
  16. Nodejs Blob流方式下载
  17. 微信小程序自定义yPicker组件分析及省市区三级联动实现
  18. Debian11安装MySql8
  19. 让数据填报、收集效率提升80%!这个报表工具真的太强大了
  20. PHP学习笔记:环境变量

热门文章

  1. 获得qq聊天窗口的句柄并使好友窗口获得焦点
  2. 将oracle端口1521共享_防火墙上开放Oracle服务端口1521的方法
  3. C语言系列——第九节-数据的存储(进阶)
  4. 自己编写字符串复制函数
  5. jupyter notebook 添加核 (jupyter:ModuleNotFoundError: No module named ‘torch‘) 亲测可用
  6. 计算机B的IP地址是,一个B类IP地址172.16.1.0,划分八个子网,计算分配各子网有效地址和最大计算机数...
  7. 每周一书-《做自己-鬼脚七自媒体第一季》
  8. qt repaint 用法_Qt重绘之update,repaint详解(转)
  9. react解析md文件
  10. 以太坊数据同步常见问题集锦