Add a debug mode that filters level tag values

Authored by mnafees on Jul 24 2017, 6:07 PM.

Diff Detail

R34 Marble
Lint Skipped
Unit Tests Skipped
nienhueser added inline comments.Jul 30 2017, 6:04 AM
944 ↗(On Diff #17133)

I think it would be better to check that Qt::ControlModifier is not checked, same below.

688 ↗(On Diff #17133)

I'd go for setDebugLevelTag(int) and int debugLevelTag() for consistency

255 ↗(On Diff #17133)

layerItems grows large and a cast takes some time, so I'd optimize this a bit for performance: Keep the original loop as-is and add a second one in case d->m_levelTagsDebugModeEnabled is true, sth like

if (d->m_levelTagsDebugModeEnabled) {
  for (auto item: layerItems) {
257 ↗(On Diff #17133)

Can't we get rid of this check and instead check that the iterator is valid below?

689 ↗(On Diff #17133)

Why not keep the last one?
Also, is a repaint needed?

nienhueser requested changes to this revision.Jul 30 2017, 6:04 AM
This revision now requires changes to proceed.Jul 30 2017, 6:04 AM
mnafees updated this revision to Diff 17434.Jul 31 2017, 5:08 PM
mnafees edited edge metadata.
nienhueser accepted this revision.Jul 31 2017, 6:42 PM
This revision is now accepted and ready to land.Jul 31 2017, 6:42 PM