]> sigrok.org Git - pulseview.git/commitdiff
CursorPair: Simplified label_rect
authorJoel Holdsworth <redacted>
Sat, 20 Dec 2014 17:51:13 +0000 (17:51 +0000)
committerJoel Holdsworth <redacted>
Sun, 28 Dec 2014 18:52:53 +0000 (18:52 +0000)
pv/view/cursorpair.cpp

index c3753e6560707cbeacd132e4b94140a7a9455c28..5df658dbf31cdff74cc9f789552634d75db50dc0 100644 (file)
@@ -84,9 +84,7 @@ pv::widgets::Popup* CursorPair::create_popup(QWidget *parent)
 
 QRectF CursorPair::label_rect(const QRectF &rect) const
 {
-       const QSizeF label_size(
-               text_size_.width() + LabelPadding.width() * 2,
-               text_size_.height() + LabelPadding.height() * 2);
+       const QSizeF label_size(text_size_ + LabelPadding * 2);
        const pair<float, float> offsets(get_cursor_offsets());
        const pair<float, float> normal_offsets(
                (offsets.first < offsets.second) ? offsets :