Sponsored Content
Full Discussion: VI Editor
Special Forums UNIX and Linux Applications VI Editor Post 302212047 by Vi-Curious on Sunday 6th of July 2008 04:32:03 AM
Old 07-06-2008
This is a joke, right? Smilie

Ignoring how you find the line you want to delete, use dd instead of rm. What rm will do is replace (r) the letter under the cursor with the letter m.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Vi editor ?

Hello everybody, My question is: how to add /tmp/work at the end of line in vi editor. my file looks like: cp file1 cp file2 cp file3 **** I need to add " /tmp/work" at the end of each line. I tried this :%s/$/" /tmp/work" and this :%s/$/\ /tmp/work\/ but it does not work. (2 Replies)
Discussion started by: billy5
2 Replies

2. HP-UX

instead VI editor - which one?

I'd like to find some editor for HP-UX, something like notepad, but not VI editor. Can someone have some ideas which one? thx (6 Replies)
Discussion started by: diamond
6 Replies

3. UNIX for Advanced & Expert Users

vi editor

Hi, how can I add at the begining and at the end of all of the lines of my text file in VI editor ? Many thanks before. for exemple if in my file i have line 1 line 2 I want to have : start line 1 end start line 2 end (3 Replies)
Discussion started by: alain123456
3 Replies

4. HP-UX

vi editor

I am new in hp ux and I want work with vi editor, but in hp ux vi editor the backspaes and del keys doesn't work. how can I enable them. thanks (3 Replies)
Discussion started by: hkoolivand
3 Replies

5. UNIX for Dummies Questions & Answers

Pasting text in VI editor from a different editor

Hi, I knw its a silly question, but am a newbie to 'vi' editor. I'm forced to use this, hence kindly help me with this question. How can i paste a chunk 'copied from' a different editor(gedit) in 'vi editor'? As i see, p & P options does work only within 'vi'. (10 Replies)
Discussion started by: harishmitty
10 Replies

6. Shell Programming and Scripting

set EDITOR=vi -> default editor not setting for cron tab

Hi All, I am running a script , working very fine on cmd prompt. The problem is that when I open do crontab -e even after setting editor to vi by set EDITOR=vi it does not open a vi editor , rather it do as below..... ///////////////////////////////////////////////////// $ set... (6 Replies)
Discussion started by: aarora_98
6 Replies

7. Solaris

Epic Editor was not able to obtain a license for your use. Feature Epic Editor :Licen

Epic Editor was not able to obtain a license for your use. Feature Epic Editor :License server is down (1 Reply)
Discussion started by: durgaprasadr13
1 Replies

8. Shell Programming and Scripting

About vi editor

How can ` character be printed on vi editor ? empl_id=`echo $line | awk ' { print $1; } '` (2 Replies)
Discussion started by: senem
2 Replies

9. Shell Programming and Scripting

Not able to use @ in VI editor

Hello All, Need one Help for one issue. I am using a French Keyboard, so @ sign is on key 0 and i have to use right Alt + 0 to print it. It is working everywhere but not inside Vi editor. I can type @ in shell, in notepad. But inside Vi editor it is not working, another problem is that if... (2 Replies)
Discussion started by: yadavricky
2 Replies

10. Open Source

What editor does everyone use?

I was looking through the topics and I wasn't sure if this was the best place to post this question: I was wondering, out of curiosity, which software everyone was using to code their scripts in. I do mostly sh/ksh and my favorite has always been EditPlus because it is small, fast, yet powerful.... (409 Replies)
Discussion started by: yongho
409 Replies
Editor(3U)						    InterViews Reference Manual 						Editor(3U)

NAME
Editor - base class for top-level windows in an application SYNOPSIS
#include <Unidraw/editor.h> DESCRIPTION
An editor provides a complete user interface for editing a component subject. It unites one or more viewers with commands and tools that act upon the component and its subcomponents. Editor is an abstract class derived from MonoScene; the Editor class adds the protocol for associating tools, commands, and viewers with the component(s) they affect. A programmer normally derives one or more application-specific editors from the Editor base class and defines their appearance with a composition of interactors. Each window of a Unidraw application is usually an instance of an editor subclass designed for the editing domain, and it is these windows that the user recognizes as the applica- tion program. PUBLIC OPERATIONS
virtual ~Editor() Editors should not be deleted explicitly if the Unidraw object is used to open and close them. Moreover, Editor subclasses should not explicitly delete the component they edit. The Unidraw object will delete the editor's component after the editor is closed, provided no other editor references the component (or its relatives) and the component is not known to the catalog. virtual void Open() virtual void Close() Open informs the editor that it has just become visible and accessible to the user, in case it needs to know, and Close signals the editor that it is no longer needed and should perform any final housekeeping operations. For example, the editor may display a copyright message when it is first opened, or it make take the opportunity when closed to warn the user to save a modified compo- nent. These operations simply notify the editor of a condition and are not usually called by the application; instead, the applica- tion makes editors appear and disappear with the Unidraw object, which calls these operations as appropriate. virtual void Handle(Event&) Editor redefines Handle to interpret key events as keyboard equivalents via the HandleKey operation (described below). This is appropriate in the common case where the interactor composition that defines the editor's appearance does not interpret keyboard events. virtual void Update() By default, the editor's Update operation calls Update on its viewer(s). virtual void SetComponent(Component*) virtual void SetViewer(Viewer*, int = 0) virtual void SetSelection(Selection*) virtual void SetKeyMap(Viewer*, int = 0) virtual void SetCurTool(Tool*) virtual Component* GetComponent() virtual Viewer* GetViewer(int = 0) virtual KeyMap* GetKeyMap() virtual Selection* GetSelection() virtual Tool* GetCurTool() Assign and return various objects managed by the editor. These operations are undefined by default. The component is the object that the user edits through the editor. The editor can have any number of viewers, identified serially. An editor can maintain a key map for defining keyboard equivalents and a selection object for keeping track of selected components (typically subcomponents of the component being edited). The editor also has a notion of the tool that is currently engaged, that is, the tool that would be used if the user clicked in a viewer. The SetCurTool and GetCurTool operations assign and return this tool, respectively. virtual StateVar* GetState(const char*) The editor may maintain a string-to-state variable mapping to provide external access to any state variables it defines. The Get- State operation returns a state variable given an identifying string. Defining such a mapping lets components query the editor for state variables that may affect them without extending the editor protocol, potentially allowing interchange of components from dif- ferent applications. This operation returns nil by default. virtual void InsertDialog(Interactor*) virtual void RemoveDialog(Interactor*) Insert or remove an interactor that provides a modal interface, such as a dialog box. By default, these operations insert the dia- log into the world as a transient window centered atop the editor's canvas. Subclasses can redefine them to insert and remove an interactor (suitably embellished with a border, drop shadow, etc.) as needed. Subclasses should not assume that two InsertDialog operations will always be separated by a RemoveDialog operation; that is, multiple dialogs might be visible at once. PROTECTED OPERATIONS
Editor() You cannot create instances of the Editor class; rather, you define subclasses that suit your application. The constructor is thus protected to disallow instantiation. virtual void HandleKey(Event&) Executes a command given a valid keyboard event as defined by the key-to-command mapping in the KeyMap object. virtual boolean DependsOn(Component*) Return whether the editor depends on the given component in any way. Unidraw may destroy the component if no editor depends on it. void SetWindow(ManagedWindow*) ManagedWindow* GetWindow() Get and set the window associated with the editor. SEE ALSO
Catalog(3U), Command(3U), Component(3U), Interactor(3I), KeyMap(3U), MonoScene(3I), Selection(3U), StateVar(3U), Tool(3U), Unidraw(3U), Viewer(3U), Window(3I), World(3I) Unidraw 30 July 1990 Editor(3U)
All times are GMT -4. The time now is 08:51 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy