- verticalScrollBar()->setRange(0,
- _viewport->get_total_height() + SignalMargin -
- areaSize.height());
+ verticalScrollBar()->setSingleStep(areaSize.height() / 8);
+
+ const pair<int, int> extents = v_extents();
+ verticalScrollBar()->setRange(extents.first - (areaSize.height() / 2),
+ extents.second - (areaSize.height() / 2));
+}
+
+void View::update_layout()
+{
+ setViewportMargins(
+ header_->sizeHint().width() - pv::view::Header::BaselineOffset,
+ ruler_->sizeHint().height(), 0, 0);
+ ruler_->setGeometry(viewport_->x(), 0,
+ viewport_->width(), ruler_->extended_size_hint().height());
+ header_->setGeometry(0, viewport_->y(),
+ header_->extended_size_hint().width(), viewport_->height());
+ update_scroll();
+}
+
+void View::paint_label(QPainter &p, const QRect &rect, bool hover)
+{
+ (void)p;
+ (void)rect;
+ (void)hover;
+}
+
+QRectF View::label_rect(const QRectF &rect)
+{
+ (void)rect;
+ return QRectF();