void HtmlToolTip_Draw(object sender, DrawToolTipEventArgs e) { e.Graphics.Clear(Color.White); if (container != null) { //Draw HTML! container.Paint(new GraphicsWrapper(e.Graphics)); } }
protected override void OnPaint(PaintEventArgs e) { base.OnPaint(e); if (!(this is HtmlLabel)) { e.Graphics.Clear(SystemColors.Window); } _htmlContainer.ScrollOffset = AutoScrollPosition; e.Graphics.TextRenderingHint = System.Drawing.Text.TextRenderingHint.ClearTypeGridFit; _htmlContainer.Paint(e.Graphics); }
protected override void OnPaint(PaintEventArgs e) { base.OnPaint(e); if (!(this is HtmlLabel)) { //e.Graphics.Clear(SystemColors.Window); e.Graphics.Clear(this.BackColor); } _htmlContainer.ScrollOffset = AutoScrollPosition; //FIX: from http://www.codeproject.com/KB/GDI-plus/HtmlRenderer.aspx?msg=3164018#xx3164018xx //e.Graphics.TextRenderingHint = System.Drawing.Text.TextRenderingHint.ClearTypeGridFit; e.Graphics.TextRenderingHint = System.Drawing.Text.TextRenderingHint.SystemDefault; _htmlContainer.Paint(e.Graphics); }