Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't reduce margin during image print #68

Open
riadapsis opened this issue Nov 7, 2018 · 0 comments
Open

Can't reduce margin during image print #68

riadapsis opened this issue Nov 7, 2018 · 0 comments

Comments

@riadapsis
Copy link

Thanks for the great plugin. Now I am facing the following problem while printing image-

  • Want to use full width of paper (58mm). But there is a margin at both side and can't remove it.
    20171031_224618
    Please help. I am stuck for last couple of days. Sample code:
var c = document.getElementById("canvas");
var ctx = c.getContext("2d");
ctx.clearRect(0, 0, c.width, c.height);
ctx.fillText("প্রতি প্যাকেটের মূল্য:",0,25);
ctx.fillText('BKH:20s-২০১.৯০,12s-১২১;',0,50);
ctx.fillText('LPGL/PM/CAP:20s-১৩৯.৯০',0,75);
ctx.fillText("KPML:12s-৮৩.৯৪;SRR:20s৮৯.৯০;",0,100);
ctx.fillText("DBBL/BBL:20s-৫৩.৯০, 10s ২৬.৯৫",0,125);
var imageData = canvas.toDataURL('image/png');
BTPrinter.printImage(function (data3) {
	}, function (err) {
		alert("ERRO IMAGEM"+ JSON.stringify(err));
	}, imageData);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant