ReoGrid Forum

Fast and powerful .NET Spreadsheet Component

You are not logged in.

Announcement

This forum has been archived and no longer accepts new user registrations. Please report your questions, problems, and feedback to the issue page of ReoGrid on GitHub. Thank you for your cooperation.

https://github.com/unvell/ReoGrid/issues

#1 2016-12-10 14:51:51

sirmfletcher
Member
Registered: 2016-12-10
Posts: 8

How To Improve Text Rendering Quality on ReoGrid version 2.0.1.0

First of all, Thank you for the great work!  I really love it!

Second, I found when comparing the control's text to the text in Excel 2010 it didn't look nearly as good (in the winform control)
I started working on how to fix it.  I used git hub and obtained the sourcecode and made a few changes.

Third, the text after the changes looks a bit better , less jagged, more even thickness on fonts and consistency.

Screenshots

//  below line added by M.Fletcher 12/10/16
                    g.TextRenderingHint = TextRenderingHint.AntiAlias;

the above 2 lines (comment and textrenderinghint) were added before any calls to GDI Graphics method DrawString(...)
Locations added to were:
Graphics.cs file

added
using System.Drawing.Text;   // so that TextRenderingHint.AntiAlias is recognized in code

class/namespaces

unvell.ReoGrid.Winform.GDIGraphics
     public void DrawText(...)

unvell.ReoGrid.Winform.GDIRenderer
     public void DrawCellText(...)


Thanks for providing the code!

Fletch

Offline

#2 2016-12-10 15:31:28

Jingwood
Moderator
From: jing at reogrid.net
Registered: 2014-06-03
Posts: 615

Re: How To Improve Text Rendering Quality on ReoGrid version 2.0.1.0

Thanks for the suggestion to improvement text rendering! We will add a setting flag to enable this feature. Or you can submit a change to the source code.

Last edited by Jingwood (2016-12-10 15:34:22)

Offline

Board footer

Powered by FluxBB