Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Side by Side Diff: core/include/fpdfapi/fpdf_serial.h

Issue 1398383002: core/ difference with XFA (for information only). (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: After bidi Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | core/include/fpdfdoc/fpdf_doc.h » ('j') | core/include/fxcodec/fx_codec.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #ifndef CORE_INCLUDE_FPDFAPI_FPDF_SERIAL_H_ 7 #ifndef CORE_INCLUDE_FPDFAPI_FPDF_SERIAL_H_
8 #define CORE_INCLUDE_FPDFAPI_FPDF_SERIAL_H_ 8 #define CORE_INCLUDE_FPDFAPI_FPDF_SERIAL_H_
9 9
10 #include "fpdf_page.h" 10 #include "fpdf_page.h"
11 #include "fpdf_pageobj.h" 11 #include "fpdf_pageobj.h"
12 12
13 class CPDF_ObjectStream; 13 class CPDF_ObjectStream;
14 class CPDF_XRefStream; 14 class CPDF_XRefStream;
15 CFX_ByteTextBuf& operator<<(CFX_ByteTextBuf& buf, const CPDF_Object* pObj); 15 CFX_ByteTextBuf& operator<<(CFX_ByteTextBuf& buf, const CPDF_Object* pObj);
16 #ifdef PDF_ENABLE_XFA
17 class CPDF_ObjArchiveSaver : public CFX_ArchiveSaver {
18 public:
19 friend CPDF_ObjArchiveSaver& operator<<(CPDF_ObjArchiveSaver& ar,
20 const CPDF_Object* pObj);
21
22 protected:
23 CFX_MapPtrToPtr m_ObjectMap;
24 };
25 class CPDF_ObjArchiveLoader : public CFX_ArchiveLoader {
26 public:
27 CPDF_ObjArchiveLoader(const uint8_t* pData, FX_DWORD dwSize)
28 : CFX_ArchiveLoader(pData, dwSize), m_IndirectObjects(NULL) {}
29
30 friend CPDF_ObjArchiveLoader& operator>>(CPDF_ObjArchiveLoader& ar,
31 CPDF_Object*& pObj);
32
33 protected:
34 CPDF_IndirectObjects m_IndirectObjects;
35 };
36 class CPDF_PageArchiveSaver : public CPDF_ObjArchiveSaver {
37 public:
38 CPDF_PageArchiveSaver(CPDF_PageObjects* pPageObjs);
39
40 friend CPDF_PageArchiveSaver& operator<<(CPDF_PageArchiveSaver& ar,
41 CPDF_PageObject* pObj);
42
43 friend CPDF_PageArchiveSaver& operator<<(CPDF_PageArchiveSaver& ar,
44 CPDF_ClipPath clip_path);
45
46 friend CPDF_PageArchiveSaver& operator<<(CPDF_PageArchiveSaver& ar,
47 CPDF_GraphState graph_state);
48
49 friend CPDF_PageArchiveSaver& operator<<(CPDF_PageArchiveSaver& ar,
50 CPDF_TextState text_state);
51
52 friend CPDF_PageArchiveSaver& operator<<(CPDF_PageArchiveSaver& ar,
53 CPDF_ColorState color_state);
54
55 friend CPDF_PageArchiveSaver& operator<<(CPDF_PageArchiveSaver& ar,
56 CPDF_GeneralState general_state);
57
58 protected:
59 CPDF_ClipPath m_LastClipPath;
60
61 CPDF_GraphState m_LastGraphState;
62
63 CPDF_ColorState m_LastColorState;
64
65 CPDF_TextState m_LastTextState;
66
67 CPDF_GeneralState m_LastGeneralState;
68 };
69 class CPDF_PageArchiveLoader : public CPDF_ObjArchiveLoader {
70 public:
71 CPDF_PageArchiveLoader(CPDF_PageObjects* pPageObjs,
72 const uint8_t* pData,
73 FX_DWORD dwSize);
74
75 friend CPDF_PageArchiveLoader& operator>>(CPDF_PageArchiveLoader& ar,
76 CPDF_PageObject*& pObj);
77
78 friend CPDF_PageArchiveLoader& operator>>(CPDF_PageArchiveLoader& ar,
79 CPDF_ClipPath& clip_path);
80
81 friend CPDF_PageArchiveLoader& operator>>(CPDF_PageArchiveLoader& ar,
82 CPDF_GraphState& graph_state);
83
84 friend CPDF_PageArchiveLoader& operator>>(CPDF_PageArchiveLoader& ar,
85 CPDF_TextState& text_state);
86
87 friend CPDF_PageArchiveLoader& operator>>(CPDF_PageArchiveLoader& ar,
88 CPDF_ColorState& color_state);
89
90 friend CPDF_PageArchiveLoader& operator>>(CPDF_PageArchiveLoader& ar,
91 CPDF_GeneralState& general_state);
92
93 protected:
94 void PostProcColor(CPDF_Color& color);
95
96 CPDF_Object* AddResource(CPDF_Object* pSrcObj, const FX_CHAR* type);
97
98 CPDF_ClipPath m_LastClipPath;
99
100 CPDF_GraphState m_LastGraphState;
101
102 CPDF_ColorState m_LastColorState;
103
104 CPDF_TextState m_LastTextState;
105
106 CPDF_GeneralState m_LastGeneralState;
107
108 CFX_MapPtrToPtr m_ObjectMap;
109 };
110 #endif
16 #define FPDFCREATE_INCREMENTAL 1 111 #define FPDFCREATE_INCREMENTAL 1
17 #define FPDFCREATE_NO_ORIGINAL 2 112 #define FPDFCREATE_NO_ORIGINAL 2
18 #define FPDFCREATE_PROGRESSIVE 4 113 #define FPDFCREATE_PROGRESSIVE 4
19 #define FPDFCREATE_OBJECTSTREAM 8 114 #define FPDFCREATE_OBJECTSTREAM 8
20 115
21 class CPDF_Creator { 116 class CPDF_Creator {
22 public: 117 public:
23 CPDF_Creator(CPDF_Document* pDoc); 118 CPDF_Creator(CPDF_Document* pDoc);
24 ~CPDF_Creator(); 119 ~CPDF_Creator();
25 120
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 CFX_DWordArray m_NewObjNumArray; 193 CFX_DWordArray m_NewObjNumArray;
99 194
100 CPDF_Array* m_pIDArray; 195 CPDF_Array* m_pIDArray;
101 196
102 int32_t m_FileVersion; 197 int32_t m_FileVersion;
103 friend class CPDF_ObjectStream; 198 friend class CPDF_ObjectStream;
104 friend class CPDF_XRefStream; 199 friend class CPDF_XRefStream;
105 }; 200 };
106 201
107 #endif // CORE_INCLUDE_FPDFAPI_FPDF_SERIAL_H_ 202 #endif // CORE_INCLUDE_FPDFAPI_FPDF_SERIAL_H_
OLDNEW
« no previous file with comments | « no previous file | core/include/fpdfdoc/fpdf_doc.h » ('j') | core/include/fxcodec/fx_codec.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698