diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2020-01-02 18:06:05 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2020-01-03 09:05:29 +0100 |
commit | c48790b5cec73a49aed20c26b123c3656bb9eff9 (patch) | |
tree | 94aeb6380b938228afbbb17a95883b09f1ea301c /sw/qa/extras/unowriter | |
parent | 1c743f157047a697e4f232d51ac7bc70ec98dd12 (diff) |
sw: add UNO API for semi-transparent text
This makes the ODF filter work out of the box, since the same property
was provided by Draw/Impress in the past already.
Change-Id: Ie6a053864c9fa41fad6ca4571d7d04a3756b7591
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86147
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'sw/qa/extras/unowriter')
-rw-r--r-- | sw/qa/extras/unowriter/unowriter.cxx | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/sw/qa/extras/unowriter/unowriter.cxx b/sw/qa/extras/unowriter/unowriter.cxx index 1cceb108181d..2f01c47605ba 100644 --- a/sw/qa/extras/unowriter/unowriter.cxx +++ b/sw/qa/extras/unowriter/unowriter.cxx @@ -824,6 +824,22 @@ CPPUNIT_TEST_FIXTURE(SwUnoWriter, testMultiSelect) } } +CPPUNIT_TEST_FIXTURE(SwUnoWriter, testTransparentText) +{ + // Test the CharTransparence text portion property. + + // Create a new document. + loadURL("private:factory/swriter", nullptr); + + // Set a custom transparency. + uno::Reference<beans::XPropertySet> xParagraph(getParagraph(1), uno::UNO_QUERY); + sal_Int16 nExpected = 42; + xParagraph->setPropertyValue("CharTransparence", uno::makeAny(nExpected)); + + // Get the transparency & verify. + CPPUNIT_ASSERT_EQUAL(nExpected, getProperty<sal_Int16>(xParagraph, "CharTransparence")); +} + CPPUNIT_PLUGIN_IMPLEMENT(); /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |