Skip to content

Commit 559c4fd

Browse files
authored
Merge pull request u2takey#63 from BubbaJoe/patch-1
Only escape when the text is not empty
2 parents 2ac7dbe + 2e1001f commit 559c4fd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

filters.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ func (s *Stream) DrawBox(x, y, w, h int, color string, thickness int, kwargs ...
8585
func (s *Stream) Drawtext(text string, x, y int, escape bool, kwargs ...KwArgs) *Stream {
8686
AssertType(s.Type, "FilterableStream", "drawtext")
8787
args := MergeKwArgs(kwargs)
88-
if escape {
88+
if escape && text != "" {
8989
text = fmt.Sprintf("%q", text)
9090
}
9191
if text != "" {

0 commit comments

Comments
 (0)