ArthurHub / ArthurHub/HTML-Renderer

PdfGenerator scales by 133% (or 1/3)

オープン
#97 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る
bug PDF
主要言語
C#
スター
1.4k
フォーク
550
平均マージ
14日 9時間
マージ済み PR(30日)
1

説明

I'm having issues with getting a page designed to fit on 8.5x11 Letter paper to size/position properly. So I just do a simple html with a div with a set height and width as a sanity check. First I did "width: 1in; height: 2in;" and the resulting div on the PDF was 1.33333 inches x 2.66666 inches. So I tried points of 72pt x 144pt, and the same thing. If I do 54pt x 108pt I get a box that is 1inx2in. So I have to specify sized that are 3/4 the size I really want in order to get the actual on page size I'm looking for apparently.

Is there some scaling going on that you can control? Do I need to do some reset on the body? What is the user.css that it uses. I wasn't able to find these things in the source code.

Here is the simple html I'm testing:

`

`

Anyone have any thoughts on this?

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

調査の方向性

No source file or test is named in the issue. Start by reproducing the supplied HTML and measuring the generated PDF dimensions, then trace the PDF-generation path for the reported 133% scaling. Done means CSS inch and point dimensions render at their specified physical size without requiring 3/4-sized values.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
csharp
領域
tooling
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。