X-Git-Url: https://git.cinelerra-gg.org/git/?p=goodguy%2Fcinelerra.git;a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Ftrackcanvas.C;h=7dbda4e139aee689e986394046e99e83e657bd77;hp=97fe7a27883eb136660f2466c32ac99180e9f6c7;hb=853b81c6d430bd41037984ecc95fd304fd98964e;hpb=017728ea68874203d45b3f16050626d540608e35 diff --git a/cinelerra-5.1/cinelerra/trackcanvas.C b/cinelerra-5.1/cinelerra/trackcanvas.C index 97fe7a27..7dbda4e1 100644 --- a/cinelerra-5.1/cinelerra/trackcanvas.C +++ b/cinelerra-5.1/cinelerra/trackcanvas.C @@ -3663,16 +3663,20 @@ int TrackCanvas::draw_hairline(Auto *auto_keyframe, int color, int show) set_color(color); draw_line(ax, 0, ax, get_h()); + char text[BCSTRLEN]; if( show ) { - char text[BCSTRLEN]; if( auto_keyframe->is_floatauto() ) { FloatAuto *float_auto = (FloatAuto *)auto_keyframe; sprintf(text, "%0.2f", float_auto->get_value()); } - else { + else if( auto_keyframe->is_intauto() ) { IntAuto *int_auto = (IntAuto *)auto_keyframe; sprintf(text, "%d", int_auto->value); } + else + show = 0; + } + if( show ) { int font = MEDIUMFONT; int tw = get_text_width(font, text) + TOOLTIP_MARGIN * 2; int th = get_text_height(font, text) + TOOLTIP_MARGIN * 2;