commit:     ef046fe8816403b63d3da9cb8c04f6bd3260803b
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Sun Aug 16 16:11:52 2020 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Sun Aug 16 16:24:10 2020 +0000
URL:        https://gitweb.gentoo.org/proj/kde-sunset.git/commit/?id=ef046fe8

kde-apps/katepart: gcc7 compat

Thanks-to: Tommy Yu <y <AT> metatoaster.com>
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 kde-apps/katepart/files/katepart-4.14.3-gcc7.patch | 13 +++++++++++++
 kde-apps/katepart/katepart-4.14.3.ebuild           |  2 ++
 2 files changed, 15 insertions(+)

diff --git a/kde-apps/katepart/files/katepart-4.14.3-gcc7.patch 
b/kde-apps/katepart/files/katepart-4.14.3-gcc7.patch
new file mode 100644
index 00000000..b6a87a90
--- /dev/null
+++ b/kde-apps/katepart/files/katepart-4.14.3-gcc7.patch
@@ -0,0 +1,13 @@
+diff --git a/part/view/kateviewhelpers.cpp b/part/view/kateviewhelpers.cpp
+index 8ad8771..cdeced3 100644
+--- a/part/view/kateviewhelpers.cpp
++++ b/part/view/kateviewhelpers.cpp
+@@ -1703,7 +1703,7 @@ void KateIconBorder::paintBorder (int /*x*/, int y, int 
/*width*/, int height)
+       if (realLine > -1) {
+         if (m_viewInternal->cache()->viewLine(z).startCol() == 0) {
+           if (m_viRelLineNumbersOn && m_view->viInputMode()) {
+-            int diff = abs(realLine - currentLine);
++            int diff = abs(realLine - (int)currentLine);
+             if (diff > 0) {
+               p.drawText( lnX + m_maxCharWidth / 2, y, lnWidth - 
m_maxCharWidth, h,
+                           Qt::TextDontClip|Qt::AlignRight|Qt::AlignVCenter, 
QString("%1").arg(diff) );

diff --git a/kde-apps/katepart/katepart-4.14.3.ebuild 
b/kde-apps/katepart/katepart-4.14.3.ebuild
index 5ad58a89..050dec04 100644
--- a/kde-apps/katepart/katepart-4.14.3.ebuild
+++ b/kde-apps/katepart/katepart-4.14.3.ebuild
@@ -19,3 +19,5 @@ RESTRICT="test"
 KMEXTRA="
        addons/ktexteditor
 "
+
+PATCHES=( "${FILESDIR}/${PN}-4.14.3-gcc7.patch" )

Reply via email to