IHTMLElementRender opacity
June 9th, 2006
Using IHTMLElementRender::DrawToDC is the wrong way to draw the contents of an webpage to a device drawing context. The reason why the IHTMLElementRender interface is not good is because it does not draw opacity or transpancy that might be visible in a web page. Instead it is best to query the IViewObject interface from the IHTMLDocument2 interface and call the function Draw.
BAD
IHTMLDocument2 — IHTMLElement – IHTMLElementRender::DrawToDC.
GOOD
IHTMLDocument2 – IViewObject::Draw using DVASPECT_DOCPRINT
You can also use OleDraw instead of IViewObject::Draw and pass OleDraw the IHTMLDocument2 interface.








August 14th, 2007 at 12:31 pm
I don’t suppose you can help me figure out how to draw an HTML page “into” an Enhanced Metafile using VB 6 ?
August 30th, 2007 at 11:39 am
YOU A GENIUS!!!!
WebBrowser control...again about web sites thumbnails/screenshots generated from the server
May 25th, 2008 at 7:20 pm
August 20th, 2009 at 4:09 pm
Is there a solution to the issue that IViewObject::Draw only draws to bitmaps? Even metafile handles result in a bitblt wrapped in a metafile.