]> sigrok.org Git - pulseview.git/commit
Remove Header::BaselineOffset and move arrows as needed instead
authorSoeren Apel <redacted>
Thu, 1 Jun 2017 19:16:27 +0000 (21:16 +0200)
committerUwe Hermann <redacted>
Fri, 2 Jun 2017 11:37:02 +0000 (13:37 +0200)
commitc1a6513b912e90ebcca2dba4453aa03fbddcfb58
treef5f26490057e32b525f4f29d053e6a3bdf06d1dc
parent33094993339188a3baef302fb09eff6bf6bb6779
Remove Header::BaselineOffset and move arrows as needed instead

The baseline offset was used to keep 5px of distance between
the tip of the arrow and the scroll area. This way, the shadow
that is drawn around the arrow when it's selected won't get
cropped.
However, we can do this differently: instead of always keeping
the empty space around, we make the arrows align at the edge
of the widget space as they should and when they're selected,
we push them aside to the left so the shadow can still be
painted without cropping.

Logically, one would assume that the arrow's label also should
be moving left but I decided against it because this way it
looks as if the arrow didn't actually move, keeping all arrow
labels lined up.
pv/view/header.cpp
pv/view/header.hpp
pv/view/trace.cpp
pv/view/view.cpp