InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
ITextScrapData.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Michael Burbidge
6 //
7 // $Author$
8 //
9 // $DateTime$
10 //
11 // $Revision$
12 //
13 // $Change$
14 //
15 // Copyright 1997-2010 Adobe Systems Incorporated. All rights reserved.
16 //
17 // NOTICE: Adobe permits you to use, modify, and distribute this file in accordance
18 // with the terms of the Adobe license agreement accompanying it. If you have received
19 // this file from a source other than Adobe, then your use, modification, or
20 // distribution of it requires the prior written permission of Adobe.
21 //
22 //========================================================================================
23 
24 #ifndef __ITEXTSCRAPDATA__
25 #define __ITEXTSCRAPDATA__
26 
27 #include "IPMUnknown.h"
28 #include "TextID.h"
29 #include "ITextModel.h"
30 #include "K2SmartPtr.h"
31 
32 
33 //========================================================================================
34 // CLASS ITextScrapData
35 //========================================================================================
36 
40 class ITextScrapData : public IPMUnknown
41 {
42  public:
43  enum { kDefaultIID = IID_ITEXTSCRAPDATA };
44 
45  enum { kScrapType = 'PMTX' };
46 
47  virtual void Initialize(const UID& story, bool16 ignoreAttributes) = 0;
48 
50  virtual void Clear() = 0;
51 
53  virtual void Set(IDataBase *sourceDB, const boost::shared_ptr<PasteData>& vasd, bool16 ignoreAttributes) = 0;
54  virtual void Set(IDataBase *sourceDB, ITextModel *vasd, bool16 ignoreAttributes) = 0;
55 
57  virtual void Append(IDataBase *db, const boost::shared_ptr<PasteData>& vasd, bool16 ignoreAttributes) = 0;
58 
59  virtual UIDRef GetStoryRef() const = 0;
60  virtual void SetStoryRef(const UIDRef& storyRef) = 0;
61 
62  virtual RangeData GetRange() const = 0;
63  virtual void SetRange(const RangeData& r) = 0;
64 
65  virtual bool16 GetIgnoreAttributes() const = 0;
66  virtual uint32 GetLength() const = 0;
67  virtual bool16 IsEmpty() const = 0;
68 
69  virtual boost::shared_ptr<PasteData> GetDataFor(const UIDRef& intoStory) const = 0;
70  virtual bool16 NeedsExternalizing() const = 0;
71 };
72 
73 #endif