Closed marco-nembrot closed 8 years ago
Do you have a sample? updateSettings does not change colors or width of existing strokes, it sets it for future strokes.
On Fri, Oct 10, 2014 at 3:33 AM, NEMBROT Isabelle notifications@github.com wrote:
Trying to use "updateSetting" to change on live settings like line width or the pen color. I tried var $sigdiv = $("#signature").jSignature(); $sigdiv.jSignature("updateSetting", "lineWidth", 100, true); $sigdiv.jSignature.updateSetting("lineWidth", 100, true); $sigdiv.jSignature("updateSettings", "lineWidth", "100", true);
but nothing seems to work. What do I miss ? Thanks for replying.
Z.
— Reply to this email directly or view it on GitHub https://github.com/brinley/jSignature/issues/69.
Brinley Ang Software Developer & Consultant http://www.unbolt.net
Thanks for answering that fast ! Here my sample. I did understand that the changes are made for the future strokes which is exactly what I want. Users should have the choice of changing settings if the default does not go with them.
var $sigdiv = $("#signature").jSignature({ "UndoButton" : true, "showUndoButton": true, "height" : "100%", "width" : "100%", "signatureLine" : false }); $("#canvas-width").on("click", function(e) { $sigdiv.jSignature("updateSetting", "lineWidth", 100, true); });
Sorry for the late response, try this instead
$("#canvas-width").on("click", function(e) { $("#signature").jSignature("updateSetting", "lineWidth", 100, true); });
On Mon, Oct 13, 2014 at 6:42 PM, NEMBROT Isabelle notifications@github.com wrote:
Thanks for answering that fast ! Here my sample. I did understand that the changes are made for the future strokes which is exactly what I want. Users should have the choice of changing settings if the default does not go with them.
var $sigdiv = $("#signature").jSignature({ "UndoButton" : true, "showUndoButton": true, "height" : "100%", "width" : "100%", "signatureLine" : false }); $("#canvas-width").on("click", function(e) { $sigdiv.jSignature("updateSetting", "lineWidth", 100, true); });
— Reply to this email directly or view it on GitHub https://github.com/brinley/jSignature/issues/69#issuecomment-58856887.
Brinley Ang Software Developer & Consultant http://www.unbolt.net
Trying to use "updateSetting" to change on live settings like line width or the pen color. I tried var $sigdiv = $("#signature").jSignature(); $sigdiv.jSignature("updateSetting", "lineWidth", 100, true); $sigdiv.jSignature.updateSetting("lineWidth", 100, true); $sigdiv.jSignature("updateSettings", "lineWidth", "100", true);
but nothing seems to work. What do I miss ? Thanks for replying.
Z.