From 7031388d8cd1dc2239d41c7693792dafe1f575c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= Date: Thu, 10 Feb 2011 12:51:07 +0000 Subject: [PATCH] fix optimal zoom --- ...50-i94623-use-optimal-border-width-w.patch | 34 +++++++++++++++++++ libreoffice.spec | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 0001-Resolves-fdo-33750-i94623-use-optimal-border-width-w.patch diff --git a/0001-Resolves-fdo-33750-i94623-use-optimal-border-width-w.patch b/0001-Resolves-fdo-33750-i94623-use-optimal-border-width-w.patch new file mode 100644 index 0000000..5d763b2 --- /dev/null +++ b/0001-Resolves-fdo-33750-i94623-use-optimal-border-width-w.patch @@ -0,0 +1,34 @@ +From 773d856c8ef2bf65aec25289cb0186d81d76f5f1 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= +Date: Thu, 10 Feb 2011 12:46:34 +0000 +Subject: [PATCH] Resolves: fdo#33750 #i94623# use optimal border width when zooming to optimal + +--- + sw/source/ui/uiview/viewmdi.cxx | 10 ++-------- + 1 files changed, 2 insertions(+), 8 deletions(-) + +diff --git a/sw/source/ui/uiview/viewmdi.cxx b/sw/source/ui/uiview/viewmdi.cxx +index 3310b83..28af9ca 100644 +--- a/sw/source/ui/uiview/viewmdi.cxx ++++ b/sw/source/ui/uiview/viewmdi.cxx +@@ -123,15 +123,9 @@ void SwView::_SetZoom( const Size &rEditSize, SvxZoomType eZoomType, + + if( SVX_ZOOM_OPTIMAL == eZoomType ) + { +- if (pPostItMgr->HasNotes() && pPostItMgr->ShowNotes()) +- { +- lLeftMargin = long(rLRSpace.GetLeft()) + aPageRect.Left() + nLeftOfst; +- } +- else +- { ++ if (!pPostItMgr->HasNotes() || !pPostItMgr->ShowNotes()) + aPageSize.Width() -= ( rLRSpace.GetLeft() + rLRSpace.GetRight() + nLeftOfst * 2 ); +- lLeftMargin = long(rLRSpace.GetLeft()) + aPageRect.Left() + nLeftOfst; +- } ++ lLeftMargin = long(rLRSpace.GetLeft()) + DOCUMENTBORDER + nLeftOfst; + nFac = aWindowSize.Width() * 100 / aPageSize.Width(); + } + else if(SVX_ZOOM_WHOLEPAGE == eZoomType || SVX_ZOOM_PAGEWIDTH == eZoomType ) +-- +1.7.4 + diff --git a/libreoffice.spec b/libreoffice.spec index 39e50db..c9d2eb3 100644 --- a/libreoffice.spec +++ b/libreoffice.spec @@ -114,6 +114,7 @@ Patch26: 0001-Resolves-fdo-33509-i62414-out-by-one-breaks-CTL-spel.patch Patch27: 0001-Resolves-rhbz-673819-crash-on-changing-position-of-d.patch Patch28: 0001-Resolves-rhbz-670020-crash-in-slidesorting.patch Patch29: 0001-Resolves-rhbz-676539-handle-missing-pWindows-from-xW.patch +Patch30: 0001-Resolves-fdo-33750-i94623-use-optimal-border-width-w.patch %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")} %define instdir %{_libdir} @@ -746,6 +747,7 @@ mv -f redhat.soc extras/source/palettes/standard.soc %patch27 -p1 -b .rhbz673819-crash-on-changing-position-of-d.patch %patch28 -p1 -b .rhbz670020-crash-in-slidesorting.patch %patch29 -p1 -b .rhbz676539-handle-missing-pWindows-from-xW.patch +%patch30 -p1 -b .fdo33750-i94623-use-optimal-border-width-w.patch touch scripting/source/pyprov/delzip touch scripting/util/provider/beanshell/delzip touch scripting/util/provider/javascript/delzip