Add warning and error icons in the current document icon border
Needs RevisionPublic

Authored by arichardson on Apr 4 2016, 12:33 PM.

Details

Reviewers
mwolff
kfunk
Summary

KTextEditor doesn't have a default icon pixmap set for any of the mark
types (including the predefined types such as MarkInterface::Warning).
Setting the pixmap manually makes the icon appear on the icon border.

Test Plan

Icon border now shows Warning/Error icon

Diff Detail

Repository
R33 KDevPlatform
Branch
5.0
Lint
No Linters Available
Unit
No Unit Test Coverage
arichardson updated this revision to Diff 3125.Apr 4 2016, 12:33 PM
arichardson retitled this revision from to Add warning and error icons in the current document icon border.
arichardson updated this object.
arichardson edited the test plan for this revision. (Show Details)
arichardson added reviewers: kfunk, mwolff.
Restricted Application added a subscriber: kdevelop-devel. · View Herald TranscriptApr 4 2016, 12:33 PM
kfunk edited edge metadata.Apr 4 2016, 3:25 PM

Food for thought: Do we actually want border icons for warnings/errors/etc?

IMO there's enough visual "clutter" already, which makes you aware of problems in code. (Thinking of underlines, different bg color (optional), etc.)

kfunk added a comment.Apr 8 2016, 6:02 PM

Other opinions?

kfunk requested changes to this revision.Jun 14 2016, 4:23 PM
kfunk edited edge metadata.
This revision now requires changes to proceed.Jun 14 2016, 4:23 PM
mwolff edited edge metadata.Feb 18 2017, 10:35 PM

For errors and warnings, I think it's a good idea to show the pixmap. But does this deal nicely with breakpoints? I.e. the breakpoint icon should always take precedence over the warning/error pixmaps

In D1313#87461, @mwolff wrote:

For errors and warnings, I think it's a good idea to show the pixmap. But does this deal nicely with breakpoints? I.e. the breakpoint icon should always take precedence over the warning/error pixmaps

Looking at https://code.woboq.org/qt5/kf5/ktexteditor/src/view/kateviewhelpers.cpp.html#1669 it seems like error will be rendered over breakpoint. We could work around this by using a larger value than MarkInterface::Error for breakpoints?

sorry for the long delay.

picking up the discussion: I'd be OK with that workaround. In general, how do other IDEs handle this scenario, with an issue and a breakpoint in the same line? Also, do we get a proper tooltip when hovering the icons?