Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.ui.texteditor
Class TextViewerDeleteLineTarget


java.lang.Object
  extended by 
org.eclipse.ui.texteditor.TextViewerDeleteLineTarget

public class TextViewerDeleteLineTarget
extends Object

A delete line target.

Since:
3.4

Constructor Summary
TextViewerDeleteLineTarget ( ITextViewer viewer)
          Creates a new target.
 
Method Summary
 void deleteLine ( IDocument document, int offset, int length, int type, boolean copyToClipboard)
          Deletes the specified fraction of the line of the given offset.
 void deleteLine ( IDocument document, ITextSelection selection, int type, boolean copyToClipboard)
          Deletes the lines that intersect with the given selection.
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TextViewerDeleteLineTarget

public TextViewerDeleteLineTarget(
ITextViewer viewer)
Creates a new target.

Parameters:
viewer - the viewer that the new target operates on
Method Detail

deleteLine

public void deleteLine(
IDocument document,
                       int offset,
                       int length,
                       int type,
                       boolean copyToClipboard)
                throws 
BadLocationException
Deletes the specified fraction of the line of the given offset.

Parameters:
document - the document
offset - the offset
length - the length
type - the line deletion type, must be one of WHOLE_LINE, TO_BEGINNING or TO_END
copyToClipboard - true if the deleted line should be copied to the clipboard
Throws:
BadLocationException - if position is not valid in the given document

deleteLine

public void deleteLine(
IDocument document,
                       
ITextSelection selection,
                       int type,
                       boolean copyToClipboard)
                throws 
BadLocationException
Deletes the lines that intersect with the given selection.

Parameters:
document - the document
selection - the selection to use to determine the document range to delete
type - the line deletion type, must be one of WHOLE_LINE, TO_BEGINNING or TO_END
copyToClipboard - true if the deleted line should be copied to the clipboard
Throws:
BadLocationException - if position is not valid in the given document
Since:
3.5

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire