[Libreoffice-commits] core.git: include/vcl solenv/clang-format

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Feb 19 19:42:37 UTC 2021


 include/vcl/fixed.hxx              |   52 -------------------------------------
 include/vcl/toolkit/fixed.hxx      |   51 +++++++++++++++++++++++++++++++++++-
 include/vcl/toolkit/fixedhyper.hxx |    2 -
 solenv/clang-format/excludelist    |    1 
 4 files changed, 51 insertions(+), 55 deletions(-)

New commits:
commit d54d66e25ec0206f43ead5fe72428ebefd0b857c
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Wed Feb 17 17:35:25 2021 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Feb 19 20:41:48 2021 +0100

    move FixedText into toolkit-only headers
    
    Change-Id: I398e0eadedb58e43d670ddd947167a0a75759c2f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111089
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/include/vcl/fixed.hxx b/include/vcl/fixed.hxx
index a28f46a5e5d6..7ba9e36b9f7b 100644
--- a/include/vcl/fixed.hxx
+++ b/include/vcl/fixed.hxx
@@ -20,58 +20,6 @@
 #ifndef INCLUDED_VCL_FIXED_HXX
 #define INCLUDED_VCL_FIXED_HXX
 
-#include <vcl/dllapi.h>
-#include <vcl/ctrl.hxx>
-#include <vcl/image.hxx>
-
-class VCL_DLLPUBLIC FixedText : public Control
-{
-private:
-    sal_Int32 m_nMaxWidthChars;
-    sal_Int32 m_nMinWidthChars;
-    VclPtr<vcl::Window> m_pMnemonicWindow;
-
-    using Control::ImplInitSettings;
-    using Window::ImplInit;
-    SAL_DLLPRIVATE void    ImplInit( vcl::Window* pParent, WinBits nStyle );
-    SAL_DLLPRIVATE static WinBits ImplInitStyle( WinBits nStyle );
-    SAL_DLLPRIVATE void    ImplDraw( OutputDevice* pDev, DrawFlags nDrawFlags,
-                              const Point& rPos, const Size& rSize, bool bFillLayout = false ) const;
-public:
-    SAL_DLLPRIVATE static DrawTextFlags ImplGetTextStyle( WinBits nWinBits );
-protected:
-    virtual void    FillLayoutData() const override;
-    virtual const vcl::Font&
-                    GetCanonicalFont( const StyleSettings& _rStyle ) const override;
-    virtual const Color&
-                    GetCanonicalTextColor( const StyleSettings& _rStyle ) const override;
-
-    virtual vcl::Window* getAccessibleRelationLabelFor() const override;
-
-public:
-    explicit        FixedText( vcl::Window* pParent, WinBits nStyle = 0 );
-    virtual         ~FixedText() override;
-    virtual void    dispose() override;
-
-    virtual void    ApplySettings(vcl::RenderContext& rRenderContext) override;
-
-    virtual void    Paint( vcl::RenderContext& rRenderContext, const tools::Rectangle& rRect ) override;
-    virtual void    Draw( OutputDevice* pDev, const Point& rPos, DrawFlags nFlags ) override;
-    virtual void    Resize() override;
-    virtual void    StateChanged( StateChangedType nType ) override;
-    virtual void    DataChanged( const DataChangedEvent& rDCEvt ) override;
-
-    void            setMaxWidthChars(sal_Int32 nWidth);
-    void            setMinWidthChars(sal_Int32 nWidth);
-    static Size     CalcMinimumTextSize(Control const* pControl, tools::Long nMaxWidth = 0x7fffffff);
-    static Size     getTextDimensions(Control const *pControl, const OUString &rTxt, tools::Long nMaxWidth);
-    Size            CalcMinimumSize(tools::Long nMaxWidth = 0x7fffffff) const;
-    virtual Size    GetOptimalSize() const override;
-    virtual bool    set_property(const OString &rKey, const OUString &rValue) override;
-    void            set_mnemonic_widget(vcl::Window *pWindow);
-    vcl::Window*    get_mnemonic_widget() const { return m_pMnemonicWindow; }
-};
-
 #endif // INCLUDED_VCL_FIXED_HXX
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/vcl/toolkit/fixed.hxx b/include/vcl/toolkit/fixed.hxx
index 2598b2497d02..2f170cc904c4 100644
--- a/include/vcl/toolkit/fixed.hxx
+++ b/include/vcl/toolkit/fixed.hxx
@@ -24,7 +24,56 @@
 
 #include <vcl/dllapi.h>
 #include <vcl/toolkit/edit.hxx>
-#include <vcl/fixed.hxx>
+#include <vcl/ctrl.hxx>
+#include <vcl/image.hxx>
+
+class VCL_DLLPUBLIC FixedText : public Control
+{
+private:
+    sal_Int32 m_nMaxWidthChars;
+    sal_Int32 m_nMinWidthChars;
+    VclPtr<vcl::Window> m_pMnemonicWindow;
+
+    using Control::ImplInitSettings;
+    using Window::ImplInit;
+    SAL_DLLPRIVATE void    ImplInit( vcl::Window* pParent, WinBits nStyle );
+    SAL_DLLPRIVATE static WinBits ImplInitStyle( WinBits nStyle );
+    SAL_DLLPRIVATE void    ImplDraw( OutputDevice* pDev, DrawFlags nDrawFlags,
+                              const Point& rPos, const Size& rSize, bool bFillLayout = false ) const;
+public:
+    SAL_DLLPRIVATE static DrawTextFlags ImplGetTextStyle( WinBits nWinBits );
+protected:
+    virtual void    FillLayoutData() const override;
+    virtual const vcl::Font&
+                    GetCanonicalFont( const StyleSettings& _rStyle ) const override;
+    virtual const Color&
+                    GetCanonicalTextColor( const StyleSettings& _rStyle ) const override;
+
+    virtual vcl::Window* getAccessibleRelationLabelFor() const override;
+
+public:
+    explicit        FixedText( vcl::Window* pParent, WinBits nStyle = 0 );
+    virtual         ~FixedText() override;
+    virtual void    dispose() override;
+
+    virtual void    ApplySettings(vcl::RenderContext& rRenderContext) override;
+
+    virtual void    Paint( vcl::RenderContext& rRenderContext, const tools::Rectangle& rRect ) override;
+    virtual void    Draw( OutputDevice* pDev, const Point& rPos, DrawFlags nFlags ) override;
+    virtual void    Resize() override;
+    virtual void    StateChanged( StateChangedType nType ) override;
+    virtual void    DataChanged( const DataChangedEvent& rDCEvt ) override;
+
+    void            setMaxWidthChars(sal_Int32 nWidth);
+    void            setMinWidthChars(sal_Int32 nWidth);
+    static Size     CalcMinimumTextSize(Control const* pControl, tools::Long nMaxWidth = 0x7fffffff);
+    static Size     getTextDimensions(Control const *pControl, const OUString &rTxt, tools::Long nMaxWidth);
+    Size            CalcMinimumSize(tools::Long nMaxWidth = 0x7fffffff) const;
+    virtual Size    GetOptimalSize() const override;
+    virtual bool    set_property(const OString &rKey, const OUString &rValue) override;
+    void            set_mnemonic_widget(vcl::Window *pWindow);
+    vcl::Window*    get_mnemonic_widget() const { return m_pMnemonicWindow; }
+};
 
 class SelectableFixedText final : public Edit
 {
diff --git a/include/vcl/toolkit/fixedhyper.hxx b/include/vcl/toolkit/fixedhyper.hxx
index 75516984bce0..1a7ec8fada7d 100644
--- a/include/vcl/toolkit/fixedhyper.hxx
+++ b/include/vcl/toolkit/fixedhyper.hxx
@@ -26,7 +26,7 @@
 
 #include <config_options.h>
 #include <vcl/dllapi.h>
-#include <vcl/fixed.hxx>
+#include <vcl/toolkit/fixed.hxx>
 
 class UNLESS_MERGELIBS(VCL_DLLPUBLIC) FixedHyperlink final : public FixedText
 {
diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index bb574d63a478..7b5326ce4b18 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -6383,7 +6383,6 @@ include/vcl/errcode.hxx
 include/vcl/errinf.hxx
 include/vcl/event.hxx
 include/vcl/evntpost.hxx
-include/vcl/fixed.hxx
 include/vcl/floatwin.hxx
 include/vcl/formatter.hxx
 include/vcl/fntstyle.hxx


More information about the Libreoffice-commits mailing list