ArthurHub / ArthurHub/HTML-Renderer

PrintDocument graphics gdi+ vs gdi issue (winforms)

Aperta
#54 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
bug
Lingua principale
C#
Stelle
1.4k
Fork
550
Merge medio
14g 9h
PR unite (30g)
1

Descrizione

Hi,
It seems like something is off with regular gdi rendering in the current version. Seems like it is being output at an extremely small resolution, even though I'm passing the correct margin data.

Here's a ghetto phone pic of my printed output:

![Image](https://github.com/user-attachments/assets/9d3ea0a5-9b06-4dfb-8975-d815e2f58bb3)

Here are the statements I'm using:
`HtmlRender.Render(printerGraphics, html, (float)printedMarginArea.Left, (float)printedMarginArea.Top, (float)printedMarginArea.Width);`
`HtmlRender.RenderGdiPlus(printerGraphics, html, (float)printedMarginArea.Left, (float)printedMarginArea.Top, (float)printedMarginArea.Width);`

The regular "render" method appears to be scaling correctly in 1.3.0, but I'm missing too much functionality to be able to use that version. I'm trying to poke around the source code but I'm not able to find the disconnect...

Appreciate it!

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Direzione di ricerca

Start by reproducing the issue with PrintDocument using the two mentioned entry points, HtmlRender.Render and HtmlRender.RenderGdiPlus, and the supplied margin values. Compare the printed scaling and inspect the rendering path to identify where regular GDI handling diverges; done means regular Render produces correctly scaled output without losing the functionality required by the reporter.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
csharp
Ambito
desktop
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Da chiarire
Idoneità per principianti
25/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.