import libreoffice-6.4.7.2-5.el8
This commit is contained in:
parent
81eae45351
commit
2cd2f03381
@ -0,0 +1,82 @@
|
||||
From 8bfdd84ffcffe19aa6c495a0772e1a5fcb9a5124 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= <caolanm@redhat.com>
|
||||
Date: Fri, 25 Sep 2020 11:22:03 +0100
|
||||
Subject: [PATCH] rhbz#1882616 move cursor one step at a time in the desired
|
||||
direction
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
until we get to the target position. The break iterator operates in graphemes
|
||||
so we can't just move Left/Right the amount of utf-16 we want to move.
|
||||
|
||||
Change-Id: I25d4e9285deae374f85dcaadbf4601bc213a89de
|
||||
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103380
|
||||
Tested-by: Jenkins
|
||||
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
||||
(cherry picked from commit bf858622e543163a23db766912ea6b121f447e6d)
|
||||
---
|
||||
sw/source/core/edit/editsh.cxx | 40 +++++++++++++++++++++++++++++-----
|
||||
1 file changed, 35 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/sw/source/core/edit/editsh.cxx b/sw/source/core/edit/editsh.cxx
|
||||
index 8f84ce42ed75..872d92d7afcc 100644
|
||||
--- a/sw/source/core/edit/editsh.cxx
|
||||
+++ b/sw/source/core/edit/editsh.cxx
|
||||
@@ -988,7 +988,8 @@ OUString SwEditShell::DeleteExtTextInput( bool bInsText )
|
||||
|
||||
void SwEditShell::SetExtTextInputData( const CommandExtTextInputData& rData )
|
||||
{
|
||||
- const SwPosition& rPos = *GetCursor()->GetPoint();
|
||||
+ SwPaM* pCurrentCursor = GetCursor();
|
||||
+ const SwPosition& rPos = *pCurrentCursor->GetPoint();
|
||||
SwExtTextInput* pInput = GetDoc()->GetExtTextInput( rPos.nNode.GetNode() );
|
||||
if( !pInput )
|
||||
return;
|
||||
@@ -1005,10 +1006,39 @@ void SwEditShell::SetExtTextInputData( const CommandExtTextInputData& rData )
|
||||
// ugly but works
|
||||
ShowCursor();
|
||||
const sal_Int32 nDiff = nNewCursorPos - rPos.nContent.GetIndex();
|
||||
- if( 0 > nDiff )
|
||||
- Left( -nDiff, CRSR_SKIP_CHARS );
|
||||
- else if( 0 < nDiff )
|
||||
- Right( nDiff, CRSR_SKIP_CHARS );
|
||||
+ if( nDiff != 0)
|
||||
+ {
|
||||
+ bool bLeft = nDiff < 0;
|
||||
+ sal_Int32 nMaxGuard = std::abs(nDiff);
|
||||
+ while (true)
|
||||
+ {
|
||||
+ auto nOldPos = pCurrentCursor->GetPoint()->nContent.GetIndex();
|
||||
+ if (bLeft)
|
||||
+ Left(1, CRSR_SKIP_CHARS);
|
||||
+ else
|
||||
+ Right(1, CRSR_SKIP_CHARS);
|
||||
+ auto nNewPos = pCurrentCursor->GetPoint()->nContent.GetIndex();
|
||||
+
|
||||
+ // expected success
|
||||
+ if (nNewPos == nNewCursorPos)
|
||||
+ break;
|
||||
+
|
||||
+ if (nNewPos == nOldPos)
|
||||
+ {
|
||||
+ // if there was no movement, we have failed for some reason
|
||||
+ SAL_WARN("sw.core", "IM cursor move failed");
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ if (--nMaxGuard == 0)
|
||||
+ {
|
||||
+ // if it takes more cursor moves than there are utf-16 chars to move past
|
||||
+ // something has probably gone wrong
|
||||
+ SAL_WARN("sw.core", "IM abandoning cursor positioning");
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
|
||||
SetOverwriteCursor( rData.IsCursorOverwrite() );
|
||||
|
||||
--
|
||||
2.29.2
|
||||
|
@ -54,7 +54,7 @@ Summary: Free Software Productivity Suite
|
||||
Name: libreoffice
|
||||
Epoch: 1
|
||||
Version: %{libo_version}.2
|
||||
Release: 4%{?libo_prerelease}%{?dist}
|
||||
Release: 5%{?libo_prerelease}%{?dist}
|
||||
License: (MPLv1.1 or LGPLv3+) and LGPLv3 and LGPLv2+ and BSD and (MPLv1.1 or GPLv2 or LGPLv2 or Netscape) and Public Domain and ASL 2.0 and MPLv2.0 and CC0
|
||||
URL: http://www.libreoffice.org/
|
||||
|
||||
@ -213,7 +213,9 @@ BuildRequires: libnumbertext-devel
|
||||
|
||||
# java stuff
|
||||
BuildRequires: ant
|
||||
%if 0%{?fedora}
|
||||
BuildRequires: bsh
|
||||
%endif
|
||||
BuildRequires: java-devel
|
||||
BuildRequires: junit
|
||||
BuildRequires: pentaho-reporting-flow-engine
|
||||
@ -264,6 +266,7 @@ Patch22: 0005-cid-1460969-Uninitialized-scalar-field.patch
|
||||
Patch23: 0006-tdf-137897-scRetypePassInputDlg-re-allow-password-re.patch
|
||||
Patch24: 0007-tdf-137982-m_xFrame-is-already-disposed.patch
|
||||
Patch25: 0008-Resolves-tdf-137215-restore-original-modality-before.patch
|
||||
Patch26: 0001-rhbz-1882616-move-cursor-one-step-at-a-time-in-the-d.patch
|
||||
|
||||
%if 0%{?rhel}
|
||||
# not upstreamed
|
||||
@ -1061,7 +1064,7 @@ SMP_MFLAGS=%{?_smp_mflags}
|
||||
SMP_MFLAGS=$[${SMP_MFLAGS/-j/}]
|
||||
|
||||
%if 0%{?flatpak}
|
||||
%define flatpakoptions --with-boost-libdir=%{_libdir} --with-beanshell-jar=/app/share/java/bsh.jar --with-commons-logging-jar=/app/share/java/commons-logging.jar --with-flute-jar=/app/share/java/flute.jar --with-jfreereport-jar=/app/share/java/flow-engine.jar --with-libbase-jar=/app/share/java/libbase.jar --with-libfonts-jar=/app/share/java/libfonts.jar --with-libformula-jar=/app/share/java/libformula.jar --with-liblayout-jar=/app/share/java/liblayout.jar --with-libloader-jar=/app/share/java/libloader.jar --with-librepository-jar=/app/share/java/librepository.jar --with-libserializer-jar=/app/share/java/libserializer.jar --with-libxml-jar=/app/share/java/libxml.jar --with-sac-jar=/app/share/java/sac.jar FIREBIRDCONFIG=%{_libdir}/fb_config QT4INC=%{_includedir}
|
||||
%define flatpakoptions --with-boost-libdir=%{_libdir} --with-beanshell-jar=/app/share/java/bsh.jar --with-commons-logging-jar=/app/share/java/commons-logging.jar --with-external-dict-dir=/app/share/myspell --with-external-hyph-dir=/app/share/hyphen --with-external-thes-dir=/app/share/mythes --with-flute-jar=/app/share/java/flute.jar --with-jdk-home=/app/lib/jvm/java-1.8.0-openjdk --with-jfreereport-jar=/app/share/java/flow-engine.jar --with-libbase-jar=/app/share/java/libbase.jar --with-libfonts-jar=/app/share/java/libfonts.jar --with-libformula-jar=/app/share/java/libformula.jar --with-liblayout-jar=/app/share/java/liblayout.jar --with-libloader-jar=/app/share/java/libloader.jar --with-librepository-jar=/app/share/java/librepository.jar --with-libserializer-jar=/app/share/java/libserializer.jar --with-libxml-jar=/app/share/java/libxml.jar --with-sac-jar=/app/share/java/sac.jar FIREBIRDCONFIG=%{_libdir}/fb_config QT4INC=%{_includedir}
|
||||
%endif
|
||||
|
||||
# TODO: enable coinmp?
|
||||
@ -1466,6 +1469,7 @@ appstream-util replace-screenshots %{buildroot}%{_datadir}/metainfo/libreoffice-
|
||||
# org.libreoffice.LibreOffice.appdata.xml; first create the single file:
|
||||
solenv/bin/assemble-flatpak-appdata-step1.sh \
|
||||
%{buildroot}%{_datadir}/metainfo/ 0
|
||||
%if 0%{?fedora}
|
||||
# ...then update the screenshots in the single file (see above):
|
||||
appstream-util replace-screenshots \
|
||||
%{buildroot}%{_datadir}/metainfo/org.libreoffice.LibreOffice.appdata.xml \
|
||||
@ -1474,6 +1478,7 @@ appstream-util replace-screenshots \
|
||||
https://raw.githubusercontent.com/hughsie/fedora-appstream/master/screenshots-extra/libreoffice-calc/a.png \
|
||||
https://raw.githubusercontent.com/hughsie/fedora-appstream/master/screenshots-extra/libreoffice-draw/a.png \
|
||||
https://raw.githubusercontent.com/hughsie/fedora-appstream/master/screenshots-extra/libreoffice-impress/a.png
|
||||
%endif
|
||||
# ...then append the original files to the single file:
|
||||
solenv/bin/assemble-flatpak-appdata-step2.sh \
|
||||
%{buildroot}%{_datadir}/metainfo/ %{buildroot}%{_datadir}/metainfo/
|
||||
@ -2246,6 +2251,9 @@ done
|
||||
%{_includedir}/LibreOfficeKit
|
||||
|
||||
%changelog
|
||||
* Wed Feb 03 2021 Caolán McNamara <caolanm@redhat.com> - 1:6.4.7.2-5
|
||||
- Resolves: rhbz#1924619 bad insertion of emoji
|
||||
|
||||
* Mon Nov 09 2020 Caolán McNamara <caolanm@redhat.com> - 1:6.4.7.2-4
|
||||
- Resolves: rhbz#1889801 rebuild for poppler
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user