Kaydet (Commit) 4305d9a4 authored tarafından Ashod Nakashian's avatar Ashod Nakashian Kaydeden (comit) Jan Holesovsky

Revert "lok: custom widgets: render editbox borders"

Looks like this is no longer needed to correctly render
editbox borders. Not clear what fixed the issue.

This reverts commit 7484f169.

Change-Id: Ieb3b8d6f60ab762d0baccb341ed6a39ae2771e79
Reviewed-on: https://gerrit.libreoffice.org/66774
Tested-by: Jenkins
Reviewed-by: 's avatarJan Holesovsky <kendy@collabora.com>
üst bd1aeecf
...@@ -117,7 +117,7 @@ private: ...@@ -117,7 +117,7 @@ private:
SAL_DLLPRIVATE void ImplInsertText( const OUString& rStr, const Selection* pNewSelection = nullptr, bool bIsUserInput = false ); SAL_DLLPRIVATE void ImplInsertText( const OUString& rStr, const Selection* pNewSelection = nullptr, bool bIsUserInput = false );
SAL_DLLPRIVATE static OUString ImplGetValidString( const OUString& rString ); SAL_DLLPRIVATE static OUString ImplGetValidString( const OUString& rString );
SAL_DLLPRIVATE void ImplClearBackground(vcl::RenderContext& rRenderContext, const tools::Rectangle& rRectangle, long nXStart, long nXEnd); SAL_DLLPRIVATE void ImplClearBackground(vcl::RenderContext& rRenderContext, const tools::Rectangle& rRectangle, long nXStart, long nXEnd);
SAL_DLLPRIVATE void ImplPaintBorder(vcl::RenderContext& rRenderContext); SAL_DLLPRIVATE void ImplPaintBorder(vcl::RenderContext const & rRenderContext);
SAL_DLLPRIVATE void ImplShowCursor( bool bOnlyIfVisible = true ); SAL_DLLPRIVATE void ImplShowCursor( bool bOnlyIfVisible = true );
SAL_DLLPRIVATE void ImplAlign(); SAL_DLLPRIVATE void ImplAlign();
SAL_DLLPRIVATE void ImplAlignAndPaint(); SAL_DLLPRIVATE void ImplAlignAndPaint();
......
...@@ -55,7 +55,6 @@ ...@@ -55,7 +55,6 @@
#include <comphelper/processfactory.hxx> #include <comphelper/processfactory.hxx>
#include <comphelper/string.hxx> #include <comphelper/string.hxx>
#include <comphelper/lok.hxx>
#include <sot/exchange.hxx> #include <sot/exchange.hxx>
#include <sot/formats.hxx> #include <sot/formats.hxx>
...@@ -987,7 +986,7 @@ void Edit::ImplClearBackground(vcl::RenderContext& rRenderContext, const tools:: ...@@ -987,7 +986,7 @@ void Edit::ImplClearBackground(vcl::RenderContext& rRenderContext, const tools::
} }
} }
void Edit::ImplPaintBorder(vcl::RenderContext& rRenderContext) void Edit::ImplPaintBorder(vcl::RenderContext const & rRenderContext)
{ {
// this is not needed when double-buffering // this is not needed when double-buffering
if (SupportsDoubleBuffering()) if (SupportsDoubleBuffering())
...@@ -1044,17 +1043,7 @@ void Edit::ImplPaintBorder(vcl::RenderContext& rRenderContext) ...@@ -1044,17 +1043,7 @@ void Edit::ImplPaintBorder(vcl::RenderContext& rRenderContext)
} }
else else
{ {
// For some mysterious reason, in headless/svp rendering, pBorder->Paint(*pBorder, tools::Rectangle());
// pBorder has bad clipping region (shows as 1x1@0,0),
// and therefore doesn't render anything at all.
// In the case that we know we're in headless/svp, we
// render directly on the current context (the edit control).
// But if we (the editbox) are part of a more complex control
// (e.g. spinbox), we render not (i.e. we let pBorder pretend).
if (!mbIsSubEdit && comphelper::LibreOfficeKit::isActive())
pBorder->Paint(rRenderContext, tools::Rectangle());
else
pBorder->Paint(*pBorder, tools::Rectangle());
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment