diff options
author | Chris Sherlock <chris.sherlock79@gmail.com> | 2022-06-29 00:06:03 +1000 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2022-07-11 11:06:53 +0200 |
commit | 934985becc567114c3f38a72322056a628aad7c9 (patch) | |
tree | 54530473a4d3a0a5876aff68b3727d51fa4dc88d /svtools | |
parent | a19e01812b60580c656cf31619e212803e2ca0fa (diff) |
tools: rename getHeight/Width() to GetOpenHeight/Width()
By default Rectangle uses closed interval, if we really want to use half
open intervals then we should specifically say as such in the name.
Change-Id: Id7a91120ba1a1a4bc330014216b73a692dbf03a2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136575
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'svtools')
-rw-r--r-- | svtools/source/control/tabbar.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/svtools/source/control/tabbar.cxx b/svtools/source/control/tabbar.cxx index a62d0ae6fad9..d47d96bc105a 100644 --- a/svtools/source/control/tabbar.cxx +++ b/svtools/source/control/tabbar.cxx @@ -105,8 +105,8 @@ public: tools::Long nTextWidth = mrRenderContext.GetTextWidth(aText); tools::Long nTextHeight = mrRenderContext.GetTextHeight(); Point aPos = aRect.TopLeft(); - aPos.AdjustX((aRect.getWidth() - nTextWidth) / 2 ); - aPos.AdjustY((aRect.getHeight() - nTextHeight) / 2 ); + aPos.AdjustX((aRect.getOpenWidth() - nTextWidth) / 2 ); + aPos.AdjustY((aRect.getOpenHeight() - nTextHeight) / 2 ); if (mbEnabled) mrRenderContext.DrawText(aPos, aText); @@ -157,7 +157,7 @@ public: BitmapEx aBitmap(BMP_TAB_LOCK); Point aPosition = maRect.TopLeft(); aPosition.AdjustX(2); - aPosition.AdjustY((maRect.getHeight() - aBitmap.GetSizePixel().Height()) / 2); + aPosition.AdjustY((maRect.getOpenHeight() - aBitmap.GetSizePixel().Height()) / 2); mrRenderContext.DrawBitmapEx(aPosition, aBitmap); } } |