FACTOID # 41: On the probability of not reaching 40 graph, the top 34 countries are all African.
 
 Home   Encyclopedia   Statistics   Countries A-Z   Flags   Maps   Education   Forum   FAQ   About 
 
WHAT'S NEW
RECENT ARTICLES
More Recent Articles »
 

FACTS & STATISTICS    Simple view

  1. Select countries to view: (hold down Control key and click to select several)

     

     

    Compare:

     

     

  1. Select fact or statistic: (* = graphable)

     

     

     

  2. (OPTIONAL) Compare to statistic: (both need to be graphable)

     

     

     

  3. View result as:

     

       
(OR) SEARCH ALL encyclopedia, stats & forums:   

Encyclopedia > Code folding

Code folding is a feature of some text editors, program source code editors and IDEs that allows the user to selectively hide and display sections of a currently-edited file as a part of routine edit operations. This allows the user to manage large regions of potentially complicated text within one window, while still viewing only those subsections of the text that are specifically relevant during a particular editing session. Notepad is the standard text editor for Microsoft Windows A text editor is a piece of computer software for editing plain text. ... Notepad is the standard text editor for Microsoft Windows A text editor is a piece of computer software for editing plain text. ... An integrated development environment (IDE), also known as integrated design environment and integrated debugging environment, is a type of computer software that assists computer programmers to develop software. ...


This type of feature is customarily popular among developers who routinely manage a high volume and variety of source code files. Nonetheless, text editors that include this feature often provide enough flexibility to allow uses for purposes other than source code management. Consequently, the term 'Code Folding' is only one among various other common terms for this feature. Terms such as 'Outlining' 'Code Hiding' 'Expand and Collapse' (among others) are also common.

Contents


Conventions

In order to support code folding, the text editor must provide a mechanism for identifying 'folding points' within a text file. Some text editors provide this mechanism automatically, while others provide defaults that can either be overidden or augmented by the user.


Generally, folding points are specified with one or more of the following conventions:

  • token-based
  • indentation-based
  • syntax-dependent

Token-based folding points are generally specified using a special sequence of characters that serve no other purpose in the text than to identify the boundaries of folding points. This convention can be compared to indentation-based folding points, where printable characters are used instead of whitespace.


Indentation-based folding points are generally specified by the position and sequence of non-printing whitespace (such as tabs and spaces) within the text. This convention is particularly suitable to syntaxes and text files that require indentation as a rule by themselves.


Syntax-dependent folding points are those that rely on the specific source code or programming language of the currently-edited file in order to specify where specific folding regions should begin and end. Syntax-based folding points are typically defined around any or all of the standard sub-features of the markup language or programming language in use. A specialized markup language using SGML is used to write the electronic version of the Oxford English Dictionary. ... A programming language is an artificial language that can be used to control the behavior of a machine (often a computer). ...


Each of these conventions has its own distinct advantages and difficulties, and it is essentially up to the developer(s) who create the text editor software to decide which conventions to follow (if any).


Example: token-based code folding

The following document contains folding marks ({{{ ... }}}):

 Heading 1 {{{ Body }}} Heading 2 {{{ Body }}} Heading 3 {{{ Body }}} 

When loaded into a folding editor, the outline structure will be shown (just the headings):

 Heading 1 {{{ ... Heading 2 {{{ ... Heading 3 {{{ ... 

Usually clicking on the {{{ marks makes the appropriate body text appear.


Software with this feature

Recent versions of the open-source text editor Vim, Emacs, and the Java IDE Eclipse offer highly-configurable support for code folding. Sun's NetBeans IDE, Microsoft's Visual Studio.NET, the Code::Blocks IDE, the UltraEdit text editor, the Zeus IDE , the OS X editors Textmate and BBedit, the KDE text editor Kate, Macromedia Dreamweaver, the GNOME IDE Anjuta and the general source code editor Notepad++ offer code folding as well. Mandriva Linux is an example of open source. ... Notepad is the standard text editor for Microsoft Windows A text editor is a piece of computer software for editing plain text. ... Vim, which stands for Vi IMproved, is an open-source, multiplatform text editor extended from vi. ... This article is about the text editor. ... Java is an object-oriented programming language developed primarily by James Gosling and colleagues at Sun Microsystems. ... An integrated development environment (IDE), also known as integrated design environment and integrated debugging environment, is a type of computer software that assists computer programmers to develop software. ... Eclipse is an open source platform-independent software framework for delivering what the project calls rich-client applications, as opposed to thin client browser-based applications. ... Sun Microsystems, Inc. ... NetBeans refers to both a platform for the development of Java desktop applications, and an integrated development environment (IDE) developed using the NetBeans Platform. ... It has been suggested that Criticism of Microsoft be merged into this article or section. ... The Visual Studio . ... UltraEdit is a text editor created by IDM Computer Solutions. ... Zeus is a general-purpose, highly configurable, fully scriptable IDE specifically designed for Windows software developers. ... TextMate is a text editor for Mac OS X. It is primarily designed for programmers and web designers. ... BBEdit is a text editor originally developed for Macintosh System Software 6 and now for Mac OS X. It is made by Bare Bones Software. ... KDE (K Desktop Environment) is a free desktop environment and development platform built with Trolltechs Qt toolkit. ... In computing, Kate is a text editor for KDE. The acronym Kate stands for KDE advanced text editor. Kate has been part of the kdebase package since KDE release 2. ... Macromedia Dreamweaver is an HTML editor developed by Macromedia. ... The GNOME project is an international effort to create an easy-to-use computing platform built entirely from free software. ... Anjuta is an integrated development environment for C and C++ on GNU/Linux. ... Notepad++ is a free source code editor which supports several programming languages running under the Microsoft Windows environment. ...


See also


  Results from FactBites:
 
Vim documentation: usr_28 (2184 words)
Folding is used to show a range of lines in the buffer as a single line on the screen.
The advantage of folding is that you can get a better overview of the structure of text, by folding lines of a section and replacing it with a line that indicates that there is a section.
But you cannot manually define folds when 'foldmethod' is "indent", as that would conflict with the relation between the indent and the fold level.
Code folding - Wikipedia, the free encyclopedia (513 words)
Code folding is a feature of some text editors, program source code editors and IDEs that allows the user to selectively hide and display sections of a currently-edited file as a part of routine edit operations.
Token-based folding points are generally specified using a special sequence of characters that serve no other purpose in the text than to identify the boundaries of folding points.
Syntax-based folding points are typically defined around any or all of the standard sub-features of the markup language or programming language in use.
  More results at FactBites »


 

COMMENTARY     


Share your thoughts, questions and commentary here
Your name
Your comments
Please enter the 5-letter protection code

Want to know more?
Search encyclopedia, statistics and forums:

 


Lesson Plans | Student Area | Student FAQ | Reviews | Press Releases |  Feeds | Contact
The Wikipedia article included on this page is licensed under the GFDL.
Images may be subject to relevant owners' copyright.
All other elements are (c) copyright NationMaster.com 2003-5. All Rights Reserved.
Usage implies agreement with terms.