forked from bartvdbraak/blender
Sequencer: optionally show strip offsets
was disabled in recent sequencer refactor, enable with view menu option.
This commit is contained in:
parent
17f0a01a56
commit
117a7e3545
@ -198,6 +198,7 @@ class SEQUENCER_MT_view(Menu):
|
||||
if st.view_type in {'SEQUENCER', 'SEQUENCER_PREVIEW'}:
|
||||
layout.prop(st, "show_seconds")
|
||||
layout.prop(st, "show_frame_indicator")
|
||||
layout.prop(st, "show_strip_offset")
|
||||
|
||||
if st.view_type in {'PREVIEW', 'SEQUENCER_PREVIEW'}:
|
||||
if st.display_mode == 'IMAGE':
|
||||
|
@ -669,7 +669,7 @@ void draw_sequence_extensions(Scene *scene, ARegion *ar, Sequence *seq)
|
||||
draw_shadedstrip(seq, col, x1, y1, (float)(seq->start), y2);
|
||||
|
||||
/* feint pinstripes, helps see exactly which is extended and which isn't,
|
||||
* especially when the extension is very small */
|
||||
* especially when the extension is very small */
|
||||
if (seq->flag & SELECT) UI_GetColorPtrBlendShade3ubv(col, col, col, 0.0, 24);
|
||||
else UI_GetColorPtrShade3ubv(col, col, -16);
|
||||
|
||||
@ -687,7 +687,7 @@ void draw_sequence_extensions(Scene *scene, ARegion *ar, Sequence *seq)
|
||||
draw_shadedstrip(seq, col, (float)(seq->start + seq->len), y1, x2, y2);
|
||||
|
||||
/* feint pinstripes, helps see exactly which is extended and which isn't,
|
||||
* especially when the extension is very small */
|
||||
* especially when the extension is very small */
|
||||
if (seq->flag & SELECT) UI_GetColorPtrShade3ubv(col, col, 24);
|
||||
else UI_GetColorPtrShade3ubv(col, col, -16);
|
||||
|
||||
@ -736,6 +736,10 @@ static void draw_seq_strip(const bContext *C, SpaceSeq *sseq, Scene *scene, AReg
|
||||
draw_shadedstrip(seq, background_col, x1, y1, x2, y2);
|
||||
}
|
||||
|
||||
if ((sseq->draw_flag & SEQ_DRAW_OFFSET_EXT) && !is_single_image) {
|
||||
draw_sequence_extensions(scene, ar, seq);
|
||||
}
|
||||
|
||||
draw_seq_handle(v2d, seq, handsize_clamped, SEQ_LEFTHANDLE);
|
||||
draw_seq_handle(v2d, seq, handsize_clamped, SEQ_RIGHTHANDLE);
|
||||
|
||||
|
@ -518,6 +518,7 @@ typedef enum eSpaceSeq_RegionType {
|
||||
/* sseq->draw_flag */
|
||||
typedef enum eSpaceSeq_DrawFlag {
|
||||
SEQ_DRAW_BACKDROP = (1 << 0),
|
||||
SEQ_DRAW_OFFSET_EXT = (1 << 1),
|
||||
} eSpaceSeq_DrawFlag;
|
||||
|
||||
|
||||
|
@ -2630,6 +2630,11 @@ static void rna_def_space_sequencer(BlenderRNA *brna)
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "draw_flag", SEQ_DRAW_BACKDROP);
|
||||
RNA_def_property_ui_text(prop, "Use Backdrop", "Display result under strips");
|
||||
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_SEQUENCER, NULL);
|
||||
|
||||
prop = RNA_def_property(srna, "show_strip_offset", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "draw_flag", SEQ_DRAW_OFFSET_EXT);
|
||||
RNA_def_property_ui_text(prop, "Show Offsets", "Display strip in/out offsets");
|
||||
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_SEQUENCER, NULL);
|
||||
}
|
||||
|
||||
static void rna_def_space_text(BlenderRNA *brna)
|
||||
|
Loading…
Reference in New Issue
Block a user