Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
fpdf_editpage_embeddertest.cpp
Go to the documentation of this file.
1// Copyright 2018 The PDFium Authors
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "core/fxcrt/fx_system.h"
6#include "core/fxge/cfx_defaultrenderdevice.h"
7#include "public/fpdf_edit.h"
8#include "testing/embedder_test.h"
9#include "testing/embedder_test_constants.h"
10
12
14 const char* rotated_checksum = []() {
15 if (CFX_DefaultRenderDevice::UseSkiaRenderer()) {
16 return "eded83f75f3d0332c584c416c571c0df";
17 }
18 return "d599429574ff0dcad3bc898ea8b874ca";
19 }();
20
21 {
22 ASSERT_TRUE(OpenDocument("rectangles.pdf"));
23 FPDF_PAGE page = LoadPage(0);
24 ASSERT_TRUE(page);
25
26 {
27 // Render the page as is.
28 EXPECT_EQ(0, FPDFPage_GetRotation(page));
29 const int page_width = static_cast<int>(FPDF_GetPageWidth(page));
30 const int page_height = static_cast<int>(FPDF_GetPageHeight(page));
31 EXPECT_EQ(200, page_width);
32 EXPECT_EQ(300, page_height);
33 ScopedFPDFBitmap bitmap = RenderLoadedPage(page);
34 CompareBitmap(bitmap.get(), page_width, page_height,
36 }
37
39
40 {
41 // Render the page after rotation.
42 // Note that the change affects the rendering, as expected.
43 // It behaves just like the case below, rather than the case above.
44 EXPECT_EQ(1, FPDFPage_GetRotation(page));
45 const int page_width = static_cast<int>(FPDF_GetPageWidth(page));
46 const int page_height = static_cast<int>(FPDF_GetPageHeight(page));
47 EXPECT_EQ(300, page_width);
48 EXPECT_EQ(200, page_height);
49 ScopedFPDFBitmap bitmap = RenderLoadedPage(page);
50 CompareBitmap(bitmap.get(), page_width, page_height, rotated_checksum);
51 }
52
53 UnloadPage(page);
54 }
55
56 {
57 // Save a copy, open the copy, and render it.
58 // Note that it renders the rotation.
59 EXPECT_TRUE(FPDF_SaveAsCopy(document(), this, 0));
60 ASSERT_TRUE(OpenSavedDocument());
61 FPDF_PAGE saved_page = LoadSavedPage(0);
62 ASSERT_TRUE(saved_page);
63
64 EXPECT_EQ(1, FPDFPage_GetRotation(saved_page));
65 const int page_width = static_cast<int>(FPDF_GetPageWidth(saved_page));
66 const int page_height = static_cast<int>(FPDF_GetPageHeight(saved_page));
67 EXPECT_EQ(300, page_width);
68 EXPECT_EQ(200, page_height);
69 ScopedFPDFBitmap bitmap = RenderSavedPage(saved_page);
70 CompareBitmap(bitmap.get(), page_width, page_height, rotated_checksum);
71
72 CloseSavedPage(saved_page);
73 CloseSavedDocument();
74 }
75}
76
78 constexpr int kExpectedObjectCount = 39;
79 ASSERT_TRUE(OpenDocument("embedded_images.pdf"));
80 FPDF_PAGE page = LoadPage(0);
81 ASSERT_TRUE(page);
82 ASSERT_EQ(kExpectedObjectCount, FPDFPage_CountObjects(page));
83
84 for (int i = 0; i < kExpectedObjectCount; ++i) {
85 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, i);
86 EXPECT_FALSE(FPDFPageObj_HasTransparency(obj));
87
88 FPDFPageObj_SetFillColor(obj, 255, 0, 0, 127);
89 EXPECT_TRUE(FPDFPageObj_HasTransparency(obj));
90 }
91
92 UnloadPage(page);
93}
94
98
100 constexpr int kExpectedObjectCount = 8;
101 ASSERT_TRUE(OpenDocument("rectangles.pdf"));
102 FPDF_PAGE page = LoadPage(0);
103 ASSERT_TRUE(page);
104 ASSERT_EQ(kExpectedObjectCount, FPDFPage_CountObjects(page));
105
106 for (int i = 0; i < kExpectedObjectCount; ++i) {
107 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, i);
108 EXPECT_FALSE(FPDFPageObj_HasTransparency(obj));
109
111 EXPECT_TRUE(FPDFPageObj_HasTransparency(obj));
112 }
113
114 UnloadPage(page);
115}
116
118 constexpr int kExpectedObjectCount = 2;
119 ASSERT_TRUE(OpenDocument("text_render_mode.pdf"));
120 FPDF_PAGE page = LoadPage(0);
121 ASSERT_TRUE(page);
122 ASSERT_EQ(kExpectedObjectCount, FPDFPage_CountObjects(page));
123
124 for (int i = 0; i < kExpectedObjectCount; ++i) {
125 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, i);
126 EXPECT_FALSE(FPDFPageObj_HasTransparency(obj));
127
128 FPDFPageObj_SetBlendMode(obj, "Lighten");
129 EXPECT_TRUE(FPDFPageObj_HasTransparency(obj));
130 }
131
132 UnloadPage(page);
133}
134
136 constexpr int kExpectedObjectCount = 39;
137 constexpr int kImageObjectsStartIndex = 33;
138 ASSERT_TRUE(OpenDocument("embedded_images.pdf"));
139 FPDF_PAGE page = LoadPage(0);
140 ASSERT_TRUE(page);
141
142 ASSERT_EQ(kExpectedObjectCount, FPDFPage_CountObjects(page));
143
144 for (int i = kImageObjectsStartIndex; i < kExpectedObjectCount; ++i) {
145 FPDF_PAGEOBJECT image = FPDFPage_GetObject(page, i);
146 ASSERT_TRUE(image);
148
149 unsigned int r;
150 unsigned int g;
151 unsigned int b;
152 unsigned int a;
153 EXPECT_FALSE(FPDFPageObj_GetFillColor(image, &r, &g, &b, &a));
154 EXPECT_FALSE(FPDFPageObj_GetStrokeColor(image, &r, &g, &b, &a));
155 }
156
157 UnloadPage(page);
158}
159
161 {
162 EXPECT_FALSE(FPDFPageObj_GetDashPhase(nullptr, nullptr));
163
164 float phase = -1123.5f;
165 EXPECT_FALSE(FPDFPageObj_GetDashPhase(nullptr, &phase));
166 EXPECT_FLOAT_EQ(-1123.5f, phase);
167
168 EXPECT_EQ(-1, FPDFPageObj_GetDashCount(nullptr));
169
170 EXPECT_FALSE(FPDFPageObj_GetDashArray(nullptr, nullptr, 3));
171
172 float get_array[] = {-1.0f, -1.0f, -1.0f};
173 EXPECT_FALSE(FPDFPageObj_GetDashArray(nullptr, get_array, 3));
174 for (int i = 0; i < 3; i++)
175 EXPECT_FLOAT_EQ(-1.0f, get_array[i]);
176
177 EXPECT_FALSE(FPDFPageObj_SetDashPhase(nullptr, 5.0f));
178 EXPECT_FALSE(FPDFPageObj_SetDashArray(nullptr, nullptr, 3, 5.0f));
179
180 float set_array[] = {1.0f, 2.0f, 3.0f};
181 EXPECT_FALSE(FPDFPageObj_SetDashArray(nullptr, set_array, 3, 5.0f));
182 }
183
184 constexpr int kExpectedObjectCount = 3;
185 ASSERT_TRUE(OpenDocument("dashed_lines.pdf"));
186 FPDF_PAGE page = LoadPage(0);
187 ASSERT_TRUE(page);
188
189 ASSERT_EQ(kExpectedObjectCount, FPDFPage_CountObjects(page));
190
191 {
192 FPDF_PAGEOBJECT path = FPDFPage_GetObject(page, 0);
193 ASSERT_TRUE(path);
195
196 EXPECT_FALSE(FPDFPageObj_GetDashPhase(path, nullptr));
197 EXPECT_FALSE(FPDFPageObj_GetDashArray(path, nullptr, 3));
198 EXPECT_FALSE(FPDFPageObj_SetDashArray(path, nullptr, 3, 5.0f));
199
200 float phase = -1123.5f;
201 EXPECT_TRUE(FPDFPageObj_GetDashPhase(path, &phase));
202 EXPECT_FLOAT_EQ(0.0f, phase);
203 EXPECT_EQ(0, FPDFPageObj_GetDashCount(path));
204
205 float get_array[] = {-1.0f, -1.0f, -1.0f};
206 EXPECT_TRUE(FPDFPageObj_GetDashArray(path, get_array, 3));
207 for (int i = 0; i < 3; i++)
208 EXPECT_FLOAT_EQ(-1.0f, get_array[i]);
209 }
210
211 {
212 FPDF_PAGEOBJECT path = FPDFPage_GetObject(page, 1);
213 ASSERT_TRUE(path);
215
216 float phase = -1123.5f;
217 EXPECT_TRUE(FPDFPageObj_GetDashPhase(path, &phase));
218 EXPECT_LT(0.0f, phase);
219 ASSERT_EQ(6, FPDFPageObj_GetDashCount(path));
220
221 float dash_array[] = {-1.0f, -1.0f, -1.0f, -1.0f, -1.0f, -1.0f};
222 ASSERT_TRUE(FPDFPageObj_GetDashArray(path, dash_array, 6));
223
224 for (int i = 0; i < 6; i++)
225 EXPECT_LT(0.0f, dash_array[i]);
226
227 // the array is decreasing in value.
228 for (int i = 0; i < 5; i++)
229 EXPECT_GT(dash_array[i], dash_array[i + 1]);
230
231 // modify phase
232 EXPECT_TRUE(FPDFPageObj_SetDashPhase(path, 1.0f));
233
234 phase = -1123.5f;
235 EXPECT_TRUE(FPDFPageObj_GetDashPhase(path, &phase));
236 EXPECT_FLOAT_EQ(1.0f, phase);
237
238 // clear array
239 EXPECT_TRUE(FPDFPageObj_SetDashArray(path, nullptr, 0, 0.0f));
240 EXPECT_EQ(0, FPDFPageObj_GetDashCount(path));
241
242 phase = -1123.5f;
243 EXPECT_TRUE(FPDFPageObj_GetDashPhase(path, &phase));
244 EXPECT_FLOAT_EQ(0.0f, phase);
245 }
246
247 {
248 FPDF_PAGEOBJECT path = FPDFPage_GetObject(page, 2);
249 ASSERT_TRUE(path);
251
252 float phase = -1123.5f;
253 EXPECT_TRUE(FPDFPageObj_GetDashPhase(path, &phase));
254 EXPECT_FLOAT_EQ(0.0f, phase);
255
256 EXPECT_EQ(0, FPDFPageObj_GetDashCount(path));
257
258 // `get_array` should be unmodified
259 float get_array[] = {-1.0f, -1.0f, -1.0f, -1.0f};
260 EXPECT_TRUE(FPDFPageObj_GetDashArray(path, get_array, 4));
261 for (int i = 0; i < 4; i++)
262 EXPECT_FLOAT_EQ(-1.0f, get_array[i]);
263
264 // modify dash_array and phase
265 const float set_array[] = {1.0f, 2.0f, 3.0f};
266 EXPECT_TRUE(FPDFPageObj_SetDashArray(path, set_array, 3, 5.0f));
267
268 phase = -1123.5f;
269 EXPECT_TRUE(FPDFPageObj_GetDashPhase(path, &phase));
270 EXPECT_FLOAT_EQ(5.0f, phase);
271 ASSERT_EQ(3, FPDFPageObj_GetDashCount(path));
272
273 // Pretend `get_array` has too few members.
274 EXPECT_FALSE(FPDFPageObj_GetDashArray(path, get_array, 2));
275 for (int i = 0; i < 4; i++)
276 EXPECT_FLOAT_EQ(-1.0f, get_array[i]);
277
278 ASSERT_TRUE(FPDFPageObj_GetDashArray(path, get_array, 4));
279
280 // `get_array` should be modified only up to dash_count
281 for (int i = 0; i < 3; i++)
282 EXPECT_FLOAT_EQ(static_cast<float>(i + 1), get_array[i]);
283
284 EXPECT_FLOAT_EQ(-1.0f, get_array[3]);
285
286 // clear array
287 EXPECT_TRUE(FPDFPageObj_SetDashArray(path, set_array, 0, 4.0f));
288 EXPECT_EQ(0, FPDFPageObj_GetDashCount(path));
289
290 phase = -1123.5f;
291 EXPECT_TRUE(FPDFPageObj_GetDashPhase(path, &phase));
292 EXPECT_FLOAT_EQ(4.0f, phase);
293 }
294
295 UnloadPage(page);
296}
297
299 ASSERT_TRUE(OpenDocument("hello_world.pdf"));
300 FPDF_PAGE page = LoadPage(0);
301 ASSERT_TRUE(page);
302
303 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, 0);
305
306 FS_QUADPOINTSF quad;
307 ASSERT_FALSE(FPDFPageObj_GetRotatedBounds(nullptr, nullptr));
308 ASSERT_FALSE(FPDFPageObj_GetRotatedBounds(obj, nullptr));
309 ASSERT_FALSE(FPDFPageObj_GetRotatedBounds(nullptr, &quad));
310
311 UnloadPage(page);
312}
313
315 ASSERT_TRUE(OpenDocument("hello_world.pdf"));
316 FPDF_PAGE page = LoadPage(0);
317 ASSERT_TRUE(page);
318
319 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, 0);
321
322 constexpr float kExpectedLeft = 20.348f;
323 constexpr float kExpectedBottom = 48.164f;
324 constexpr float kExpectedRight = 83.36f;
325 constexpr float kExpectedTop = 58.328f;
326
327 float left;
328 float bottom;
329 float right;
330 float top;
331 ASSERT_TRUE(FPDFPageObj_GetBounds(obj, &left, &bottom, &right, &top));
332 EXPECT_FLOAT_EQ(kExpectedLeft, left);
333 EXPECT_FLOAT_EQ(kExpectedBottom, bottom);
334 EXPECT_FLOAT_EQ(kExpectedRight, right);
335 EXPECT_FLOAT_EQ(kExpectedTop, top);
336
337 FS_QUADPOINTSF quad;
338 ASSERT_TRUE(FPDFPageObj_GetRotatedBounds(obj, &quad));
339 EXPECT_FLOAT_EQ(kExpectedLeft, quad.x1);
340 EXPECT_FLOAT_EQ(kExpectedBottom, quad.y1);
341 EXPECT_FLOAT_EQ(kExpectedRight, quad.x2);
342 EXPECT_FLOAT_EQ(kExpectedBottom, quad.y2);
343 EXPECT_FLOAT_EQ(kExpectedRight, quad.x3);
344 EXPECT_FLOAT_EQ(kExpectedTop, quad.y3);
345 EXPECT_FLOAT_EQ(kExpectedLeft, quad.x4);
346 EXPECT_FLOAT_EQ(kExpectedTop, quad.y4);
347
348 UnloadPage(page);
349}
350
352 ASSERT_TRUE(OpenDocument("rotated_text.pdf"));
353 FPDF_PAGE page = LoadPage(0);
354 ASSERT_TRUE(page);
355
356 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, 0);
358
359 constexpr float kExpectedLeft = 98.9478f;
360 constexpr float kExpectedBottom = 78.2607f;
361 constexpr float kExpectedRight = 126.32983f;
362 constexpr float kExpectedTop = 105.64272f;
363
364 float left;
365 float bottom;
366 float right;
367 float top;
368 ASSERT_TRUE(FPDFPageObj_GetBounds(obj, &left, &bottom, &right, &top));
369 EXPECT_FLOAT_EQ(kExpectedLeft, left);
370 EXPECT_FLOAT_EQ(kExpectedBottom, bottom);
371 EXPECT_FLOAT_EQ(kExpectedRight, right);
372 EXPECT_FLOAT_EQ(kExpectedTop, top);
373
374 FS_QUADPOINTSF quad;
375 ASSERT_TRUE(FPDFPageObj_GetRotatedBounds(obj, &quad));
376 EXPECT_FLOAT_EQ(kExpectedLeft, quad.x1);
377 EXPECT_FLOAT_EQ(98.4557f, quad.y1);
378 EXPECT_FLOAT_EQ(119.14279f, quad.x2);
379 EXPECT_FLOAT_EQ(kExpectedBottom, quad.y2);
380 EXPECT_FLOAT_EQ(kExpectedRight, quad.x3);
381 EXPECT_FLOAT_EQ(85.447739f, quad.y3);
382 EXPECT_FLOAT_EQ(106.13486f, quad.x4);
383 EXPECT_FLOAT_EQ(kExpectedTop, quad.y4);
384
385 UnloadPage(page);
386}
387
389 ASSERT_TRUE(OpenDocument("matte.pdf"));
390 FPDF_PAGE page = LoadPage(0);
391 ASSERT_TRUE(page);
392
393 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, 2);
395
396 constexpr float kExpectedLeft = 0.0f;
397 constexpr float kExpectedBottom = 90.0f;
398 constexpr float kExpectedRight = 40.0f;
399 constexpr float kExpectedTop = 150.0f;
400
401 float left;
402 float bottom;
403 float right;
404 float top;
405 ASSERT_TRUE(FPDFPageObj_GetBounds(obj, &left, &bottom, &right, &top));
406 EXPECT_FLOAT_EQ(kExpectedLeft, left);
407 EXPECT_FLOAT_EQ(kExpectedBottom, bottom);
408 EXPECT_FLOAT_EQ(kExpectedRight, right);
409 EXPECT_FLOAT_EQ(kExpectedTop, top);
410
411 FS_QUADPOINTSF quad;
412 ASSERT_TRUE(FPDFPageObj_GetRotatedBounds(obj, &quad));
413 EXPECT_FLOAT_EQ(kExpectedLeft, quad.x1);
414 EXPECT_FLOAT_EQ(kExpectedBottom, quad.y1);
415 EXPECT_FLOAT_EQ(kExpectedRight, quad.x2);
416 EXPECT_FLOAT_EQ(kExpectedBottom, quad.y2);
417 EXPECT_FLOAT_EQ(kExpectedRight, quad.x3);
418 EXPECT_FLOAT_EQ(kExpectedTop, quad.y3);
419 EXPECT_FLOAT_EQ(kExpectedLeft, quad.x4);
420 EXPECT_FLOAT_EQ(kExpectedTop, quad.y4);
421
422 UnloadPage(page);
423}
424
426 ASSERT_TRUE(OpenDocument("rotated_image.pdf"));
427 FPDF_PAGE page = LoadPage(0);
428 ASSERT_TRUE(page);
429
430 FPDF_PAGEOBJECT obj = FPDFPage_GetObject(page, 0);
432
433 constexpr float kExpectedLeft = 100.0f;
434 constexpr float kExpectedBottom = 70.0f;
435 constexpr float kExpectedRight = 170.0f;
436 constexpr float kExpectedTop = 140.0f;
437
438 float left;
439 float bottom;
440 float right;
441 float top;
442 ASSERT_TRUE(FPDFPageObj_GetBounds(obj, &left, &bottom, &right, &top));
443 EXPECT_FLOAT_EQ(kExpectedLeft, left);
444 EXPECT_FLOAT_EQ(kExpectedBottom, bottom);
445 EXPECT_FLOAT_EQ(kExpectedRight, right);
446 EXPECT_FLOAT_EQ(kExpectedTop, top);
447
448 FS_QUADPOINTSF quad;
449 ASSERT_TRUE(FPDFPageObj_GetRotatedBounds(obj, &quad));
450 EXPECT_FLOAT_EQ(kExpectedLeft, quad.x1);
451 EXPECT_FLOAT_EQ(100.0f, quad.y1);
452 EXPECT_FLOAT_EQ(130.0f, quad.x2);
453 EXPECT_FLOAT_EQ(kExpectedBottom, quad.y2);
454 EXPECT_FLOAT_EQ(kExpectedRight, quad.x3);
455 EXPECT_FLOAT_EQ(110.0f, quad.y3);
456 EXPECT_FLOAT_EQ(140.0f, quad.x4);
457 EXPECT_FLOAT_EQ(kExpectedTop, quad.y4);
458
459 UnloadPage(page);
460}
461
463 constexpr float kDashArray[] = {2.5, 3.6};
464 constexpr float kDashPhase = 1.2;
465
466 CreateEmptyDocument();
467 {
468 ScopedFPDFPage page(FPDFPage_New(document(), 0, 612, 792));
469
470 FPDF_PAGEOBJECT path = FPDFPageObj_CreateNewPath(400, 100);
471 EXPECT_TRUE(FPDFPageObj_SetStrokeWidth(path, 2));
472 EXPECT_TRUE(FPDFPageObj_SetStrokeColor(path, 255, 0, 0, 255));
474 EXPECT_TRUE(FPDFPath_LineTo(path, 200, 200));
475 EXPECT_TRUE(FPDFPageObj_SetDashArray(path, kDashArray,
476 std::size(kDashArray), kDashPhase));
477 FPDFPage_InsertObject(page.get(), path);
478
479 EXPECT_TRUE(FPDFPage_GenerateContent(page.get()));
480 path = FPDFPage_GetObject(page.get(), 0);
481 ASSERT_TRUE(path);
482 ASSERT_EQ(2, FPDFPageObj_GetDashCount(path));
483
484 EXPECT_TRUE(FPDF_SaveAsCopy(document(), this, 0));
485 }
486
487 ASSERT_TRUE(OpenSavedDocument());
488 FPDF_PAGE page = LoadSavedPage(0);
489 ASSERT_TRUE(page);
490
491 FPDF_PAGEOBJECT path = FPDFPage_GetObject(page, 0);
492 ASSERT_TRUE(path);
493
494 float dash_array[] = {0, 0};
495 ASSERT_EQ(static_cast<int>(std::size(dash_array)),
497 ASSERT_TRUE(
498 FPDFPageObj_GetDashArray(path, dash_array, std::size(dash_array)));
499 ASSERT_EQ(kDashArray[0], dash_array[0]);
500 ASSERT_EQ(kDashArray[1], dash_array[1]);
501 float dash_phase = 0;
502 ASSERT_TRUE(FPDFPageObj_GetDashPhase(path, &dash_phase));
503 ASSERT_EQ(kDashPhase, dash_phase);
504
505 CloseSavedPage(page);
506 CloseSavedDocument();
507}
FPDF_EXPORT int FPDF_CALLCONV FPDFPage_GetRotation(FPDF_PAGE page)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_SetStrokeColor(FPDF_PAGEOBJECT page_object, unsigned int R, unsigned int G, unsigned int B, unsigned int A)
FPDF_EXPORT FPDF_PAGEOBJECT FPDF_CALLCONV FPDFPageObj_CreateNewPath(float x, float y)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPath_SetDrawMode(FPDF_PAGEOBJECT path, int fillmode, FPDF_BOOL stroke)
FPDF_EXPORT int FPDF_CALLCONV FPDFPageObj_GetDashCount(FPDF_PAGEOBJECT page_object)
FPDF_EXPORT void FPDF_CALLCONV FPDFPage_SetRotation(FPDF_PAGE page, int rotate)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_SetFillColor(FPDF_PAGEOBJECT page_object, unsigned int R, unsigned int G, unsigned int B, unsigned int A)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_GetDashPhase(FPDF_PAGEOBJECT page_object, float *phase)
#define FPDF_FILLMODE_NONE
Definition fpdf_edit.h:51
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_GetRotatedBounds(FPDF_PAGEOBJECT page_object, FS_QUADPOINTSF *quad_points)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_GetFillColor(FPDF_PAGEOBJECT page_object, unsigned int *R, unsigned int *G, unsigned int *B, unsigned int *A)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPath_LineTo(FPDF_PAGEOBJECT path, float x, float y)
FPDF_EXPORT FPDF_PAGEOBJECT FPDF_CALLCONV FPDFPage_GetObject(FPDF_PAGE page, int index)
FPDF_EXPORT int FPDF_CALLCONV FPDFPageObj_GetType(FPDF_PAGEOBJECT page_object)
#define FPDF_PAGEOBJ_PATH
Definition fpdf_edit.h:40
#define FPDF_PAGEOBJ_TEXT
Definition fpdf_edit.h:39
#define FPDF_PAGEOBJ_IMAGE
Definition fpdf_edit.h:41
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_GetBounds(FPDF_PAGEOBJECT page_object, float *left, float *bottom, float *right, float *top)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_SetDashPhase(FPDF_PAGEOBJECT page_object, float phase)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_SetStrokeWidth(FPDF_PAGEOBJECT page_object, float width)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_HasTransparency(FPDF_PAGEOBJECT page_object)
FPDF_EXPORT int FPDF_CALLCONV FPDFPage_CountObjects(FPDF_PAGE page)
FPDF_EXPORT void FPDF_CALLCONV FPDFPageObj_SetBlendMode(FPDF_PAGEOBJECT page_object, FPDF_BYTESTRING blend_mode)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObj_GetStrokeColor(FPDF_PAGEOBJECT page_object, unsigned int *R, unsigned int *G, unsigned int *B, unsigned int *A)
TEST_F(FPDFEditPageEmbedderTest, Rotation)
FPDF_EXPORT double FPDF_CALLCONV FPDF_GetPageWidth(FPDF_PAGE page)
FPDF_EXPORT double FPDF_CALLCONV FPDF_GetPageHeight(FPDF_PAGE page)
const char * RectanglesChecksum()