html2canvas icon indicating copy to clipboard operation
html2canvas copied to clipboard

firefox html2canvas text display unusual

Open cookcc opened this issue 3 years ago • 6 comments

use the latest [1.0.0] text display unusual on result image.

image

3 problems 1.text overlapping 2.add letter-spacing can figure out overlapping,but text margin irregular event it is a single word !!! for example "Let" "first" in above image 3.only happen in firefox

OS macOS Big Sur 11.4; firefox version: 89.0.2(64Bit)

cookcc avatar Jul 07 '21 09:07 cookcc

@niklasvh help

cookcc avatar Jul 07 '21 09:07 cookcc

@cookcc can you create a repro on jsfiddle.net ?

niklasvh avatar Jul 13 '21 11:07 niklasvh

@cookcc can you create a repro on jsfiddle.net ?

i figure out this problem by using image replace the text. there isn't any other handle,u can try it out with html include text,then html2canvas,the result image displays font space is abnormal. the font family is "DIN Alternate";

cookcc avatar Jul 22 '21 03:07 cookcc

22 this is the same problem:text overlapping,but is doesn't solve yet

cookcc avatar Jul 22 '21 03:07 cookcc

I get this exact same issue in both Chrome and Firefox when using a non-standard font family, such as CiscoSansTT

CiscoSansTTRegular

OS macOS Monterey 12.0.1; firefox version: 94.0.2 (64-bit); chrome 92.0.4515.159 (x86_64)

kahole avatar Dec 10 '21 00:12 kahole

Hello, I also faced the same problem there is a sample, run index.html, wait 2 sec and look at variable window.resultPng < there is PNG with illustration

index.zip

Alexandr-Ilyin avatar Apr 21 '24 20:04 Alexandr-Ilyin