add knewstuff support for color schemes
ClosedPublic

Authored by sitter on Feb 23 2018, 12:47 PM.

Details

Summary
  • new manager helpers to unload a theme and check a file's name validity
  • new Get New.. button to start the KNS download dialog
  • upon KNS completion we'll attempt to load all installed files as schemes
  • for KNS entities which failed to load anything we'll show a warning as the theme is malformed
  • for removal we'll first try to remove schemes through KNS to avoid its registry going out of sync with the on-disk "installedness" of an entity
  • properly disable copying of the scheme manager (needs to be private)

FEATURE: 18.04.0
CHANGELOG: Support for downloading color schemes from the KDE store

Test Plan

category doesn't exist yet (T8053) KDE Color Scheme KDE4 can be used in combination with searching for konsole.

  • get new -> install scheme -> close -> shows up in list
  • remove from list -> get new -> not listed as installed
  • install random stuff from kde color scheme category -> close -> warning should be displayed
  • install scheme -> get new -> remove scheme via dialog -> close -> not listed as installed

Diff Detail

Repository
R319 Konsole
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
sitter created this revision.Feb 23 2018, 12:47 PM
Restricted Application added a project: Konsole. · View Herald TranscriptFeb 23 2018, 12:47 PM
Restricted Application added a subscriber: Konsole. · View Herald Transcript
sitter requested review of this revision.Feb 23 2018, 12:47 PM

What do I need to do to test this? I see T8053 was committed.

I get : "konsole.knsrc" doesn't contain a KNewStuff3 section.

kf5.kwidgetsaddons: Invalid framesize.
kf5.kwidgetsaddons: No frame loaded
kf5.kwidgetsaddons: No frame loaded
kf5.kwidgetsaddons: No frame loaded
"konsole.knsrc" doesn't contain a KNewStuff3 section.

sitter added a comment.EditedFeb 26 2018, 11:36 AM

Are you sure wherever you install konsole has the XDG_* env vars set up properly?

Namely konsole.knsrc needs to be in XDG_CONFIG_DIRS (defaults to /etc/xdg/) or XDG_CONFIG_HOME (defaults to $HOME/.config/)

OK yea it works now after adjusting the XDG variables - LGTM

hindenburg accepted this revision.Feb 27 2018, 2:46 PM
This revision is now accepted and ready to land.Feb 27 2018, 2:46 PM

Do you want me to commit this? Perhaps change the commit message to show the opendesktop cat?

This revision was automatically updated to reflect the committed changes.