5#include "core/fxcrt/fx_system.h"
6#include "public/fpdf_edit.h"
7#include "testing/embedder_test.h"
8#include "testing/gtest/include/gtest/gtest.h"
9#include "third_party/base/check.h"
14 constexpr int kObjectCount = 256;
15 CreateEmptyDocument();
16 FPDF_PAGE page = FPDFPage_New(document(), 0, 612, 792);
18 for (size_t i = 0; i < kObjectCount; ++i) {
20 EXPECT_TRUE(FPDFPageObj_SetFillColor(path, i, i, i, i));
21 EXPECT_TRUE(FPDFPageObj_SetStrokeColor(path, i, i, i, i));
31 EXPECT_TRUE(FPDF_SaveAsCopy(document(),
this, 0));
35 ASSERT_TRUE(OpenSavedDocument());
36 page = LoadSavedPage(0);
39 for (size_t i = 0; i < kObjectCount; ++i) {
40 FPDF_PAGEOBJECT path = FPDFPage_GetObject(page, i);
#define FPDF_FILLMODE_ALTERNATE
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 void FPDF_CALLCONV FPDFPage_InsertObject(FPDF_PAGE page, FPDF_PAGEOBJECT page_object)
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPath_Close(FPDF_PAGEOBJECT path)
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 int FPDF_CALLCONV FPDFPageObj_GetType(FPDF_PAGEOBJECT page_object)
#define FPDF_PAGEOBJ_PATH
FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPage_GenerateContent(FPDF_PAGE page)
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(FPDFEditPathEmbedderTest, VerifyCorrectColoursReturned)
FPDF_EXPORT void FPDF_CALLCONV FPDF_ClosePage(FPDF_PAGE page)