X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=pv%2Fviews%2Fdecoder_output%2FQHexView.hpp;h=c3004c5c59d07aa7040589b688f9e36b4e26616e;hb=13b726cda35835a120ade2d9cc1ab58770d4ef3f;hp=b5fb01fb51ba6dfb7a16c17222645cd9b34cb04f;hpb=628b45cc0ba7ac38ac6a003fedbbc746f15dd724;p=pulseview.git diff --git a/pv/views/decoder_output/QHexView.hpp b/pv/views/decoder_output/QHexView.hpp index b5fb01fb..c3004c5c 100644 --- a/pv/views/decoder_output/QHexView.hpp +++ b/pv/views/decoder_output/QHexView.hpp @@ -34,6 +34,7 @@ #include +using std::pair; using std::size_t; using pv::data::DecodeBinaryClass; using pv::data::DecodeBinaryDataChunk; @@ -56,6 +57,9 @@ public: void clear(); void showFromOffset(size_t offset); + virtual QSizePolicy sizePolicy() const; + + pair get_selection() const; protected: void initialize_byte_iterator(size_t offset); @@ -84,8 +88,10 @@ private: size_t charWidth_, charHeight_; size_t selectBegin_, selectEnd_, selectInit_, cursorPos_; - size_t current_chunk_id_, current_chunk_offset_; - const DecodeBinaryDataChunk* current_chunk_; + size_t current_chunk_id_, current_chunk_offset_, current_offset_; + DecodeBinaryDataChunk current_chunk_; // Cache locally so that we're not messed up when the vector is re-allocating its data + + vector chunk_colors_; }; #endif /* PULSEVIEW_PV_VIEWS_DECODEROUTPUT_QHEXVIEW_H */