mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 11:40:06 +02:00
lyx: fix for Qt 5.8.
This commit is contained in:
@@ -15,10 +15,11 @@ cross-referenced PDF, just as readily produced - looks like nothing else."
|
||||
HOMEPAGE="http://www.lyx.org"
|
||||
LICENSE="GNU GPL v2"
|
||||
COPYRIGHT="the lyx community"
|
||||
REVISION="2"
|
||||
REVISION="3"
|
||||
SOURCE_URI="ftp://ftp.lyx.org/pub/lyx/stable/2.2.x/lyx-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="7f6a0aeeeb7e9b1405e27394d1b7192e4abebba2491e5d0ffc6a4cb993803a45"
|
||||
ADDITIONAL_FILES="lyx.rdef.in"
|
||||
PATCHES="lyx-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="?x86_gcc2 ?x86 x86_64"
|
||||
SECONDARY_ARCHITECTURES="?x86"
|
||||
|
||||
30
app-office/lyx/patches/lyx-2.2.2.patchset
Normal file
30
app-office/lyx/patches/lyx-2.2.2.patchset
Normal file
@@ -0,0 +1,30 @@
|
||||
From 40dd98fb1c46e0b9773ff4448d863425c80cdcce Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Fri, 7 Apr 2017 19:20:49 +0200
|
||||
Subject: upstream fix for qt 5.8
|
||||
|
||||
|
||||
diff --git a/src/frontends/qt4/GuiViewSource.cpp b/src/frontends/qt4/GuiViewSource.cpp
|
||||
index d583897..60792dc 100644
|
||||
--- a/src/frontends/qt4/GuiViewSource.cpp
|
||||
+++ b/src/frontends/qt4/GuiViewSource.cpp
|
||||
@@ -219,14 +219,9 @@ void ViewSourceWidget::realUpdateView()
|
||||
if (changed && !texrow_.get()) {
|
||||
// position-to-row is unavailable
|
||||
// we jump to the first modification
|
||||
- const QChar * oc = old.constData();
|
||||
- const QChar * nc = qcontent.constData();
|
||||
+ int length = min(old.length(), qcontent.length());
|
||||
int pos = 0;
|
||||
- while (*oc != '\0' && *nc != '\0' && *oc == *nc) {
|
||||
- ++oc;
|
||||
- ++nc;
|
||||
- ++pos;
|
||||
- }
|
||||
+ for (; pos < length && old.at(pos) == qcontent.at(pos); ++pos) {}
|
||||
QTextCursor c = QTextCursor(viewSourceTV->document());
|
||||
//get some space below the cursor
|
||||
c.setPosition(pos);
|
||||
--
|
||||
2.11.0
|
||||
|
||||
Reference in New Issue
Block a user