Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating font using Windows Installer causes font rendering issues even after system reboot #9

Closed
ciscorucinski opened this issue Jun 5, 2016 · 21 comments

Comments

@ciscorucinski
Copy link

I decided to actually update my Hack font to the latest version using this installer. When I tried it, the installer froze twice during restarting the Font Cacher service on windows.

The 3rd time I tried to install the Hack font, the installer actually finished and the font rendering of the Hack font in Android Studio 2.2 preview 2 was almost perfect.

However, I still see issues when I have non-bold, italic text.

@texhex
Copy link
Member

texhex commented Jun 7, 2016

@ciscorucinski Sorry to hear that Christopher, but the only explanation I have is that the Font Cache Service really refused to stop. We do not have any timeout for this but instead simply wait for it to stop, even if it takes hours. I will think about how to improve this.

About the issues with the font in Android Studio: Is this a Java based IDE?

@ciscorucinski
Copy link
Author

Well, that explains the behavior I was seeing in the installer. I just used Ctrl - Alt - Del and stopped the installer twice before having a success later on.

Android Studio is a Java-based IDE; however, this effect is also seen on non-java files such as XML or JSON as long as the font is styled with only italic text (non-bold)

The letters are transformed to usually be the same letters but with accent marks above them. foo turns to goo with the accent marks above the os. newInstance() looks just like newInstance() however, every letters has the accent tick above it with the t having an extra bar

@texhex
Copy link
Member

texhex commented Jun 8, 2016

OK, thanks for the update. I suspect this is the "Java FreeType vs. Windows" bug you are having (see issue #129 over at Hack). There is also a hint to force Java to fall back to the t2k render path which might help.

If possible, could check if the font also displays incorrectly when using a non-Java tool, e.g. Notepad++?

@texhex
Copy link
Member

texhex commented Jun 8, 2016

Oh, and by the way: Could you please post the contents of Log-FontData.txt somewhere? I don't think it's an installer issue, but I better be sure than sorry.

@ciscorucinski
Copy link
Author

@texhex Ok, with a quick check in Notepad++, the Hack font seems to work very well.

Setup Log 2016-06-05 #004.txt

2016-06-05 08:55:08.636   Log opened. (Time zone: UTC+09:00)
2016-06-05 08:55:08.636   Setup version: Inno Setup version 5.5.8 (a)
2016-06-05 08:55:08.636   Original Setup EXE: C:\Users\Christopher\Downloads\HackWindowsInstaller.exe
2016-06-05 08:55:08.636   Setup command line: /SL5="$3503F2,560025,147456,C:\Users\Christopher\Downloads\HackWindowsInstaller.exe" /SPAWNWND=$90584 /NOTIFYWND=$F006E 
2016-06-05 08:55:08.636   Windows version: 10.0.10586  (NT platform: Yes)
2016-06-05 08:55:08.636   64-bit Windows: Yes
2016-06-05 08:55:08.636   Processor architecture: x64
2016-06-05 08:55:08.673   User privileges: Administrative
2016-06-05 08:55:08.674   64-bit install mode: Yes
2016-06-05 08:55:08.678   Created temporary directory: C:\Users\CHRIST~1\AppData\Local\Temp\is-KJUF3.tmp
2016-06-05 08:55:18.254   ---BeforeInstallAction START---
2016-06-05 08:55:18.254   Setup version: 1.2.0
2016-06-05 08:55:18.254   Font version.: 2.020
2016-06-05 08:55:18.254   Local time...: 2016-05-06 08:55
2016-06-05 08:55:18.254   Fonts folder.: C:\WINDOWS\Fonts
2016-06-05 08:55:18.255   Dest folder..: C:\Program Files\Hack Windows Installer
2016-06-05 08:55:18.266   ---HASH CALCULATION---
2016-06-05 08:55:18.266   Calculating hash for Hack-Bold.ttf
2016-06-05 08:55:18.266      File from setup: a7bb6faacd609145b55ed15ca238755544c03af5
2016-06-05 08:55:18.266      File in \fonts : -NOT FOUND-
2016-06-05 08:55:18.266   Calculating hash for Hack-BoldItalic.ttf
2016-06-05 08:55:18.266      File from setup: c428004a2fe3570450c6d03442052b1a9989c58b
2016-06-05 08:55:18.266      File in \fonts : -NOT FOUND-
2016-06-05 08:55:18.266   Calculating hash for Hack-Regular.ttf
2016-06-05 08:55:18.266      File from setup: 664cfe2a64de1486c0ace8073ceeb6d9281e8b78
2016-06-05 08:55:18.274      File in \fonts : 664cfe2a64de1486c0ace8073ceeb6d9281e8b78
2016-06-05 08:55:18.274   Calculating hash for Hack-Italic.ttf
2016-06-05 08:55:18.274      File from setup: efdae4b94858b98eab6dcf2cb8e3cc3d28263cc2
2016-06-05 08:55:18.275      File in \fonts : -NOT FOUND-
2016-06-05 08:55:18.275   ----------------------
2016-06-05 08:55:18.275   Checking for differences between fonts in setup and this system
2016-06-05 08:55:18.275   IsSetupFontSameAsInstalledFont(): Hack-Bold.ttf
2016-06-05 08:55:18.275      Checking for font name in registry: Hack Bold (TrueType)
2016-06-05 08:55:18.275      Font not found in registry!
2016-06-05 08:55:18.275      Found difference for file Hack-Bold.ttf
2016-06-05 08:55:18.275      Installation required.
2016-06-05 08:55:18.277   Stopping service FontCache
2016-06-05 08:55:19.786   Stopping service FontCache3.0.0.0
2016-06-05 08:55:21.605   ---BeforeInstallAction END---
2016-06-05 08:55:21.606   Starting the installation process.
2016-06-05 08:55:21.606   IsSetupFontSameAsInstalledFont(): Hack-Bold.ttf
2016-06-05 08:55:21.606      Checking for font name in registry: Hack Bold (TrueType)
2016-06-05 08:55:21.606      Font not found in registry!
2016-06-05 08:55:21.606   IsSetupFontSameAsInstalledFont(): Hack-BoldItalic.ttf
2016-06-05 08:55:21.606      Checking for font name in registry: Hack Bold Italic (TrueType)
2016-06-05 08:55:21.606      Font not found in registry!
2016-06-05 08:55:21.606   IsSetupFontSameAsInstalledFont(): Hack-Regular.ttf
2016-06-05 08:55:21.606      Checking for font name in registry: Hack (TrueType)
2016-06-05 08:55:21.606      Font name found
2016-06-05 08:55:21.606      Checking for file name in registry. Expected: Hack-Regular.ttf
2016-06-05 08:55:21.606      File name matches
2016-06-05 08:55:21.606      File hash matches, installation not required
2016-06-05 08:55:21.606   IsSetupFontSameAsInstalledFont(): Hack-Italic.ttf
2016-06-05 08:55:21.607      Checking for font name in registry: Hack Italic (TrueType)
2016-06-05 08:55:21.607      Font not found in registry!
2016-06-05 08:55:21.614   Directory for uninstall files: C:\Program Files\Hack Windows Installer
2016-06-05 08:55:21.615   Will append to existing uninstall log: C:\Program Files\Hack Windows Installer\unins000.dat
2016-06-05 08:55:21.616   -- File entry --
2016-06-05 08:55:21.618   Dest filename: C:\Program Files\Hack Windows Installer\unins000.exe
2016-06-05 08:55:21.618   Non-default bitness: 32-bit
2016-06-05 08:55:21.621   Time stamp of our file: 2016-06-05 08:55:08.547
2016-06-05 08:55:21.621   Dest file exists.
2016-06-05 08:55:21.621   Time stamp of existing file: 2016-06-05 08:20:22.960
2016-06-05 08:55:21.621   Version of our file: 51.52.0.0
2016-06-05 08:55:21.622   Version of existing file: 51.52.0.0
2016-06-05 08:55:21.622   Installing the file.
2016-06-05 08:55:21.626   Uninstaller requires administrator: Yes
2016-06-05 08:55:21.804   Leaving temporary file in place for now.
2016-06-05 08:55:21.806   -- File entry --
2016-06-05 08:55:21.808   Dest filename: C:\Program Files\Hack Windows Installer\LICENSE-Hack.txt
2016-06-05 08:55:21.808   Time stamp of our file: 2016-02-06 11:07:34.000
2016-06-05 08:55:21.808   Dest file exists.
2016-06-05 08:55:21.808   Time stamp of existing file: 2016-02-06 11:07:34.000
2016-06-05 08:55:21.808   Installing the file.
2016-06-05 08:55:21.851   Successfully installed the file.
2016-06-05 08:55:21.851   -- File entry --
2016-06-05 08:55:21.853   Dest filename: C:\Program Files\Hack Windows Installer\LICENSE.txt
2016-06-05 08:55:21.853   Time stamp of our file: 2016-04-23 19:22:10.000
2016-06-05 08:55:21.853   Dest file exists.
2016-06-05 08:55:21.853   Time stamp of existing file: 2016-04-23 19:22:10.000
2016-06-05 08:55:21.853   Installing the file.
2016-06-05 08:55:21.856   Successfully installed the file.
2016-06-05 08:55:21.857   -- File entry --
2016-06-05 08:55:21.858   Dest filename: C:\Program Files\Hack Windows Installer\Hack-installer-icon.ico
2016-06-05 08:55:21.859   Time stamp of our file: 2016-04-25 18:56:58.000
2016-06-05 08:55:21.859   Dest file exists.
2016-06-05 08:55:21.859   Time stamp of existing file: 2016-04-25 18:56:58.000
2016-06-05 08:55:21.859   Installing the file.
2016-06-05 08:55:21.874   Successfully installed the file.
2016-06-05 08:55:21.875   IsSetupFontSameAsInstalledFont(): Hack-Bold.ttf
2016-06-05 08:55:21.875      Checking for font name in registry: Hack Bold (TrueType)
2016-06-05 08:55:21.875      Font not found in registry!
2016-06-05 08:55:21.875   -- File entry --
2016-06-05 08:55:21.877   Dest filename: C:\WINDOWS\Fonts\Hack-Bold.ttf
2016-06-05 08:55:21.939   Time stamp of our file: 2016-04-26 18:53:42.000
2016-06-05 08:55:21.939   Installing the file.
2016-06-05 08:55:21.987   Successfully installed the file.
2016-06-05 08:55:21.987   Registering file as a font ("Hack Bold (TrueType)")
2016-06-05 08:55:21.993   IsSetupFontSameAsInstalledFont(): Hack-BoldItalic.ttf
2016-06-05 08:55:21.993      Checking for font name in registry: Hack Bold Italic (TrueType)
2016-06-05 08:55:21.993      Font not found in registry!
2016-06-05 08:55:21.993   -- File entry --
2016-06-05 08:55:21.995   Dest filename: C:\WINDOWS\Fonts\Hack-BoldItalic.ttf
2016-06-05 08:55:21.996   Time stamp of our file: 2016-04-26 18:53:42.000
2016-06-05 08:55:21.996   Installing the file.
2016-06-05 08:55:22.038   Successfully installed the file.
2016-06-05 08:55:22.038   Registering file as a font ("Hack Bold Italic (TrueType)")
2016-06-05 08:55:22.043   IsSetupFontSameAsInstalledFont(): Hack-Regular.ttf
2016-06-05 08:55:22.044      Checking for font name in registry: Hack (TrueType)
2016-06-05 08:55:22.044      Font name found
2016-06-05 08:55:22.044      Checking for file name in registry. Expected: Hack-Regular.ttf
2016-06-05 08:55:22.044      File name matches
2016-06-05 08:55:22.044      File hash matches, installation not required
2016-06-05 08:55:22.044   IsSetupFontSameAsInstalledFont(): Hack-Italic.ttf
2016-06-05 08:55:22.044      Checking for font name in registry: Hack Italic (TrueType)
2016-06-05 08:55:22.044      Font not found in registry!
2016-06-05 08:55:22.044   -- File entry --
2016-06-05 08:55:22.046   Dest filename: C:\WINDOWS\Fonts\Hack-Italic.ttf
2016-06-05 08:55:22.046   Time stamp of our file: 2016-04-26 18:53:42.000
2016-06-05 08:55:22.046   Installing the file.
2016-06-05 08:55:22.108   Successfully installed the file.
2016-06-05 08:55:22.108   Registering file as a font ("Hack Italic (TrueType)")
2016-06-05 08:55:22.117   -- Icon entry --
2016-06-05 08:55:22.117   Dest filename: C:\Program Files\Hack Windows Installer\Fonts Applet.lnk
2016-06-05 08:55:22.120   Creating the icon.
2016-06-05 08:55:22.164   Successfully created the icon.
2016-06-05 08:55:22.166   -- Icon entry --
2016-06-05 08:55:22.166   Dest filename: C:\Program Files\Hack Windows Installer\Hack Homepage.url
2016-06-05 08:55:22.168   Creating the icon.
2016-06-05 08:55:22.174   Successfully created the icon.
2016-06-05 08:55:22.177   -- INI entry --
2016-06-05 08:55:22.177   Dest filename: C:\Program Files\Hack Windows Installer\InstallInfo.ini
2016-06-05 08:55:22.177   Section: Main
2016-06-05 08:55:22.177   Entry: Version
2016-06-05 08:55:22.177   Value: 1.2.0
2016-06-05 08:55:22.177   Updating the .INI file.
2016-06-05 08:55:22.190   Successfully updated the .INI file.
2016-06-05 08:55:22.190   -- INI entry --
2016-06-05 08:55:22.190   Dest filename: C:\Program Files\Hack Windows Installer\InstallInfo.ini
2016-06-05 08:55:22.190   Section: Main
2016-06-05 08:55:22.190   Entry: Name
2016-06-05 08:55:22.190   Value: Hack Windows Installer
2016-06-05 08:55:22.190   Updating the .INI file.
2016-06-05 08:55:22.191   Successfully updated the .INI file.
2016-06-05 08:55:22.194   ---NeedRestart---
2016-06-05 08:55:22.195     Changes detected, require reboot
2016-06-05 08:55:22.195   ---NeedRestart END---
2016-06-05 08:55:22.195   Will restart because NeedRestart returned True.
2016-06-05 08:55:22.376   Installation process succeeded.
2016-06-05 08:55:22.376   ---AfterInstallAction START---
2016-06-05 08:55:22.386   Starting service FontCache
2016-06-05 08:55:23.905   Starting service FontCache3.0.0.0
2016-06-05 08:55:27.011   Saving font state to C:\Program Files\Hack Windows Installer\Log-FontData.txt
2016-06-05 08:55:27.040   ---AfterInstallAction END---
2016-06-05 08:55:27.040   Need to restart Windows? Yes
2016-06-05 08:55:41.120   Will not restart Windows automatically.
2016-06-05 08:55:41.123   Deinitializing Setup.
2016-06-05 08:55:41.134   Log closed.

@chrissimpkins
Copy link
Member

@ciscorucinski Any idea what version of the JDK Android Studio is using? If you have it on your system, can you confirm that you see this in any of the Jetbrains editors?

@jorgheymans thoughts?

@ciscorucinski
Copy link
Author

I don't know which version it is right now, but I checked the font with IntelliJ IDEA, and there are no issues with italics

@chrissimpkins
Copy link
Member

chrissimpkins commented Jun 12, 2016

Based on Intellij IDEA, Android Studio provides the fastest possible...

I am not familiar with this @ciscorucinski. Is it a plugin for Intellij IDEA?

Android Studio provides wizards and templates that verify your system requirements, such as the Java Development Kit (JDK) and available RAM

Any chance that you can tap into those wizards to show us information on the JDK that is in use?

@ciscorucinski
Copy link
Author

ciscorucinski commented Jun 13, 2016

Oh wow, I completely forgot about the About screen ...

Android Studio 2.2 Preview 3
Build #AI-145.2949926, built on June 7, 2016
JRE: 1.8.0_76-release-b01 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o

I have the option to use embedded JDK which points to the newly bundled JDK that Android Studio (AS) started to do recently. However, if my memory is correct, this issue was persistent when I was using my original JDK that I had pointing to my project before I upgraded Android Studio (previously I had AS version 2.0).

Also, as for the 1st point...

IntelliJ IDEA and all JetBrain IDE's are built on top of the IntelliJ Platform. Also, Android Studio is built on top of the IntelliJ Platform; however it was build by Google. It is its own IDE. The only difference is that IntelliJ IDEA is almost always on a newer version. Android Studio lags behind from the current IntelliJ Platform version by a little bit.

Check out more here...
https://blog.jetbrains.com/idea/2013/07/webinar-build-developer-tools-on-top-of-intellij-platform/

@texhex
Copy link
Member

texhex commented Jun 13, 2016

@ciscorucinski Thanks for the log. Expect that Hack-Regular was already there, I found nothing that would explain this strange behavior. Given that the logs looks good, Hack is OK in Notepad++, this might be the Java render bug again: see issue #129 over at Hack. There is also a hint to force Java to fall back to the t2k render path which might help.

/cc @chrissimpkins

@ciscorucinski
Copy link
Author

ciscorucinski commented Jun 15, 2016

@texhex the t2k workaround does work - kind of. It fixes the weird characters that are appearing. However, it has created several other issues that are not as disruptive.

First, any text that is slated to use the italic-only font will use the bold-italic font. I have the option to choose how font looks, and there are no physical differences between the choosing italic and bold-italic. See the purple text in the picture

Second, a lot of the text within the IDE (but outside of the text editor) now looks bold. The only text that does not have the bold effect are the Tool Windows. In the picture, they are on the left, right, and bottom. (i.e. Build Variants, TODO, Gradle, etc...). The bold effect occurs everywhere, even in the Settings, and other windows.

untitled

@texhex
Copy link
Member

texhex commented Aug 21, 2016

@ciscorucinski Just for your information, we don't have forgot about this issue but there seems to be a general bug with Hack on Windows as soon a Java VM tries to displays it. We will update this as soon as we have anything new. Right now we are still trying to get to the root cause.

@rainabba
Copy link

rainabba commented Oct 20, 2016

I was also unable to use the installer. I don't see any "Font Cache" service either. What is the actual name of the service (so I can try to stop/start manually)?

UPDATE: Interestingly, I downloaded the font zip and tried to install manually, but already have the fonts so perhaps the installer was working behind the scenes and only the UI was unresponsive. That, or I've had the font for a while :)

capture

@chrissimpkins
Copy link
Member

@texhex thoughts?

@texhex
Copy link
Member

texhex commented Oct 24, 2016

@rainabba Look closer :). "FontCache3.0.0.0" is called "Windows Presentation Foundation Fond Cache 3.0.0.0" in services.msc (the other one is called "Windows Font Cache Service". The Hack Installer would not try to start it if they do not exist. I really have no idea why a simple "Start Services" hangs the entire installer.

The position it is hanging is actually AFTER the installation, so this could be the explanation why the files were already there.

@chrissimpkins
Copy link
Member

@texhex 👍

@texhex
Copy link
Member

texhex commented Oct 31, 2017

@ciscorucinski @rainabba That the installer hangs during installation should be solved as of v1.4.1, please give it a try. We had only one response from the people that also reported it (see issue #11), but also no new reports so I really think we killed that bug.

About the font rendering in Android Studio: We maybe just came across a similar issue where the reason were "old" Hack TTF files in C:\Windows\Fonts caused the Java Render to freak out.

Please check issue 345 in the Hack Repo, maybe this will also resolve your issue.

@texhex
Copy link
Member

texhex commented Nov 1, 2017

@ciscorucinski @rainabba Version 1.4.2 was just released that deletes more Hack TTF files in C:\Windows\Fontsl, especially the linegap variants that caused issues with Java based environments. The new installer should avoid these situations, so please give it a try.

@texhex
Copy link
Member

texhex commented Dec 20, 2017

@ciscorucinski @rainabba Could you please provide feedback if we can close this issue?

@ciscorucinski
Copy link
Author

@texhex sorry, I have gone to another font for a while now due to all the issues I was having.

This newest update, as of a few days ago, seemed to have fixed the issue for me. The installer works as expected, and the font now seems to work. I checked the version and it looks like it is using v3.000.

I don't know if the installer removed all the unnecessary files, but everything seems to work fine with the quick check that I did.

@texhex
Copy link
Member

texhex commented Jan 7, 2018

Thanks for the update @ciscorucinski and good to know, happy we finally got that solved. I will close this issue now.

@texhex texhex closed this as completed Jan 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants