X-Git-Url: https://sigrok.org/gitweb/?p=pulseview.git;a=blobdiff_plain;f=pv%2Fview%2Fdecode%2Fannotation.h;h=091cd26004acee80fea8eb45baf86cb5a181983e;hp=4e24121c50622923e5b0284cc8bd475a777d9261;hb=ea47a30c748939c334dfdbb8215e52a53204f5e6;hpb=3195aeb6a867b6ab54b4a410182467f63f9b79f2;ds=sidebyside diff --git a/pv/view/decode/annotation.h b/pv/view/decode/annotation.h index 4e24121c..091cd260 100644 --- a/pv/view/decode/annotation.h +++ b/pv/view/decode/annotation.h @@ -33,9 +33,25 @@ namespace decode { class Annotation { +private: + static const double EndCapWidth; + static const int DrawPadding; + public: Annotation(const srd_proto_data *const pdata); + void paint(QPainter &p, QColor fill, QColor outline, + QColor text_colour, int text_height, int left, int right, + double samples_per_pixel, double pixels_offset, int y); + +private: + void draw_instant(QPainter &p, QColor fill, QColor outline, + QColor text_color, int h, double x, int y); + + void draw_range(QPainter &p, QColor fill, QColor outline, + QColor text_color, int h, double start, + double end, int y); + private: uint64_t _start_sample; uint64_t _end_sample;