Open Bug 1632185 Opened 5 years ago Updated 5 years ago

Printing Problem, the print out is rotated 90 degrees anti clock wise where as the print preview is correct

Categories

(Core :: Printing: Output, defect)

75 Branch
defect

Tracking

()

UNCONFIRMED

People

(Reporter: takalika_man, Unassigned)

Details

Attachments

(6 files, 1 obsolete file)

Attached file receipt

User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0

Steps to reproduce:

I am using ubuntu 18 and Firefox version 75.0 (64-bit).
I am using generic label printer using driver TSC TDP-245. I tried to print a qr code label as attached. When i press print, the print preview looks nicely fitted into the paper but when i print the print out is rotated 90 degrees anti clock wise.
If i print to pdf format and then i print again from the pdf viewer the same output, the expected output comes but it doesn't happen if i print from the browser straight

Actual results:

print out is rotated 90 degrees anti clock wise.

Expected results:

It should print as depicted in the print preview

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → Printing: Output
Product: Firefox → Core

Could you upload the HTML/CSS/image files to this bug report for the label please?

Flags: needinfo?(takalika_man)
Attached image moz-image.jpg

//Script libraries that i use to generate the barcode
<script src="JsBarcode.all.min.js"></script>
<script src="./qrcode/qrcode.js"></script>

//Function that generates the barcode.
function queryStock(dataObj)
{
var param = JSON.stringify(dataObj);
var ajax = new XMLHttpRequest();
ajax.open("POST","barcebe.php",true);
ajax.setRequestHeader("Content-type","application/json");

ajax.onreadystatechange = function() {
if(this.readyState == 4 && this.status == 200)
{
var jsonData = JSON.parse(this.responseText);

if(jsonData.length > 0)
{
 var prefix = document.getElementById("txtprefixBcode").value;

  for(var x=0;x<jsonData.length;x++)
  {
var hash = CryptoJS.HmacSHA256(jsonData[x]["serialnum"], "1234");
var hashInBase64 = CryptoJS.enc.Base64.stringify(hash);

var dvattr = document.getElementById("barcodecontainer"); 
new QRCode(document.getElementById("barcodecontainer"), {
text: "[\""+jsonData[x]["serialnum"]+"\",\""+prefix+"\",\""+jsonData[x]["barcode"]+"\",\""+hashInBase64+"\"]",
width: 100,
height: 100,
colorDark : "#000000",
colorLight : "#ffffff",
correctLevel : QRCode.CorrectLevel.H
});

document.getElementById("txtSerial").innerHTML = jsonData[x]["serialnum"];
document.getElementById("txtPrtBarcode").innerHTML = jsonData[x]["barcode"];

var divP = document.createElement("DIV");
    divP.setAttribute("style","font-size:8px;page-break-after:always");
dvattr.appendChild(divP);
alert("[\""+jsonData[x]["serialnum"]+"\",\""+prefix+"\",\""+jsonData[x]["barcode"]+"\",\""+hashInBase64+"\"]");
 }
}
else
{
 document.getElementById("displayDiv").setAttribute("style","display:block;");
 document.getElementById("printheader").setAttribute("style","display:none;");
 return
}

}
}//eorsc
ajax.send(param);
} //eof

Attached file mozbug.txt (obsolete) —
Flags: needinfo?(takalika_man)
Attached image moz-bug-img.jpg

This print out was made after printing to pdf from mozilla and then printing it from pdf viewer

Attachment #9143379 - Attachment is obsolete: true

In the photo in comment 3, it appears that "portrait" orientation is selected in the print preview; if you select "landscape" instead, does that affect the result?

Flags: needinfo?(takalika_man)

This is the actual print out in landscape

Flags: needinfo?(takalika_man)
Attached image Lanscape_preview.jpg

landscape preview

Print out spans two labels in landscape mode

The priority flag is not set for this bug.
:hiro, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(hikezoe.birchill)

I wonder if you set the orientation in the print dialog it still outputs the wrong result?

Flags: needinfo?(hikezoe.birchill) → needinfo?(takalika_man)

The output is still wrong. The behavior seems to be same. I even tried opening pdf file in firefox and reprint it again. it still behaves like that.

If i open the pdf in the cairo 1.9.5 , the default pdf viewer in ubuntu and reprints it. It works beautifully.

Flags: needinfo?(takalika_man)
Attached file barcode

This is the pdf file

The priority flag is not set for this bug.
:svoisen, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(svoisen)

Because this bug's Severity has not been changed from the default since it was filed, and it's Priority is -- (non,) indicating it has has not been previously triaged, the bug's Severity is being updated to -- (default, untriaged.)

Severity: normal → --
Severity: -- → S3
Flags: needinfo?(svoisen)

The priority flag is not set for this bug.
:svoisen, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(svoisen)
Flags: needinfo?(svoisen)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: