This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Broken KDevelop color scheme?

Tags: None
(comma "," separated)
paulinia
Registered Member
Posts
8
Karma
0

Broken KDevelop color scheme?

Mon Feb 04, 2019 11:47 pm
Did KDevelop suddenly change color scheme (I hope not) or is there something wrong with my settings?
KDevelop recently stopped coloring variables (and now only colors keywords). I tried to reset config by deleting the file, but it didn't help, and all variables stayed blandly white. What can possibly be the issue?
flherne
Registered Member
Posts
23
Karma
0

Re: Broken KDevelop color scheme?

Tue Feb 05, 2019 12:34 am
This isn't directly related to the colour scheme.

Variables etc. are highlighted using information from the background parser. This also powers the info tooltips, jump-to-definition, 'Show Uses' and many other KDevelop features.

If nothing's highlighted, it means the background parser didn't successfully parse the file. There are many reasons why that can happen; some examples:

- Not a supported language (unlikely in this case, I assume).
- Plugin for the language isn't installed (e.g. kdev-python is usually a separate package).
- Plugin for the language can't load due to a missing dependency (e.g. https://bugs.kde.org/show_bug.cgi?id=400882)

- Syntax or other code error in the file.
- (for C++) An error in some #included file.
- Include paths not set correctly. For supported buildsystems KDevelop should read those; otherwise they must be set manually in the project settings.
- Required libraries/headers for the project aren't installed on the system.

- KDevelop bug of some kind.

Try looking at the "Problems" toolview - many of the issues above will cause the parser to report a problem. If nothing is shown, set "Scope: Current Project".

If that doesn't help, run `QT_LOGGING_RULES="kdev*=true" kdevelop --pick-session` in a terminal, load the affected project and watch the output spam for any interesting errors.

Good luck!
User avatar
scummos
Global Moderator
Posts
1175
Karma
7
OS

Re: Broken KDevelop color scheme?

Tue Feb 05, 2019 10:56 am
"Help -> Loaded Plugins" should list a plugin specifically for the language you are using. Check if that is the case.


I'm working on the KDevelop IDE.
paulinia
Registered Member
Posts
8
Karma
0

Re: Broken KDevelop color scheme?

Tue Feb 05, 2019 4:25 pm
After running KDEV_CLANG_DISPLAY_DIAGS=1 kdevelop, it seems that KDEvelop can't find the parser, as it loads it from clang/7.0.0 whereas my version is 7.0.1. Where should I fix the path to the parser?
flherne
Registered Member
Posts
23
Karma
0

Re: Broken KDevelop color scheme?

Tue Feb 05, 2019 4:51 pm
You have (or your distribution has) upgraded libclang without rebuilding KDevelop.

There has been a recent patch (https://phabricator.kde.org/D17858) to allow KDevelop to work in this case, but it isn't yet in a released version - it's in the 5.3 and master git branches, so 5.3.2 and 5.4.0 will include it.

You'll have to rebuild KDevelop. Note that changing dependency versions without a rebuild isn't supported in general despite the patch above; that's just a workaround for a particularly common case.

What distro are you using? I know Gentoo users have encountered this before, it would be worrying if any of the binary-package distributions had this problem.
User avatar
scummos
Global Moderator
Posts
1175
Karma
7
OS

Re: Broken KDevelop color scheme?

Wed Feb 06, 2019 6:54 pm
The binary distros often don't have the dependency versions right. So, if you for example install kdevelop, then three weeks later update clang, you could easily get into the described situation.


I'm working on the KDevelop IDE.


Bookmarks



Who is online

Registered users: bancha, Bing [Bot], Evergrowing, Google [Bot], lockheed, mesutakcan, Sogou [Bot]