From c76582f92f4686dff929bff706b24eb5d1058e78 Mon Sep 17 00:00:00 2001 From: timb Date: Sun, 13 Mar 2016 17:42:28 -0700 Subject: fix painting from brush cells with text and trans bg. renamed lex paint to lex stamp to match draw.js --- js/lex.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'js/lex.js') diff --git a/js/lex.js b/js/lex.js index 8a6d248..70dd2bf 100644 --- a/js/lex.js +++ b/js/lex.js @@ -65,10 +65,9 @@ Lex.prototype.assign = function (lex){ this.opacity = lex.opacity this.build() } -Lex.prototype.paint = function (lex){ - if (lex.opacity == 0) return +Lex.prototype.stamp = function (lex, brush){ if (brush.draw_fg) this.fg = lex.fg - if (brush.draw_bg) this.bg = lex.bg + if (brush.draw_bg && lex.opacity > 0) this.bg = lex.bg if (brush.draw_char) this.char = lex.char this.opacity = 1 this.build() -- cgit v1.2.3-70-g09d2