Search code examples
javascripthtmltwitter-bootstraphtml2canvas

html2canvas issue with icons


Hello I am trying to print a div of list of notes with some icons with the help of html2canvas.enter image description here

see above is my input image. enter image description here

but I am getting this output. Please help me if any one

    .icon-circle:before {
      content: "\e941";
    }
<div style="position: relative; border-bottom: 1px solid #cecece; display: table-cell; vertical-align: middle; width: 85px; padding:5px 0;"> 
  <i class="icon-circle" style="color:"blue">
     <span style="color: white;font-size: 18px;position: absolute; top: 22px;left: 13px;"> T
     </span>
   </i>
</div>

have any solution


Solution

  • Finally in the new version 1.1 of html2canvas I got the solution #1001.

    Here is the fiddle

    window.takeScreenShot = function() {
        html2canvas(document.getElementById("target"), {
            width:320,
            height:220
        }).then(function (canvas) {
           document.body.appendChild(canvas);
       });
    }