Created attachment 160948 [details] screenshot showing the problem SUMMARY The git diff view of Kate marks (a) lines with a change with a light color tone and (b) words with a change within that line with a stronger color tone. However, that background color for (b) words increasingly to low with the number of softbreaks in that line. While words before the first softbreak are vertically well aligned, the background color mark after several soft breaks is too low and even placed under the actual line. STEPS TO REPRODUCE 1. create a git repository with some random text in file test.md 2. commit that test.md 2. change a word at the end of a very long line in test.md 3. view the git diff of test.md in Kate and check the word diff color background Additional info: I use as font JetBrains Mono (https://www.jetbrains.com/lp/mono/)
Hi, can you share the text files that you used?
Created attachment 160949 [details] test.md that I commited first
Created attachment 160950 [details] test.md with some changes to reproduce the problem in kate diff view
Git commit d6f41fea4db80b8b1dc47b1ee240756febb53f5f by Waqar Ahmed. Committed on 14/08/2023 at 16:40. Pushed by waqar into branch 'master'. Use QFontMetrics::lineSpacing to calculate the line y offset M +2 -2 apps/lib/diff/diffeditor.cpp https://invent.kde.org/utilities/kate/-/commit/d6f41fea4db80b8b1dc47b1ee240756febb53f5f
Git commit 705aaac1b8624f529049af6e18a9c76d725237b0 by Waqar Ahmed. Committed on 14/08/2023 at 16:41. Pushed by waqar into branch 'release/23.08'. Use QFontMetrics::lineSpacing to calculate the line y offset (cherry picked from commit d6f41fea4db80b8b1dc47b1ee240756febb53f5f) M +2 -2 apps/lib/diff/diffeditor.cpp https://invent.kde.org/utilities/kate/-/commit/705aaac1b8624f529049af6e18a9c76d725237b0