ArthurHub / HTML-Renderer

Cross framework (WinForms/WPF/PDF/Metro/Mono/etc.), Multipurpose (UI Controls / Image generation / PDF generation / etc.), 100% managed (C#), High performance HTML Rendering library.
https://htmlrenderer.codeplex.com/
BSD 3-Clause "New" or "Revised" License
1.26k stars 527 forks source link

HTML with Images - unwanted image scaling problem #197

Open Dime358 opened 1 year ago

Dime358 commented 1 year ago

When HTML contains images they are scaled up by ~20% when converting to PDF.

Image 1: Screenshot 2022-10-05 135628 This is the desired look when generating (taken from HTML template)

Image 2: Screenshot 2022-10-05 135738 This is the result i am getting

When HTML is opened in browser it looks like example 1 as it should be. The < img > tag have height and width attributes and this is occurring every time image is present in the HTML.