blob: 2c91b6b2976fb275a7d44aebc6b338ba714f5b11 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
/*******************************************************************************
* Copyright (c) 2000, 2003 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Common Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/cpl-v10.html
*
* Contributors:
* IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jface.text;
import org.eclipse.swt.custom.StyledTextContent;
/**
* Adapts an <code>IDocument</code> to the <code>StyledTextContent</code> interface.
* The document adapter is used by <code>TextViewer</code> to translate document changes
* into styled text content changes and vice versa.
* Clients may implement this interface and override <code>TextViewer.createDocumentAdapter</code>
* if they want to intercept the communication between the viewer's text widget and
* the viewer's document.
*
* @see IDocument
* @see StyledTextContent
*/
public interface IDocumentAdapter extends StyledTextContent {
/**
* Sets the adapters document.
*
* @param document the document to be adapted
*/
void setDocument(IDocument document);
}
|