Which Font Is Substituted?

I have a several chapters of a book that were originally composed
using an earlier version of LibreOffice using what I believe was the
"Century Schoolbook" font. Now when I call them in for editing, the
font is shown in italics as "Times New Roman" with the note "The
current font is not available and will be substituted".

This is giving me a serious problem since the book contains many
drawings and framed images and these get re-flowed due to the
difference in the absolute height of the font being substituted. In
some cases the drawings are pages away from their correct location and
have to be towed back, which is time consuming and creates some other
problems too.

I checked and the Century Schoolbook font is installed where expected;
in the /usr/share/fonts/century-schoolbook/ directory.

I have not been able to figure out which font is being used for the
substitution, nor why the correct font cannot be found.

Can anyone help?

Details:
  Linux Fedora 32 - workstation
  LO 6.1.3.2

I am on a back level of Libre Office because we have hundreds of line
drawings in use in the .eps format that is no longer supported by LO
on newer releases.

Thanks in advance for any help!

Regards,

John

John,

I am using Slackware Linux 14.2 (k4.4.227).

Do you have any font substitutions in LO's Options > LibreOffice > Fonts > Replacement table?

Note that "/usr/share/fonts/century-schoolbook/" is not a standard Xorg font directory. Xorg probably does not have this directory in its list of font directories to search. That may be why LO cannot find it. I found it in "/usr/share/fonts/100dpi/" as ncen*.pcf.gz. It is listed in the fonts.dir plain text file in that directory. If the font path is not in the X font directory search list, then X cannot supply it to LO. I suggest to place it in the correct directory or add the century-schoolbook directory to X's font directory list. To do that, if you have an xorg.conf file (/etc/X11/xorg.conf YMMV), look for the "FontPath" entries and add your path to it.

Another option is to run the font database manager, but I use that so little, I have forgotten how to do it.

I just checked and discovered my LibreOffice 6.2.8.2 does not have Century Schoolbook listed either. However, my Apache OpenOffice 4.1.6 does have a "Century Schoolbook L" font listed. This implies that even if the font is in the correct directory, as in my case, LO is omitting it for some reason. Are you sure there is no entry in your font replacement table?
So, another option might be to install AOO and see if that works better for you.

HTH.

Girvin Herr

You can also places fonts in /home/<username>/.fonts. They will be
available only for that user, but it's easier because there's just one
folder so you don't have to sweat whether you put it in the right
place.

On Sat, 10 Oct 2020 14:07:18 -0700
Girvin Herr <gherrl@fastmail.com> dijo:

Thanks you for the prompt reply Girvin.

The replacement table is empty at the moment; any font replacements/
substitutions are happening due to defaults.

I did find the X11 font table but Fedora uses Wayland instead of X11
as the display manager so it may not show up in Gnome, and hence to
Libre Office. None of the common fonts seem to be in the fonts.alias
table in the X11/dpi100 font directory.

I didn't know there is a font database; I'll have to look that up and
see if it helps.

I might have to install Apache Open Office but that would be a
significant business risk if I screw up and lose the existing LO
version because of the management of the drawing inserts.

Regards,

John

Hi,

I also had a similar issue because the name of the font changed with an upgrade. I.e "Century Schoolbook" to "Century Schoolbook L", although in my case it wasn't Century Schoolbook.

The first step will be to get the font you need to show in the fonts list in LibreOffice. A solution here could be to use the system font installer tool, go to /usr/share/fonts/century-schoolbook/ directory and try to install the fonts. The installer will either install the fonts where the system wants them or tell you they are already installed.

Restart LO and see if the font is in the font list.

A backup for next time: I have a fonts directory in my home folder, I copy fonts here as a backup when they are installed and it means I cam always get back to fonts used in old documents even after an OS upgrade, assuming you back up this fonts directory.

Steve

Thanks John.

I created that directory and the result is a bit peculiar. When I
copied over the Century Schoolbook directory it has fonts like
"Century PS Pro" in it and these now appear on the available fonts
list. So I tried that one and it appears to be identical to the
existing text so I think I'll use that. The size is correct and for
me, the character outlines look the same, or close enough that it
won't be a problem.

That said, I still don't know why the font shows in italics as "Times
New Roman", a font that I do not have installed at all anywhere that I
can find, when I initially load the document.

One of life's little mysteries I guess!

Regards and thanks.

John

I have tried your suggestion several times, with possible changes, and
the font always shows in italics at the head of editor screen.

To clarify, the correct font, named Century PS Pro in this
incarnation, is available on the font options list when editing a
document.

BUT the incoming text documents were created on previous versions of
Libre Office, or may have been imported from Open Office, Textmaker or
Word Perfect, and show the name of the font as known to those
programmes, ie "Century Schoolbook" so the font name shows in
italics.

So, I went to the Replacement table in Libre Office and set "font
Century Schoolbook, replace with Century PS Pro" (which showed up as a
choice on the drop down menu) and ticked the "always" box and "apply
replacement table" and OK. These settings are retained between
restarts of Libre Office..

But when I load a document for editing, Century Schoolbook still shows
up in italics as the active font. If I then start to edit and click
"Insert | Special Character" I get a very limited number of Latin
special characters and a group of Sinhala glyphs. It is quite
possible to change the Latin subset of characters but Libre Office
always reverts to Sinhala when you return to editing the document. By
experiment, if the font is recognized by LO then the correct special
character substitution table is presented.

The actual font in use seems to be correct in that the characters look
"right" and all the metrics (height, spacing, leading, etc) work out
as expected.

I could possibly provide a soft link to the correct name but I'm
afraid of blowing up something else that I haven't thought about
(yet).

Any ideas?

Thanks in advance.

John

Do the documents you want to edit contain any fonts other than "Century Schoolbook", i.e. contain only a single font.

With the documents I edit from various sources I just select-all and change the font to Arial which I use throughout.

Steve

May be font substitution doesn't really work as we expected.
I just tried a document using an older font no longer installed. I set up the substitution table and saved the document but the font was not substituted.
I just tried saving the document as an fodt then;
> sed 's/Albany AMT/Bitstream Charter/g' <fontSub.fodt >fontSubout.fodt

And it worked a charm.

Steve

Thanks for the reply Steve.

Yes, there are at last two fonts from different families in each
document, the bulk of the text is in Century Schoolbook but the titles
and subtitles are in Deja Vu Sans, and any Internet references are in
a mono spaced font.

Regards,

John