summaryrefslogtreecommitdiff
path: root/vcl/qa
diff options
context:
space:
mode:
authorChris Sherlock <chris.sherlock79@gmail.com>2021-08-25 18:16:38 +1000
committerMike Kaganski <mike.kaganski@collabora.com>2021-09-10 09:52:21 +0200
commit9db1e85a8da3952cefef552853753342d7147b98 (patch)
tree33375a1642e3cdeb05d276cd8ab9a447945c6f97 /vcl/qa
parentaf78873e2000e604c9de78280cbcfbfcf4c7e99b (diff)
vcl: move OutputDevice drawmode functions to outdev.cxx
Ultimately I hope to reduce outdevstate.cxx to only have push(), pop() and clearstack(), then rename outdevstate.cxx to stack.cxx. Eventually, the plan is to separate metafile processing from rendering. Add unit test for GetDrawMode() and SetDrawMode(). Change-Id: I63948e7e4c332c786487c18c52faa60893f672a5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121021 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'vcl/qa')
-rw-r--r--vcl/qa/cppunit/outdev.cxx13
1 files changed, 13 insertions, 0 deletions
diff --git a/vcl/qa/cppunit/outdev.cxx b/vcl/qa/cppunit/outdev.cxx
index ee1dc6a37b8d..f7a50b3bb5d2 100644
--- a/vcl/qa/cppunit/outdev.cxx
+++ b/vcl/qa/cppunit/outdev.cxx
@@ -58,6 +58,7 @@ public:
void testRefPoint();
void testRasterOp();
void testOutputFlag();
+ void testDrawMode();
void testAntialias();
void testSystemTextColor();
void testShouldDrawWavePixelAsRect();
@@ -93,6 +94,7 @@ public:
CPPUNIT_TEST(testRefPoint);
CPPUNIT_TEST(testRasterOp);
CPPUNIT_TEST(testAntialias);
+ CPPUNIT_TEST(testDrawMode);
CPPUNIT_TEST(testOutputFlag);
CPPUNIT_TEST(testSystemTextColor);
CPPUNIT_TEST(testShouldDrawWavePixelAsRect);
@@ -814,6 +816,17 @@ void VclOutdevTest::testAntialias()
CPPUNIT_ASSERT_EQUAL(AntialiasingFlags::Enable, pVDev->GetAntialiasing());
}
+void VclOutdevTest::testDrawMode()
+{
+ ScopedVclPtrInstance<VirtualDevice> pVDev;
+
+ CPPUNIT_ASSERT_EQUAL(DrawModeFlags::Default, pVDev->GetDrawMode());
+
+ pVDev->SetDrawMode(DrawModeFlags::BlackLine);
+
+ CPPUNIT_ASSERT_EQUAL(DrawModeFlags::BlackLine, pVDev->GetDrawMode());
+}
+
void VclOutdevTest::testSystemTextColor()
{
{