bugFree UCS Outline Fonts - Bugs: bug #58233, Numerals have different size on...

 
 

bug #58233: Numerals have different size on display

Submitter:  Matvei Davydov <matt_d>
Submitted:  Fri 24 Apr 2020 07:32:59 AM UTC
   
 
Category:  font metrics Severity:  3 - Normal
Item Group:  screen rendering Status:  Proceeding
Privacy:  Public Assigned to:  Stevan_White
Open/Closed:  Open Release:  * development
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Fri 01 May 2020 11:10:24 AM UTC, comment #10: 

Hi,

To be accurate: The current OTF files are more appropriate for Windows 7 +.  Maybe even (the awful) Windows Vista.  But for Windows XP, TTF files were better.

Again: I will revisit this in the next release, and make the whole thing more appropriate for modern Windows systems.

Thanks for pointing this out!

Steve White <Stevan_White>
Group administrator
Fri 01 May 2020 07:16:15 AM UTC, comment #9: 

Hi Steve,

Thank you a lot for a research! Now it's clear, that OTF is much more appropriate for Windows than TTF.

Matvei Davydov <matt_d>
Wed 29 Apr 2020 07:15:34 PM UTC, comment #8: 

Hi, Matvei,

I've done some experiments, and some recollecting.  See attached.
I don't see quite what you showed.  It is likely that there is a device dependence, besides the issues I'll describe below.

They all seem different.  To my eye, both Windows 7 and Windows 10 look better with the OTF format, as you reported.  In GNU Linux, the two files produce identical results, and those are better than anything in Windows.

The upshot is:
1) The build rules for FreeFont are out of date.  I need to re-think them, and make different suggestions for installation on different systems.  Thank you for pointing the problem out.

2) The effect you're poining out is an effect of Windows rendering.  You already found an amelioration: use the OTF files instead of the TTF files in Windows 7 - 10.  In GNU Linux systems, the rendering is much better, regardless of which format is used.

The technical background has to do with two technologies: hinting, and the outline structure.

The history is: when the 2012 release was done, I had no access to a Windows 7 system, and had tested the font only in Windows XP.  The rendering software had been completely replaced and greatly improved, but I hadn't tested it much.  The requirement of TTF for Windows thus refer to Windows XP.

I had observed that Widnows XP was very challenged with cubic ("Postscript") outlines, and did much better with its native quadratic ones.

Furthermore, Windows font renderers invest heavily in hinting, which I have heard is still done by hand.  We can't affort manual hinting in our project.  With automatic hinting, Windows' renderer is sub-optimal; without hints, it is awful.

For this reason, I packaged automatic hinting with quadratic outlines for Windows (with another switch too).  I put these into the TTF files, because TTF is in principle outdated, and I preferred the standard OTF format for our primary free-software target OS.

Thanks!


(file #48966)

Steve White <Stevan_White>
Group administrator
Mon 27 Apr 2020 10:04:01 AM UTC, comment #7: 

Hi Steve,

комментарий №6:

> Hi,
>
> 1) As I understand it:
>
> The problem is strictly one of screen rendering, and
>    * printed documents and PDFs do not show the issue.
>    * it appears both in LibreOffice and Word.
>    it *is affected by the TTF vs OTF build of the font.
>    * the better build is the OTF one, contrary to the font's installation instructions.
>

Yes, that's right.
 

> 2) My first guess, that the glyphs were somehow being replaced, isn't completely ruled out, but it seems unlikely:  something would have to turn the replacement off just during printing.
>
> 3) What you showed seemed to me much too extreme to be explained by 'hinting', yet that is the primary difference between the built TTF and OTF files.
>
> Note that the modern Windows font renderer, ClearType, relies heavily on hinting for small font sizes.
>
> Maybe I'm wrong.  And maybe somehow the hinting setting got reversed... but that 6 is very extreme.
>
> ** There is a setting: type "Adjust ClearType Text" in the Start thing.
> See if that makes a difference for you.
>

I carried out some sort of 'investigation' and installed FreeSerif TTF fonts on my laptop (it runs Windows 7 32-bit with Word 2003). In that scenario the problem with numerals still exists.
Then I changed ClearType settings several times and finally deactivated it at all, but those manipulations had absolutely no impact on numerals.


> 4) Modern versions of LibreOffice (since v. 5.3, I think) include a non-MS, free text shaper, Harfbuzz.
> I would expect that to make a big difference in the display of small letters.
>
> ** Please let me know: which version of LibreOffice are you using?
>

I have been using LibreOffice v. 4.1 for years. After reading your suggestion I installed the latest stable build (v. 6.4), but the problem with TTF fonts still remains. It manifests itself on a low scale (up to 150%). At 200% scale almost all numerals look nice, but superscript numeral 6 still is too high.
So, I think, the reason is Microsoft's screen rendering feature. At home I have only Windows 7, that's why I can't say, if it affects only Windows 7 or (maybe) Windows 10 as well.


> 5) I do have a Windows 7 system -- I don't have Word but I can get LibreOffice for it.
>
> ** If you could send me a file with just part of that text (with the superscript numerals)
> I could experiment with it.
> Or... just make another small completely different document, but with the same font settings,
> which shows this issue, and send that to me.
>

OK. Please, take a look at the attached doc file.


> 6) Note: there are various Windows programs to allow you to "Print to PDF" in Windows 7 from any program that allows printing.  Some would be adequate for the purpose.  I have used such things, but I haven't tried for a long time.
>

I spent yesterday morning on reading about those PDF applications. And finally I came to the conclusion that font embedding is a weak spot for them (I mean free software).


> 7) We are engaging here in supporting use of GNU FreeFont on a non-free system which is no longer supported by its manufacturer.  This activity is of questionable merit.  I will continue to investigate this, because I want people to use GNU FreeFont on as many systems as is reasonable.
>
> However, I must recommend that you bring your systems up to date, and further, that you do so using free software.  There are big advantages besides its being free!
>

I really have forgotten, that Windows 7 is obsolete now. And you are certainly right, when mentioning that further activity in that direction is of questionable merit. But on the other hand Windows 7 provides for all (or almost all) my needs now. And what's more, every time when MS upgrades its OS, it's a big test for users and their habits.

Offtopic: Do you plan a public release in the nearest future/this year? If no, in the support area I could share ideas concerning the shape of some Cyrillic characters.

(file #48955)

Matvei Davydov <matt_d>
Sun 26 Apr 2020 08:20:40 AM UTC, comment #6: 

Hi,

1) As I understand it:

The problem is strictly one of screen rendering, and
   * printed documents and PDFs do not show the issue.
   * it appears both in LibreOffice and Word.
   it *is affected by the TTF vs OTF build of the font.
   * the better build is the OTF one, contrary to the font's installation instructions.

2) My first guess, that the glyphs were somehow being replaced, isn't completely ruled out, but it seems unlikely:  something would have to turn the replacement off just during printing.

3) What you showed seemed to me much too extreme to be explained by 'hinting', yet that is the primary difference between the built TTF and OTF files.

Note that the modern Windows font renderer, ClearType, relies heavily on hinting for small font sizes.

Maybe I'm wrong.  And maybe somehow the hinting setting got reversed... but that 6 is very extreme.

** There is a setting: type "Adjust ClearType Text" in the Start thing.
See if that makes a difference for you.

4) Modern versions of LibreOffice (since v. 5.3, I think) include a non-MS, free text shaper, Harfbuzz.
I would expect that to make a big difference in the display of small letters.

** Please let me know: which version of LibreOffice are you using?

5) I do have a Windows 7 system -- I don't have Word but I can get LibreOffice for it.

** If you could send me a file with just part of that text (with the superscript numerals)
I could experiment with it.
Or... just make another small completely different document, but with the same font settings,
which shows this issue, and send that to me.

6) Note: there are various Windows programs to allow you to "Print to PDF" in Windows 7 from any program that allows printing.  Some would be adequate for the purpose.  I have used such things, but I haven't tried for a long time.

7) We are engaging here in supporting use of GNU FreeFont on a non-free system which is no longer supported by its manufacturer.  This activity is of questionable merit.  I will continue to investigate this, because I want people to use GNU FreeFont on as many systems as is reasonable. 

However, I must recommend that you bring your systems up to date, and further, that you do so using free software.  There are big advantages besides its being free!

Steve White <Stevan_White>
Group administrator
Sun 26 Apr 2020 07:08:34 AM UTC, comment #5: 

Hi Steve,

My yesterday screenshots both represent not pdf, but doc files opened in Word application. And all the screenshots taken and attached two days ago do so either.

As I reported earlier, in pdf everything is OK with the numerals, even when TTF fonts are used. You may take a look at the file 01.pdf attached two days ago: https://savannah.gnu.org/bugs/download.php?file_id=48920

I run Windows 7 64-bit at home, and I don't use Linux at all. I use LibreOffice Writer only for making pdfs, because Word 2003 can't do that. And when I open doc files with LibreOffice, the situation is the same to what I see in Word. I mean the following: if TTF fonts are used, the numerals have different height, if OTF ones - numerals look equal.

Matvei Davydov <matt_d>
Sat 25 Apr 2020 04:45:38 PM UTC, comment #4: 

Yes, in this PDF file, we are seeing FreeSerif for sure.  And as you mention, it looks good.
I really need a PDF file showing the problem to make any further determinations.

Some notes.

1) about the ttf/otf distiction in Windows -- There are settings in the ttf file specifically for the Windows font renderer.  It is not an accident tha it looks different.  I seem to remember it has to do with "hinting". 

But now I'm wondering... could the Windows font renderer have changed since I last tested it?  It has been a few years.

But this is Word 2003 on what Windows?  The font rendering is done by the operating system, I think.

2) hinting could explain a difference in height at very small font sizes -- maybe a pixel or two.

3) In the image you sent, some of the numerals don't even look like FreeSerif.  I mentioned the 6.  It is a different glyph.  I do not think hinting could account for that -- something replaced the glyphs with ones from another font.  (We would be able to tell from a PDF file.)

4) You mentioned LibreOffice -- just what do you see there?
Have you tried this in Linux?   You know, font rendering in Linux is mosty far better than in Windows.

Steve White <Stevan_White>
Group administrator
Sat 25 Apr 2020 08:40:04 AM UTC, comment #3: 


комментарий №2:

> Hi Steve,
>
> I'm willing to make another pdf file. At home I use Word 2003, so it should be a third party application, that embeds the fonts properly.
>
> And now as regards your suggestion to try OTF files instead of TTF ones. What should I say? Numerals in OTF look much, much better. Please, take a look at the attached screenshots.



Matvei Davydov <matt_d>
Sat 25 Apr 2020 08:36:48 AM UTC, comment #2: 

Hi Steve,

I'm willing to make another pdf file. At home I use Word 2003, so it should be a third party application, that embeds the fonts properly.

And now as regards your suggestion to try OTF files instead of TTF ones. What should I say? Numerals in OTF look much, much better. Please, take a look at the attached screenshots.

Matvei Davydov <matt_d>
Fri 24 Apr 2020 08:12:35 PM UTC, comment #1: 

Hi Matvei,

The numerals in the image look different from those in FreeSerif.  In particular, the numeral 6 has proportions quite different from those of FreeSerif.

But from images, I can't even be sure this is really FreeFont.  It would be nice to have a PDF file -- usually the name of the fonts used is recorded there.

It may be that the font is being changed in some LibreOffice character style.  But I am guessing.

It would help even more to have a sample OTF file to work with.

I am disturbed to hear that it is different when printed.  That suggests a bug somewhere.

Steve White <Stevan_White>
Group administrator
Fri 24 Apr 2020 07:32:59 AM UTC, original submission:  

Hi Steve,

I tried to understand what's going wrong with the numerals in FreeSerif Regular and Italic and finally I found out the reason why numerals have different height.

And it's not overshoot for sure.

All depends on text-scaling feature. The original-size numerals (12pt) look different both in Word and LibreOffice (see file OriginalSize.jpg)

Zooming text on the display in some cases solves the problems, but in others not (see files Zoom1.jpg and Zoom2.jpg)

While being converted to pdf, numerals look equal at any scale (see file 01.pdf)

And in printed text numerals have equal height either. I can provide you a scanned copy of it if necessary.

And now the big question is how we can get rid of it.

Matvei Davydov <matt_d>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #48966:  compare-rendering.svg added by Stevan_White (23KiB - image/svg+xml - OTF vs TTF rendering on Windows and Linux)
file #48955:  01.doc added by matt_d (27KiB - application/msword)
file #48933:  Original_Size@_OTF.JPG added by matt_d (56KiB - image/jpeg)
file #48934:  Zoom_OTF.JPG added by matt_d (148KiB - image/jpeg)
file #48917:  Original@Size.JPG added by matt_d (49KiB - image/jpeg)
file #48918:  Zoom1.JPG added by matt_d (129KiB - image/jpeg)
file #48919:  Zoom2.JPG added by matt_d (122KiB - image/jpeg)
file #48920:  01.pdf added by matt_d (45KiB - application/pdf)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by Stevan_White (Posted a comment)
  • -email is unavailable- added by matt_d (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 11 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-04-29 Stevan_White Attached File- Added compare-rendering.svg, #48966
        StatusNeed info Proceeding
    2020-04-27 matt_d Attached File- Added 01.doc, #48955
    2020-04-25 matt_d Attached File- Added Original_Size@_OTF.JPG, #48933
        Attached File- Added Zoom_OTF.JPG, #48934
    2020-04-24 Stevan_White StatusNone Need info
        Assigned toNone Stevan_White
    2020-04-24 matt_d Attached File- Added Original@Size.JPG, #48917
        Attached File- Added Zoom1.JPG, #48918
        Attached File- Added Zoom2.JPG, #48919
        Attached File- Added 01.pdf, #48920

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code