简体   繁体   English

你是否区分了文本编辑器和IDE?

[英]Do you draw a distinction between text editors and IDEs?

I've seen several responses to questions asking for IDEs where text editors were suggested and vice-versa. 我已经看到几个问题的回答,要求提供文本编辑器的IDE,反之亦然。 That makes me think that people treat them as the same thing, where I draw clear distinctions. 这让我觉得人们把它们视为同一件事,在那里我画出明显的区别。

  1. How do you define "text editor" and "IDE"? 你如何定义“文本编辑器”和“IDE”?
  2. Do you see a difference between the two tools? 你看到这两种工具有什么区别吗?

Note that I accepted an answer which I think best addressed the concepts of "text editor" and "IDE". 请注意,我接受了一个答案,我认为最好解决“文本编辑器”和“IDE”的概念。 However, it's just my personal opinion of what best addresses the question and I will continue to check in on this question from time to time to see if there's a better answer and I will accept that one. 然而,这只是我个人对最佳解决问题的看法,我将不时继续检查这个问题,看看是否有更好的答案,我会接受这个问题。

The confusion arises from the fact that a text editor is a core component of every IDE. 混淆源于文本编辑器是每个IDE的核心组件。 But, an IDE has much more than just a text editor; 但是,IDE不仅仅是一个文本编辑器; it also has interfaces to compilers, debuggers, profilers, reference material, and more. 它还具有编译器,调试器,分析器,参考材料等的接口。

Many text editors have plugins or other flexible extension mechanisms, often including the ability to "wrap" external tools like those I mentioned above. 许多文本编辑器都有插件或其他灵活的扩展机制,通常包括“包装”外部工具的能力,就像我上面提到的那样。 The key difference, IMHO, is the "I" in IDE - integrated. 关键区别,恕我直言,是IDE中的“我” - 集成。 An IDE is (again, IMHO) something that's purposefully designed to support a specific set of tools, one of which is a text editor. IDE(再次,恕我直言)是专门设计用于支持一组特定工具的东西,其中一个是文本编辑器。

I do, but it's more in the way you use them than a difference in the software itself. 我这样做,但它更像你使用它们的方式而不是软件本身的差异。 Some software is used as an IDE by some, but a mere text editor by others. 某些软件被某些人用作IDE,但仅由其他人用作文本编辑器。 Some software can only be a text editor, some is difficult to use as only a text editor, and some can be easily used as both. 有些软件只能是文本编辑器,有些软件只能用作文本​​编辑器,有些软件可以很容易地用作文本编辑器。

I would say that such stalwarts as Vi(m) and Emacs are used by some as text editors and some as IDEs. 我会说像Vi(m)和Emacs这样的忠实用户被一些人用作文本编辑器而一些用作IDE。 Things like eclipse, visual studio, etc only really make sense as IDEs and things like notepad can hardly be anything but a text editor. 像eclipse,visual studio等这样的东西才真正有意义,因为IDE和记事本之类的东西几乎不是文本编辑器。

I would say if you stay in your text editor to do other things - compile, debug, etc - then you're using it more like an IDE. 我会说,如果你留在你的文本编辑器中做其他事情 - 编译,调试等 - 那么你就像IDE一样使用它。 Quite where I'd draw the line, I'm not sure. 我在哪里画线,我不确定。

The obvious difference is the "I" from the IDE. 明显的区别是来自IDE的“我”。 IDE's are an integrated platform that allows not only editing, but debugging, file management for your project, and usually cool features like syntax highlighting and code completion. IDE是一个集成平台,不仅可以编辑,还可以调试项目的文件管理,通常还有很酷的功能,如语法高亮和代码完成。 oh yeah, and integration of tools and compilers, as well as source control. 哦,是的,工具和编译器的集成,以及源代码控制。

I use both and I suggest you do too. 我使用两者,我建议你也这样做。 Sometimes an IDE can make development faster - like code completion and refactoring support. 有时,IDE可以使开发更快 - 例如代码完成和重构支持。 Fast find of files and symbols, functions, classes in project not to mention project management features. 快速查找项目中的文件和符号,函数,类,更不用说项目管理功能。 Sometimes they'll manage the build for you. 有时候他们会为你管理构建。 Maybe it has a built in debugger (a good built in debugger is worth gold). 也许它有一个内置的调试器(一个好的内置调试器值得金)。 How about code snippets and file templates. 代码片段和文件模板怎么样? Sometimes an IDE will help you build GUI interfaces and data stores. 有时IDE会帮助您构建GUI界面和数据存储。 I've seen ones that help you build regexps and run SQL queries. 我见过那些可以帮助你构建regexp并运行SQL查询的方法。

These (IMO) are all sugar. 这些(IMO)都是糖。 I also use a plain text editor (although I really appreciate code syntax coloring nowadays) and roll most of that other stuff myself. 我也使用纯文本编辑器(虽然我现在非常欣赏代码语法着色)并自己滚动大部分其他内容。 Some of the newer text editors are creeping into IDE territory (eg TextMate) since they are extensible enough to allow for most of the above paragraphs niceties. 一些较新的文本编辑器正在进入IDE领域(例如TextMate),因为它们具有足够的可扩展性以允许上述大多数段落的细节。

In 90% of the cases I use what I am given or what the majority of the teams uses (I am a contractor). 在90%的案例中,我使用的是我所使用的或大多数团队使用的(我是承包商)。 This reduces the build conflicts that can arise if you decide to go it on your own. 这可以减少您决定独立完成时可能出现的构建冲突。 By learning to use IDE's, text editors and everything in between you will stay flexible and able to cope with whatever is thrown at you. 通过学习使用IDE,文本编辑器以及介于两者之间的所有内容,您将保持灵活性并能够应对任何被抛出的内容。

To me, a text editor is light weight tool used to edit text based documents. 对我来说,文本编辑器是用于编辑基于文本的文档的轻量级工具。 There is no mark up or formatting of the text other than defining the "system" font for the editor. 除了为编辑器定义“系统”字体外,没有标记或格式化文本。 Useful tools can still be part of a text editor, like a folder tree, syntax highlighting, even cmd line execution of compilers. 有用的工具仍然可以是文本编辑器的一部分,如文件夹树,语法高亮,甚至编译器的cmd行执行。 In the end though, all it does it allow you edit the text in a document. 最后,它只允许您编辑文档中的文本。 It will not display it to you in a different way. 它不会以不同的方式显示给您。 ie: it will not show you a grid when viewing an XML document 即:查看XML文档时不会显示网格

An IDE is much more robust and is generally specific to a language or framework. IDE更加健壮,通常特定于语言或框架。

you know, before i started writing this answer, i had a clear line between a text editor and an IDE. 你知道,在我开始写这个答案之前,我在文本编辑器和IDE之间有一条清晰的界限。 But now, i'm thinking they are one in the same. 但现在,我认为他们是同一个人。 I mean really and IDE like VS is just a glorified text editor. 我的意思是真的,像VS这样的IDE只是一个美化的文本编辑器。 And a text editor like Textpad is an IDE with a much smaller budget for development of features. 像Textpad这样的文本编辑器是一个IDE,其开发功能的预算要少得多。

I guess the real answer is, an IDE is backed by a large company or group expanding it's features in many different directions. 我想真正的答案是,IDE由大型公司或集团支持,在许多不同方向扩展其功能。 But a text editor is built by a small group of people, with just enough features to get by. 但是文本编辑器是由一小群人构建的,只有足够的功能可以使用。

如果你看看Kate ,文本编辑器和Kdevelop ,IDE的主要区别在于Kdevelop支持项目管理(CVS / Subversion)和构建脚本,而Kate则不支持。

Personally where I think the 'line' is drawn between IDE's and Text Editors is knowledge of the end program, rather than just knowledge of it's source code. 就个人而言,我认为在IDE和文本编辑器之间绘制'线'是对最终程序的了解,而不仅仅是对它的源代码的了解。

As examples: 例如:

  • Can it compile your code into a binary? 它可以将您的代码编译成二进制文件吗? It's an IDE 这是一个IDE
  • Does it have an integrated debugger? 它是否有集成的调试器? It's an IDE 这是一个IDE
    • In order to have an integrated debugger it needs to know about either the binary compiled program, or in the case of scripting languages, the in-memory interpretation of the program as it runs. 为了拥有一个集成的调试器,它需要知道二进制编译的程序,或者在脚本语言的情况下,需要知道程序在运行时的内存中解释。

Note: Things like intellisense don't rely on your code being compiled into anything, so I wouldn't say that intellisense implies IDE 注意:像intellisense这样的东西不依赖于你的代码被编译成任何东西,所以我不会说intellisense意味着IDE

Note 2: Many text editors like textmate have plugin systems which can be extended to build your project. 注2:像textmate这样的许多文本编辑都有插件系统,可以扩展它们来构建你的项目。 This does not make them an IDE, as they are simply shelling out to a plugin, they don't have any knowledge about the building itself. 这不会使它们成为IDE,因为它们只是对插件进行外壳攻击,它们对构建本身没有任何了解。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM