18
TEXT Editor BY: Sachin.R.I

Text editor

  • Upload
    sriashu

  • View
    583

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Text editor

TEXT Editor

BY: Sachin.R.I

Page 2: Text editor

An Interactive text editor has become an important part of almost any computing environment

Text editor acts as a primary interface to the computer for all type of “knowledge workers” as they compose, organize, study, and manipulate computer-based information.

A text editor allows you to edit a text file (create, modify etc…).

The common editing features associated with text editors are, Moving the cursor, Deleting, Replacing, Pasting, Searching, Searching and replacing, Saving and loading, and, Miscellaneous(e.g. quitting)

Page 3: Text editor

Windows OS - Notepad, WordPad, Microsoft Word, and text editors.

UNIX OS - vi, emacs, jed, pico. Gui based editors • Gedit gvim• Nedit• Tea• subtime

Page 4: Text editor

Overview of the editing process

Document-editing process involves- - Select the part of the target document to be viewed and

manipulated - Determine how to format this view on-line and how to

display it - Specify and execute operations that modify the target

document - Update the view appropriatelyO The above task involves traveling, filtering and formatting.

Editing phase involvesO – insert, delete, replace, move, copy, cut, paste, etc…O - Traveling – locate the area of interestO - Filtering - extracting the relevant subsetO - Formatting – visible representation on a display screen

Page 5: Text editor

User InterfaceO Conceptual model of the editing system

provides an easily understood abstraction of the target document and its elements.

O Line editors – simulated the world of the key punch – 80 characters, single line or an integral number of lines,

O Screen editors – Document is represented as a quarter-plane of text lines, unbounded both down and to the right.

O The user interface is concerned with, the input devices, the output devices and, the interaction language.

Page 6: Text editor

O Input Devices are divided into three categories, text devices, button devices and, locator devices.

O Text Devices are keyboard.O Button Devices are special function keys,

symbols on the screen.O Locator Devices are mouse, data tablet.O voice input devices which translates spoken

words to their textual equivalents.O Output Devices are Teletypewriters (first

output devices), Glass teletypes (Cathode ray tube (CRT) technology), Advanced CRT terminals, TFT Monitors

(Wysiwyg) and Printers (Hard-copy).

Page 7: Text editor

O The interaction language could be, typing oriented or text command oriented and menu-oriented user interface.

O Typing oriented or text command oriented interaction was with oldest editors, in the form of use of commands, use of function keys, control keys

etc.,O Menu-oriented user interface has menu

with a multiple choice set of text strings or icons. Display area for text is limited. Menus can be turned on or off.

Page 8: Text editor

Typical Editor Structure Diagram

Page 9: Text editor

Components of Editor Structure

OCommand language processor: It accepts input from the user’s input devices, and analyzes the tokens and syntactic structure of the commands.The command language functions much like the lexical and syntactic phases of a complier.In complier CLP may invoke semantic routines directly.

Page 10: Text editor

In a text editor, these semantic routines perform functions such as editing and viewing.

CLP may produce an intermediate representation of the desired editing operations.

This intermediate representation is then decoded by an interpreter that invokes the appropriate semantic routines.

The use of an intermediate representation allows the editor to provide the variety of user-interaction languages with a single set of semantic routine.

Page 11: Text editor

The routines involves travelling, editing, viewing and display functions.

OEditing operations are always specified explicitly by the user.

OThe Display operations are specified implicitly by the other three categories of operations.

OThe travelling and viewing operations may be invoked either explicitly by the user or implicitly by the editing operations

OThere is a relationship between this classes of operations and it is considerably more complicated than a simple model.

Page 12: Text editor

Simple relationship between editing and viewing buffers

Page 13: Text editor

OIn editing a document, the start of the area to be edited is determined by the editing component (which deals in editing task).

OThe current editing pointer can be set or reset explicitly by the user with traveling command such as…ONext paragraph ONext screen.

OOr implicitly by the system as a side effect such as delete paragraph.

Current editing pointer

Page 14: Text editor

OThe traveling component of the editor actually performs the setting of the current editing and the viewing pointers and determines the point at which the viewing or editing filtering begins.

OWhen the user issues an editing command the editing component invokes the editing filter.

OThis filter generates a new editing buffer based on the current editing pointer.

Page 15: Text editor

OThese parameters which are specified both by the user and the system, provide information such as the range of the text that can be affected by an operation.

--------------------End of CEP------------------

Page 16: Text editor

Current viewing pointer

OIn viewing a document, the start of the area to be viewed is determined by the current viewing pointer.

OThis pointer is maintained by the viewing component of the editor

OThe current viewing pointer can be set or reset explicitly by the user with a travelling command or explicitly by the system as a result of the previous editing operation .

OWhen the display needs to be updated, the viewing component invoked the viewing filter.

Page 17: Text editor

OThis component filters the document to generate the new viewing buffer based on the current viewing pointer as well as on the viewing filter parameters.

OThis parameters which is specified both by the user and system, provide information such as the number of characters needed to fill the display and how to select them from the document..

OThe editing and viewing buffers, while independent, can be related in many ways. In the simplest case..OThey are identical, the user edits the material

directly on the screen

Page 18: Text editor

Thank you…!!!

BY: Sachin.R.I