aboutsummaryrefslogtreecommitdiff
path: root/js/tools/LineTool.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/tools/LineTool.js')
-rwxr-xr-xjs/tools/LineTool.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/js/tools/LineTool.js b/js/tools/LineTool.js
index 89f33a16..d2ee0b43 100755
--- a/js/tools/LineTool.js
+++ b/js/tools/LineTool.js
@@ -268,7 +268,11 @@ exports.LineTool = Montage.create(ShapeTool, {
268 { 268 {
269 strokeMaterial = Object.create(MaterialsModel.getMaterial(strokeM)); 269 strokeMaterial = Object.create(MaterialsModel.getMaterial(strokeM));
270 } 270 }
271 strokeColor = ShapesController.getMaterialColor(strokeM) || strokeColor; 271 if (strokeMaterial && this.options.stroke.color && (strokeMaterial.gradientType === this.options.stroke.color.gradientMode)) {
272 strokeColor = {gradientMode:strokeMaterial.gradientType, color:this.options.stroke.color.stops};
273 } else {
274 strokeColor = ShapesController.getMaterialColor(strokeM) || strokeColor;
275 }
272 } 276 }
273 277
274 var world = this.getGLWorld(canvas, this.options.use3D); 278 var world = this.getGLWorld(canvas, this.options.use3D);