From 3f54e9d5e22e3ec18a23a8d09e6cd603cf313979 Mon Sep 17 00:00:00 2001 From: Alexis Deveria Date: Wed, 9 Mar 2011 18:55:48 +0000 Subject: [PATCH] Fixed Issue 784: Allow extensions to set font color git-svn-id: http://svg-edit.googlecode.com/svn/trunk@2027 eee81c28-f429-11dd-99c0-75d572ba1ddd --- editor/svgcanvas.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/editor/svgcanvas.js b/editor/svgcanvas.js index edf5c9f8..39ee8e81 100644 --- a/editor/svgcanvas.js +++ b/editor/svgcanvas.js @@ -7313,6 +7313,23 @@ this.setFontFamily = function(val) { } }; + +// Function: setFontColor +// Set the new font color +// +// Parameters: +// val - String with the new font color +this.setFontColor = function(val) { + cur_text.fill = val; + changeSelectedAttribute("fill", val); +}; + +// Function: getFontColor +// Returns the current font color +this.getFontSize = function() { + return cur_text.fill; +}; + // Function: getFontSize // Returns the current font size this.getFontSize = function() {