Media print not coming correctly when print using javascript
<p>I am trying to print a div using the following <code>javascript</code> code as follows:</p>

<pre><code>var divToPrint = document.getElementById(curid);

    var newWin = window.open('', 'Print-Window');

    newWin.document.open();

    newWin.document.write('&lt;html&gt;&lt;head&gt;&lt;link rel="stylesheet" href="css/bootstrap.css"&gt;&lt;link rel="stylesheet" href="css/font-awesome.min.css"&gt;&lt;link rel="stylesheet" href="css/style.css"&gt;&lt;link rel="stylesheet" type="text/css" media="print" href="css/print.css"&gt;&lt;/head&gt;&lt;body onload="window.print()"&gt;' + divToPrint.innerHTML + '&lt;/body&gt;&lt;/html&gt;');



    newWin.document.close();

    setTimeout(function () {
        newWin.close();
    }, 10);
</code></pre>

<p>Print.css as follows:</p>

<pre><code>@media print {
        font-size:10px;
        font-family: Calibri;

    }
</code></pre>

<p>Print div style is as follows:
<code>font-size:8pt;font-family: Calibri</code>;</p>

<p>When I see the div it comes correctly. But when I print the font-size comes as <strong>12 font-size</strong> which I checked in open office. </p>

<p>I tried to change the media-print attributes but not working.</p>