diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2020-10-15 14:11:54 +0200 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2020-10-18 21:22:46 +0200 |
commit | aa301119c98bc5103d3738263b1df90b30013e32 (patch) | |
tree | b108e03ef1bff7d33dd1dccfea1036f9b4227919 /vcl/qa | |
parent | 2a1b5af875d8ee84fec18c781020d836c4650dc9 (diff) |
pdfium: add reading of line points to the wrapper
Change-Id: I3e596254b2e4ecc9f56ff09eeb63b66195ea6a2e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104376
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'vcl/qa')
-rw-r--r-- | vcl/qa/cppunit/PDFiumLibraryTest.cxx | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/vcl/qa/cppunit/PDFiumLibraryTest.cxx b/vcl/qa/cppunit/PDFiumLibraryTest.cxx index 2ef9ba942f27..6b4dbedff185 100644 --- a/vcl/qa/cppunit/PDFiumLibraryTest.cxx +++ b/vcl/qa/cppunit/PDFiumLibraryTest.cxx @@ -325,6 +325,8 @@ void PDFiumLibraryTest::testAnnotationsDifferentTypes() CPPUNIT_ASSERT_EQUAL(0, pAnnotation->getObjectCount()); OUString aContentsString = pAnnotation->getString(vcl::pdf::constDictionaryKeyContents); CPPUNIT_ASSERT_EQUAL(OUString("Inline Note"), aContentsString); + auto const& rLineGeometry = pAnnotation->getLineGeometry(); + CPPUNIT_ASSERT_EQUAL(true, rLineGeometry.empty()); } { @@ -339,6 +341,8 @@ void PDFiumLibraryTest::testAnnotationsDifferentTypes() auto const& aPoints = aInkStrokes[0]; CPPUNIT_ASSERT_EQUAL(size_t(74), aPoints.size()); CPPUNIT_ASSERT_DOUBLES_EQUAL(2.0f, pAnnotation->getBorderWidth(), 1E-2); + auto const& rLineGeometry = pAnnotation->getLineGeometry(); + CPPUNIT_ASSERT_EQUAL(true, rLineGeometry.empty()); } { @@ -348,6 +352,8 @@ void PDFiumLibraryTest::testAnnotationsDifferentTypes() CPPUNIT_ASSERT_EQUAL(0, pAnnotation->getObjectCount()); OUString aContentsString = pAnnotation->getString(vcl::pdf::constDictionaryKeyContents); CPPUNIT_ASSERT_EQUAL(OUString("Line Text"), aContentsString); + auto const& rLineGeometry = pAnnotation->getLineGeometry(); + CPPUNIT_ASSERT_EQUAL(false, rLineGeometry.empty()); } { @@ -361,6 +367,8 @@ void PDFiumLibraryTest::testAnnotationsDifferentTypes() auto const& aVertices = pAnnotation->getVertices(); CPPUNIT_ASSERT_EQUAL(size_t(3), aVertices.size()); CPPUNIT_ASSERT_DOUBLES_EQUAL(2.0f, pAnnotation->getBorderWidth(), 1E-2); + auto const& rLineGeometry = pAnnotation->getLineGeometry(); + CPPUNIT_ASSERT_EQUAL(true, rLineGeometry.empty()); } { @@ -370,6 +378,8 @@ void PDFiumLibraryTest::testAnnotationsDifferentTypes() CPPUNIT_ASSERT_EQUAL(0, pAnnotation->getObjectCount()); OUString aContentsString = pAnnotation->getString(vcl::pdf::constDictionaryKeyContents); CPPUNIT_ASSERT_EQUAL(OUString("Ellipse Text"), aContentsString); + auto const& rLineGeometry = pAnnotation->getLineGeometry(); + CPPUNIT_ASSERT_EQUAL(true, rLineGeometry.empty()); } { @@ -381,6 +391,8 @@ void PDFiumLibraryTest::testAnnotationsDifferentTypes() CPPUNIT_ASSERT_EQUAL(OUString("Rectangle Text"), aContentsString); CPPUNIT_ASSERT_EQUAL(Color(0xFF, 0xE0, 0x00), pAnnotation->getColor()); CPPUNIT_ASSERT_EQUAL(false, pAnnotation->hasKey(vcl::pdf::constDictionaryKeyInteriorColor)); + auto const& rLineGeometry = pAnnotation->getLineGeometry(); + CPPUNIT_ASSERT_EQUAL(true, rLineGeometry.empty()); } } |