X-Git-Url: http://git.code-monkey.de/?a=blobdiff_plain;f=pv%2Fview%2Fview.hpp;h=8ef8812cf5443aaaf1553343eeda27df6b77073b;hb=8a5fd81fea577663e8c0f17e53d5928599d0926d;hp=aebc25401bb85d34cad008e28c99fa0104c8dce3;hpb=cafe470ed977ab3bff1a865439a261c9f0eb397d;p=pulseview.git diff --git a/pv/view/view.hpp b/pv/view/view.hpp index aebc254..8ef8812 100644 --- a/pv/view/view.hpp +++ b/pv/view/view.hpp @@ -29,11 +29,10 @@ #include #include -#include #include -#include #include +#include #include "cursorpair.hpp" #include "flag.hpp" @@ -54,6 +53,10 @@ namespace pv { class Session; +namespace data { +class Logic; +} + namespace views { namespace TraceView { @@ -67,7 +70,8 @@ class Trace; class Viewport; class TriggerMarker; -class CustomAbstractScrollArea : public QAbstractScrollArea { +class CustomAbstractScrollArea : public QAbstractScrollArea +{ Q_OBJECT public: @@ -76,7 +80,8 @@ public: bool viewportEvent(QEvent *event); }; -class View : public ViewBase, public TraceTreeItemOwner { +class View : public ViewBase, public TraceTreeItemOwner +{ Q_OBJECT private: @@ -90,7 +95,6 @@ private: static const pv::util::Timestamp MinScale; static const int MaxScrollValue; - static const int MaxViewAutoUpdateRate; static const int ScaleUnits[3]; @@ -107,7 +111,7 @@ public: virtual void clear_signals(); - virtual void add_signal(const shared_ptr signal); + void add_signal(const shared_ptr signal); #ifdef ENABLE_DECODE virtual void clear_decode_signals(); @@ -210,11 +214,21 @@ public: */ void enable_coloured_bg(bool state); + /** + * Returns true if the trace background should be drawn with a coloured background. + */ + bool coloured_bg() const; + /** * Enable or disable showing sampling points. */ void enable_show_sampling_points(bool state); + /** + * Enable or disable showing the analog minor grid. + */ + void enable_show_analog_minor_grid(bool state); + /** * Returns true if cursors are displayed. false otherwise. */ @@ -301,6 +315,8 @@ private: */ void calculate_tick_spacing(); + void adjust_top_margin(); + void update_scroll(); void reset_scroll(); @@ -340,9 +356,8 @@ private Q_SLOTS: void signals_changed(); void capture_state_updated(int state); - void data_updated(); - void perform_delayed_view_update(); + virtual void perform_delayed_view_update(); void process_sticky_events(); @@ -407,7 +422,6 @@ private: bool sticky_scrolling_; bool coloured_bg_; bool always_zoom_to_fit_; - QTimer delayed_view_updater_; pv::util::Timestamp tick_period_; pv::util::SIPrefix tick_prefix_; @@ -432,8 +446,6 @@ private: // A nonzero value indicates the v offset to restore. See View::resizeEvent() int saved_v_offset_; - - bool size_finalized_; }; } // namespace TraceView