PDA

View Full Version : FontReplacer Applet: Fixed



bklaas
2015-05-17, 08:04
After a couple months of it being broken, I've confirmed the 3rd party applet FontReplacer is now fixed and installable. A hearty thank you for persistent help from Michael Herger, the Lone Wolf of the Squeezebox, in helping me get this working. He even emailed me from holiday in Brazil helping me. He has really been a tireless help to everyone in this still present community, and I commend him for it.

FontReplacer provides a modified DroidSans font that includes a broader character set. I tested it out and it works for Chinese, Japanese, and Korean character sets. It does not work with Thai and Arabic. Cyrillic characters are already supported by the default font, so you should already be good there. As for other character sets, you will need to test those on your own.

To install on a squeezeplay-based Squeezebox (Touch/Radio/Controller):
App Gallery->3rd Party Applets->FontReplacer, choose install (version should currently read 1.3)
Applet will download, install and restart
To use:
You will need to find the Font Replacer item in the home menu, select it and confirm that you want the default font replaced. The squeezebox will restart once more and you will now have a working expanded font set.

Background on why it broke: I've been hosting the applet for years on the googlecode website. Early this year I got an email from Google that googlecode was being discontinued (as Google is wont to do with everything they build). To their credit, they offered a one click conversion to my github account, and that worked great. However, github proved to be a non-viable repository for the applet zip file because a) github only provides https for zip downloads, and this is incompatible with the squeezeplay, and b) it produces a zip file organized in a way that is unusable in this context.

I am now self-hosting the applet. While that wouldn't be my first choice, it gets me solidly around all of the potential pitfalls of using cloud services as described above. Until Comcast shuts down my webserver, which they'd have no reason to do but I'm convinced they will do someday, because they are Comcast, I think we're good.

cheers,
#!/ben

180191802018021

pippin
2015-05-17, 08:37
Cool. Is there a simple way to use other OpenType or ttf fonts?
Can you select the face, too?

bklaas
2015-05-17, 09:35
The applet is really a hack. A clean hack, but a hack. Squeezeplay is expecting two font files, FreeSansBold.ttf and FreeSans.ttf (and is hard-coded to only use those font files). The applet works by copying the applet font files (which are hand-cobbled files I made: FreeSans + a bunch of extra Droid Sans characters to fill in gaps not covered by FreeSans) over the stock ones.

If you wanted to hack the hack, you could either a) fork the FontReplacer applet and create your own one with different fonts (https://github.com/bklaas/fontreplacer/tree/master/FontReplacer), or yb) ou could skip the applet route altogether and just scp new ttf files overwriting the FreeSans files on the filesystem, which is all the applet ends up doing anyway.

The applet code is trivially simple, you can figure out what's happening by looking at the _copyAndRestart() method in FontReplacerApplet.lua

cheers,
#!/ben

ply3908
2015-05-18, 23:00
It stuck at "Downloading Applet" forever...

EDIT: It works now after added the repository "http://github.com/bklaas/fontreplacer/repo.xml" to LMS. LMS does not take "https" path. Thanks.

bklaas
2015-05-22, 07:37
It stuck at "Downloading Applet" forever...

EDIT: It works now after added the repository "http://github.com/bklaas/fontreplacer/repo.xml" to LMS. LMS does not take "https" path. Thanks.

FYI, you want http://benklaas.com/fontreplacer/repo.xml, not a github.com URL. I don't know how LMS updates those paths, but that's out of date. I'm actually quite surprised the github repo.xml file worked for you, as it points to a zip file that in my testing did not work.

cheers,
#!/ben

rklpoon
2015-06-11, 21:47
I use SBT and last night when I attempted to reinstall the FontReplacer(after reset the SBT to factory setting) it just failed and the screen showed Reinstall version 1.3.... reinstallation also failed. :(

Alpengreis
2015-06-13, 12:15
I use SBT and last night when I attempted to reinstall the FontReplacer(after reset the SBT to factory setting) it just failed and the screen showed Reinstall version 1.3.... reinstallation also failed. :(Yes, here too - this is no wonder because the URL
http://benklaas.com/fontreplacer/repo.xml produces a "404 Not found" ...

EDIT: I have replaces now the two fonts via SCP, was no problem.

In my case (on my device), the files are in the path ...

/usr/share/jive/fonts

... then I reboot the device and voila.

Greetings

mherger
2015-06-15, 00:48
> http://benklaas.com/fontreplacer/repo.xml produces a "404 Not found" ...

You should no longer need that URL. The pre-installed repository file
should contain the Fontreplacer addon. Please remove that entry and try
again.

--

Michael

Alpengreis
2015-06-15, 08:41
> http://benklaas.com/fontreplacer/repo.xml produces a "404 Not found" ...

You should no longer need that URL. The pre-installed repository file
should contain the Fontreplacer addon. Please remove that entry and try
again.

1) I wrote this because the posting of bklaas itself:


FYI, you want http://benklaas.com/fontreplacer/repo.xml, not a github.com URL.

But, I see NOW (with help of your posting), this is probably really no more the right URL.


2) I had no additional repos added actually. I had tested it direct via SBR and PC.

Important: If no additional repo is added in LMS, the SBR has nevertheless an entry for FontReplacer in the 3rd-Party Plugins - which was NOT successful ("Reinstall" appears always).

I have the actual Firmware (after switching from UE to SBR).

So this seems to be a real problem for all whitout no extra repo for FontReplacer.


3) The right additional repo ...

From ...

http://wiki.slimdevices.com/index.php/Squeezebox_Server_repositories

I see this ...

http://fontreplacer.googlecode.com/svn/trunk/repo.xml

which points to ...

http://fontreplacer.googlecode.com/files/FontReplacer04252011.zip

You mean this repo, right?

At least the font files are the same, as I have installed now (except the file names, which are not yet changed in the ZIP).

So for next reset of SBR or so, I could add this repo ...


Thanks!

Regards
Alpengreis

rklpoon
2015-06-15, 20:03
Any chance for my SBT to get the correct path please? Thank you.

mherger
2015-06-15, 21:19
> http://wiki.slimdevices.com/index.php/Squeezebox_Server_repositories
>
> I see this ...
>
> http://fontreplacer.googlecode.com/svn/trunk/repo.xml
>
> which points to ...
>
> http://fontreplacer.googlecode.com/files/FontReplacer04252011.zip
>
> You mean this repo, right?

NO. You should not need to enter any URL at all. Above URL is no longer
valid. Remove them all and try again.

--

Michael

Alpengreis
2015-06-16, 08:15
> http://wiki.slimdevices.com/index.php/Squeezebox_Server_repositories
>
> I see this ...
>
> http://fontreplacer.googlecode.com/svn/trunk/repo.xml
>
> which points to ...
>
> http://fontreplacer.googlecode.com/files/FontReplacer04252011.zip
>
> You mean this repo, right?

NO. You should not need to enter any URL at all. Above URL is no longer
valid. Remove them all and try again.

Good to know!

I have it now already (copied the fonts manually via SCP), so I do not make further tests - at least not at this moment. I can just say: few days ago (ca. 3 or 4 days ago) I had tested it after reset my UE resp. SBR - and without any repo in LMS - was NOT successful (I had always the message "Reinstall").

However, thank you, Michael, for your answer!

Greetings

bklaas
2015-06-19, 12:54
Alpengreis- you reached out to me via last.fm but your user on that service is not configured to receive messages, so I was unable to respond.

I had a major HD failure on my home webserver, which is now the home of fontreplacer after googlecode went away. I've finally replaced the hardware and gone through the unpleasant task of recovering all the data (though I got it all back, which is quite pleasant).

By all indications this should all be finally working again.

cheers,
#!/ben

Alpengreis
2015-06-19, 15:58
Alpengreis- you reached out to me via last.fm but your user on that service is not configured to receive messages, so I was unable to respond.
Oh, sorry, that's bad!


I had a major HD failure on my home webserver, which is now the home of fontreplacer after googlecode went away. I've finally replaced the hardware and gone through the unpleasant task of recovering all the data (though I got it all back, which is quite pleasant).

By all indications this should all be finally working again.
All right, thank you very much for your answer here!

Kind regards!

Alpengreis
2015-07-06, 15:47
@bklaas

I can confirm now, that the FontReplacer installation works again!

Thank you!

rlsx
2015-08-24, 08:19
@bklaas


By all indications this should all be finally working again.
#!/ben
Thanks for the work!

Any change to get "Arabic" in the next iteration?

Strangely my SB3 displays them without problems...

SBT
2015-08-29, 10:17
Alpengreis- you reached out to me via last.fm but your user on that service is not configured to receive messages, so I was unable to respond.

I had a major HD failure on my home webserver, which is now the home of fontreplacer after googlecode went away. I've finally replaced the hardware and gone through the unpleasant task of recovering all the data (though I got it all back, which is quite pleasant).

By all indications this should all be finally working again.

cheers,
#!/ben

Hi
I tried to install the font replacer many time without success, it always asked me to reinstaall , even after I did the restore default via the reset button. Please help me with detail instructions on how to install the font replacer
Many Thanks