ArthurHub / ArthurHub/HTML-Renderer

PdfGenerator scales by 133% (or 1/3)

Aberta
#97 1 comentário 0 reações 0 responsáveis Ver no GitHub
bug PDF
Linguagem predominante
C#
Estrelas
1.4k
Forks
550
Merge médio
14d 9h
PRs com merge (30d)
1

Descrição

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?

Guia de contribuição

Nenhum guia de contribuição indexado para este repositório

Direção de pesquisa

Nenhum arquivo-fonte ou teste é nomeado na issue. Comece reproduzindo o HTML fornecido e medindo as dimensões do PDF gerado; em seguida, rastreie o caminho de geração do PDF para a escala de 133% relatada. Considera-se concluído quando as dimensões CSS em polegadas e pontos são renderizadas no tamanho físico especificado, sem exigir valores de 3/4 do tamanho.

Escrita pelo modelo de indexação a partir do texto da issue.

Avaliação

Stack de tecnologia
csharp
Domínio
tooling
Tipo de issue
Bug
Dificuldade
3/5
Tempo estimado
1-2 dias
Status de atividade
Estagnada
Clareza
Precisa de esclarecimento
Facilidade para iniciantes
35/100

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.