include/vcl/outdev.hxx                 |    2 -
 vcl/CppunitTest_vcl_font.mk            |    5 --
 vcl/qa/cppunit/logicalfontinstance.cxx |   59 ---------------------------------
 3 files changed, 1 insertion(+), 65 deletions(-)

New commits:
commit 1ff2f5fa2d8c353b0cad28317a696c2ba9a4aab5
Author:     خالد حسني <kha...@aliftype.com>
AuthorDate: Mon Nov 21 15:01:39 2022 +0100
Commit:     خالد حسني <kha...@aliftype.com>
CommitDate: Mon Nov 21 19:58:22 2022 +0100

    Revert "vcl: test getting glyph boundary rect from LogicalFontInstance"
    
    This reverts commit 0cef06f0a2c0963e8c1579b78975710e6af4471c.
    
    Reason for revert:
    
    https://gerrit.libreoffice.org/c/core/+/141234/comments/89325e55_2271cfe8
    
    > Stephan Bergmann:
    >
    > I saw the unrelated <https://gerrit.libreoffice.org/c/core/+/143026/1> 
fail its Jenkins <https://ci.libreoffice.org/job/gerrit_windows/140750/> build 
on tb88-win with
    >
    >   
C:/cygwin64/home/tdf/jenkins/workspace/gerrit_windows/vcl/qa/cppunit/logicalfontinstance.cxx(53)
 : error : Assertion
    >   Test name: VclLogicalFontInstanceTest::testglyphboundrect
    >   equality assertion failed
    >   - Expected: 51x82@(7,-80)
    >   - Actual  : 50x82@(7,-80)
    
    Change-Id: Idc4132adbaf0b051dcf955f3f1e7c44841c60117
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142928
    Tested-by: Jenkins
    Reviewed-by: خالد حسني <kha...@aliftype.com>

diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index b4fdd82e1ab9..14c1675e7eed 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -1176,7 +1176,7 @@ public:
     //If bNewFontLists is true then drop and refetch lists of system fonts
     SAL_DLLPRIVATE static void  ImplUpdateAllFontData( bool bNewFontLists );
 
-    const LogicalFontInstance* GetFontInstance() const;
+    SAL_DLLPRIVATE const LogicalFontInstance* GetFontInstance() const;
 
 protected:
     SAL_DLLPRIVATE tools::Long GetEmphasisAscent() const { return 
mnEmphasisAscent; }
diff --git a/vcl/CppunitTest_vcl_font.mk b/vcl/CppunitTest_vcl_font.mk
index 813ab1c9c009..891352508a1c 100644
--- a/vcl/CppunitTest_vcl_font.mk
+++ b/vcl/CppunitTest_vcl_font.mk
@@ -20,7 +20,6 @@ $(eval $(call gb_CppunitTest_add_exception_objects,vcl_font, \
        vcl/qa/cppunit/physicalfontfacecollection \
        vcl/qa/cppunit/physicalfontfamily \
        vcl/qa/cppunit/physicalfontcollection \
-       vcl/qa/cppunit/logicalfontinstance \
 ))
 
 $(eval $(call gb_CppunitTest_use_externals,vcl_font,\
@@ -57,8 +56,4 @@ $(eval $(call gb_CppunitTest_use_components,vcl_font,\
 
 $(eval $(call gb_CppunitTest_use_configuration,vcl_font))
 
-$(eval $(call gb_CppunitTest_use_more_fonts,vcl_font))
-
-$(eval $(call gb_CppunitTest_set_non_application_font_use,vcl_font,abort))
-
 # vim: set noet sw=4 ts=4:
diff --git a/vcl/qa/cppunit/logicalfontinstance.cxx 
b/vcl/qa/cppunit/logicalfontinstance.cxx
deleted file mode 100644
index 56b9897f0589..000000000000
--- a/vcl/qa/cppunit/logicalfontinstance.cxx
+++ /dev/null
@@ -1,59 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include <sal/config.h>
-
-#include <test/bootstrapfixture.hxx>
-#include <cppunit/TestAssert.h>
-
-#include <vcl/virdev.hxx>
-#include <vcl/font.hxx>
-
-#include <font/LogicalFontInstance.hxx>
-
-#include <memory>
-
-class VclLogicalFontInstanceTest : public test::BootstrapFixture
-{
-public:
-    VclLogicalFontInstanceTest()
-        : BootstrapFixture(true, false)
-    {
-    }
-
-    void testglyphboundrect();
-
-    CPPUNIT_TEST_SUITE(VclLogicalFontInstanceTest);
-    CPPUNIT_TEST(testglyphboundrect);
-
-    CPPUNIT_TEST_SUITE_END();
-};
-
-void VclLogicalFontInstanceTest::testglyphboundrect()
-{
-    ScopedVclPtr<VirtualDevice> device = 
VclPtr<VirtualDevice>::Create(DeviceFormat::DEFAULT);
-    device->SetOutputSizePixel(Size(1000, 1000));
-    device->SetFont(vcl::Font("Liberation Sans", Size(0, 110)));
-
-    const LogicalFontInstance* pFontInstance = device->GetFontInstance();
-
-    tools::Rectangle aBoundRect;
-    const auto LATIN_SMALL_LETTER_B = 0x0062;
-    
pFontInstance->GetGlyphBoundRect(pFontInstance->GetGlyphIndex(LATIN_SMALL_LETTER_B),
 aBoundRect,
-                                     false);
-#ifdef MACOSX
-    CPPUNIT_ASSERT_EQUAL(tools::Rectangle(Point(7, -80), Size(51, 83)), 
aBoundRect);
-#else
-    CPPUNIT_ASSERT_EQUAL(tools::Rectangle(Point(7, -80), Size(51, 82)), 
aBoundRect);
-#endif
-}
-
-CPPUNIT_TEST_SUITE_REGISTRATION(VclLogicalFontInstanceTest);
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */

Reply via email to