使用gEdit搭配terminal来写程序也有一段时间了,但一直当它是windows下的notepad,没有好好熟悉下它,今天无意中发现原来gEdit也可以打造一个不错的编程环境。这里对相关的资料收集总结了一下,与大家共享。
gEdit是GNOME桌面环境中默认的文本编辑器,它简单易用,对中文支持良好,支持多种字符编码,同时具有开放的插件支持特性。通过安装插件,作一些简单的设置,gEdit就可以做为一个简洁的编程环境。在我的ubuntu 8.04下,默认情况只安装了gedit包,还有以下几个插件:
代码:
Change case: Changes the case of selected text.
Document Statistics: Analyses the current document and reports the number of words, lines, characters and non-space characters in it.
External tools: Execute external commands and shell scripts. (More)
File Browser: A file browser plugin allowing to easily access your filesystem (includes remote mounts, creating new files/dirs, monitor dirs for changes, etc) (More)
Indent: Indents or un-indents selected lines.
Modelines: Emacs, Kate and Vim-style modelines support for gedit.
Python console: Interactive python console standing in the bottom panel.
Snippets: Insert often used pieces of text in a fast way. (More)
Sort: Sorts a document or selected text.
Spell: Checks the spelling of the current document.
Tag list: Provides a method to easily insert into a document commonly used tags/strings without having to type them.
Insert Date/Time: Inserts current date and time at the cursor position.
Document Statistics: Analyses the current document and reports the number of words, lines, characters and non-space characters in it.
External tools: Execute external commands and shell scripts. (More)
File Browser: A file browser plugin allowing to easily access your filesystem (includes remote mounts, creating new files/dirs, monitor dirs for changes, etc) (More)
Indent: Indents or un-indents selected lines.
Modelines: Emacs, Kate and Vim-style modelines support for gedit.
Python console: Interactive python console standing in the bottom panel.
Snippets: Insert often used pieces of text in a fast way. (More)
Sort: Sorts a document or selected text.
Spell: Checks the spelling of the current document.
Tag list: Provides a method to easily insert into a document commonly used tags/strings without having to type them.
Insert Date/Time: Inserts current date and time at the cursor position.
就编程而言,我觉得比较有用的有External tools(外部工具),通过它在菜单上集成shell命令来编译运行程序(由于不是交互性的shell,所以不便用于debug);File Browser(文件浏览器),提供一个多文件(工程)的视图,还有可以编辑远程文件,虽然后者我很少用到;Snippets(片断),提供一种代码模板以快速输入,如我在snippets->C++下定义了如下for循环:
代码:
for( $1 ; $2 ; ${3:++ix} )
{
$4
}
$0
{
$4
}
$0