Bug 412502 - Auto Completion is Broken for Variables in Kate & KWrite
Summary: Auto Completion is Broken for Variables in Kate & KWrite
Status: RESOLVED FIXED
Alias: None
Product: kate
Classification: Applications
Component: general (show other bugs)
Version: 19.08.1
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-01 10:20 UTC by 3ndymion
Modified: 2020-02-11 13:15 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
patch for fix (2.90 KB, patch)
2020-01-31 22:41 UTC, painless roaster
Details

Note You need to log in before you can comment on or make changes to this bug.
Description 3ndymion 2019-10-01 10:20:53 UTC
SUMMARY
Ever since the last update, auto completion no longer works for variables.  It works fine when typing normal words, but not for variables.  For example, if I have 3 variables anywhere in the file, named varONE, varTWO, & varTHREE, I can type "var" anywhere in the file, & the auto completion list will pop up showing the 3 variable names.  However, if I type "$var", or "${var", nothing happens.  The auto completion pop up does not show up.

STEPS TO REPRODUCE
1. Type any variable with the dollar ($) sign.
2. 
3. 

OBSERVED RESULT
The auto completion list does not pop up when typing any variable with the dollar sign.

EXPECTED RESULT
The auto completion list should pop up when typing any variable with the dollar sign.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 5.3.1-arch1-1-ARCH
(available in About System)
KDE Plasma Version: 5.16.5
KDE Frameworks Version: 5.62.0
Qt Version: 5.13.1

ADDITIONAL INFORMATION
Comment 1 RL 2019-12-27 14:36:59 UTC
Same problem in KWrite on Fedora 30.

kwrite: 19.04.2
KDE Frameworks Version: 5.64.0
KDE Plasma Version: 5.15.5
Qt version: 5.12.5
Comment 2 painless roaster 2020-01-20 11:03:12 UTC
Same problem in KWrite / Kate on Fedora 31.
Error is in package kf5-ktexteditor.
Downgrade package (to 5.61) solves the problem.
Comment 3 painless roaster 2020-01-31 22:41:30 UTC
Created attachment 125583 [details]
patch for fix

fix is reversed from broken patch 'improve word completion to use highlighting to detect word boundaries' (25.08.19 11:51)
Comment 4 Christoph Cullmann 2020-02-01 20:19:20 UTC
Git commit 6540dbf180cc2a0a895fe6b85defc467f708e399 by Christoph Cullmann.
Committed on 01/02/2020 at 20:19.
Pushed by cullmann into branch 'master'.

Revert "improve word completion to use highlighting to detect word boundaries"

This reverts commit 8d0f6ff8014cdf32be6410efa184a968ce53525a.

try to fix code completion behavior

this needs more investigations, I assume the string we search for has different boundaries

M  +6    -7    src/completion/katewordcompletion.cpp

https://commits.kde.org/ktexteditor/6540dbf180cc2a0a895fe6b85defc467f708e399
Comment 5 Christoph Cullmann 2020-02-01 20:19:33 UTC
Reverted the change, the other older bug needs more investigations :/
Comment 6 3ndymion 2020-02-11 13:15:14 UTC
Got the reverted fix with the Arch Linux KDE updates yesterday.  Thank you very much for this.  : )