epoc32/include/medobsrv.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
parent 0 061f57f2323e
child 4 837f303aceeb
permissions -rw-r--r--
Final list of Symbian^2 public API header files
williamr@2
     1
// Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@2
     2
// All rights reserved.
williamr@2
     3
// This component and the accompanying materials are made available
williamr@2
     4
// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
williamr@2
     5
// which accompanies this distribution, and is available
williamr@2
     6
// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
williamr@2
     7
//
williamr@2
     8
// Initial Contributors:
williamr@2
     9
// Nokia Corporation - initial contribution.
williamr@2
    10
//
williamr@2
    11
// Contributors:
williamr@2
    12
//
williamr@2
    13
// Description:
williamr@2
    14
//
williamr@2
    15
williamr@2
    16
#ifndef __MEDOBSRV_H__
williamr@2
    17
#define __MEDOBSRV_H__
williamr@2
    18
williamr@2
    19
#include <e32def.h>
williamr@2
    20
williamr@2
    21
williamr@2
    22
williamr@2
    23
class MEditObserver
williamr@2
    24
/** 
williamr@2
    25
Specifies the mixin protocol for a rich text edit observer. 
williamr@2
    26
williamr@2
    27
This class is implemented by controls which use a rich text (CRichText) object, 
williamr@2
    28
when it is possible for the text object to be changed from outside of the 
williamr@2
    29
control without the control's knowledge.
williamr@2
    30
williamr@2
    31
An edit observer is a callback to the control from the CRichText object which 
williamr@2
    32
it has been set up to observe. The edit observer is set up using CRichText::SetEditObserver(). 
williamr@2
    33
@publishedAll
williamr@2
    34
@released
williamr@2
    35
*/
williamr@2
    36
	{
williamr@2
    37
public:
williamr@2
    38
	// Observer function called by CRichText to signal changes to the text
williamr@2
    39
	// buffer within it. A pointer to this function must be passed in to
williamr@2
    40
	// a CRichText instance by <rich text instance>.SetEditObserver(<ptr>).
williamr@2
    41
	// aStart is the start position of the edit and aExtent is the number
williamr@2
    42
	// of characters added or, if negative, deleted after this position.
williamr@2
    43
	
williamr@2
    44
	
williamr@2
    45
	/** Observer function called by the CRichText object when the object is edited 
williamr@2
    46
	to give notification of changes to its text buffer. In this way, the control 
williamr@2
    47
	knows how the text object has changed and can reformat and redraw the text 
williamr@2
    48
	object appropriately.
williamr@2
    49
	
williamr@2
    50
	A pointer to the observer object must have been passed in to a CRichText instance 
williamr@2
    51
	using CRichText::SetEditObserver().
williamr@2
    52
	
williamr@2
    53
	@param aStart The start position of the edit. 
williamr@2
    54
	@param aExtent The number of characters added or, if negative, deleted after 
williamr@2
    55
	this position. */
williamr@2
    56
	virtual void EditObserver(TInt aStart, TInt aExtent) = 0;
williamr@2
    57
	};
williamr@2
    58
williamr@2
    59
#endif