code: function ( o, w, h, force ) {
  
          // prevent exesive redraw
  
          if( force && R.tmpTime !== null ) { clearTimeout(R.tmpTime); R.tmpTime = null;  }
  
          if( R.tmpTime !== null ) return;
  
          if( R.lock ) R.tmpTime = setTimeout( function(){ R.tmpTime = null; }, 10 );
  
          ///
  
          var isNewSize = false;
          if( w !== o.canvas.width || h !== o.canvas.height ) isNewSize = true;
  
          if( R.tmpImage === null ) R.tmpImage = new Image();
  
          var img = R.tmpImage; //new Image();
  
          var htmlString = R.xmlserializer.serializeToString( o.content );
          
          var svg = '<svg xmlns="http://www.w3.org/2000/svg" width="'+w+'" height="'+h+'"><foreignObject style="pointer-events: none; left:0;" width="100%" height="100%">'+ htmlString +'</foreignObject></svg>';
  
          img.onload = function() {
  
              var ctx = o.canvas.getContext("2d");
  
              if( isNewSize ){ 
                  o.canvas.width = w;
                  o.canvas.height = h;
              }else{
                  ctx.clearRect( 0, 0, w, h );
              }
              ctx.drawImage( this, 0, 0 );
  
              o.onDraw();
  
          };
  
          img.src = "data:image/svg+xml;charset=utf-8," + encodeURIComponent(svg);
          //img.src = 'data:image/svg+xml;base64,'+ window.btoa( svg );
          img.crossOrigin = '';
  
  
      }
docs: ---------------------- CANVAS ----------------------