Show application window icon on AboutPage
AcceptedPublic

Authored by caspermeijn on Sun, Aug 18, 10:48 AM.

Details

Reviewers
mart
apol
hein
Group Reviewers
Kirigami
Summary

With this it is not nessecary to KAboutData::setProgramLogo. If the
QApplication::setWindowIcon is set, then the AboutPage will
automatically use that icon.

Test Plan

Tested with Discover, with only setWindowIcon, only setProgramLogo and
both setWindowIcon and setProgramLogo

Diff Detail

Repository
R169 Kirigami
Branch
about_icon (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 15591
Build 15609: arc lint + arc unit
caspermeijn created this revision.Sun, Aug 18, 10:48 AM
Restricted Application added a project: Kirigami. · View Herald TranscriptSun, Aug 18, 10:48 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
caspermeijn requested review of this revision.Sun, Aug 18, 10:48 AM

I am not sure about the version numbers and the return type. Did I choose the correct ones?

ngraham added a subscriber: ngraham.
ngraham added inline comments.
src/settings.h
79

2.10 actually (this is super confusing, I know)

apol added a comment.Sun, Aug 18, 10:51 PM

+1 LGTM, please address the @since bit

src/settings.h
81

It could make sense to include the REVISION part:
https://doc.qt.io/qt-5/properties.html

hein accepted this revision.Mon, Aug 19, 2:39 AM
This revision is now accepted and ready to land.Mon, Aug 19, 2:39 AM
hein added a comment.EditedMon, Aug 19, 2:48 AM

I was looking into this recently and added the component name getter, which does the trick for me and is much nicer to use than setting the program logo. So in some sense this is not strictly necessary, and also it would really be better if the window icon was part of the Qt.application upstream API in QML. It's still an okay workaround though. Let's see what Marco thinks.

Fixed since version number

caspermeijn marked an inline comment as done.Sat, Aug 24, 7:57 PM
caspermeijn added inline comments.
src/settings.h
81

I have no idea what the value would be for that and Kirigami doesn't have any example.

sitter added a subscriber: sitter.Mon, Aug 26, 9:19 AM
sitter added inline comments.
src/settings.h
81

https://doc.qt.io/qt-5/qtqml-cppintegration-definetypes.html#type-revisions-and-versions

tldr:

  • add REVISON 10 to property
  • change krigiamiplugin.cpp to register that revision

I am not sure how that would work for a singletontype though, one always needs all properties since any revision may be used at any time.
@apol are you sure this makes sense for singletons?

This comment was removed by bcooksley.
bcooksley removed a subscriber: fsitter.