Skip to content

Inkscape font warning: font replaced with itself (i.e. Font '321impact' substituted with '321impact')

Duplicate issue in https://bugs.launchpad.net/inkscape/+bug/1181623

Summary:

Inkscape font warning with no need

When opening a SVG file with texts, Inkscape shows a Warning Message talking about changing an existing font by the same font.

Steps to reproduce:

Requires Font Substitution warning dialog to be enabled (in preferences, under Tools > Text)

  1. Open Inkscape and add some text with font "321impact".
  2. Save document as svgz and close Inkscape.
  3. Open the file and it works fine.
  4. Change the text font from "321impact" to "Helvetica".
  5. Save the document and close Inkscape.
  6. Open the file and it shows the font substitution alert: Font '321impact' substituted with '321impact'

What happened?

With the attached sample file this message appears:

https://imgur.com/cL3NcyW.png

What should have happened?

Nothing.
If the file uses an existing font, there is no need to change it for any other.

Following the steps to replicate should result in a svg file that is in this format:

<text style="font-family:FONTA">
<tspan style="font-family:FONTB"> text </tspan>
<tspan style="font-family:FONTB"> text with different style </tspan>
</text>

where Inkscape warns that FONTA is substituted with FONTA.

Taking a look at https://gitlab.com/inkscape/inkscape/-/blob/a9d5e92c4bbf04a4ecc151678855fc6ec6b8146e/src/ui/dialog/font-substitution.cpp#L120-131 , this case doesn't seem to have been considered.

Sample attachments:

Version Info:

1.0 (4035a4fb49, 2020-05-01) Debian
Inkscape 0.48+devel r12217 (Windows XP SP3)
Inkscape 0.91 r13725 (OS X 10.7.5)
Inkscape 0.91+devel r14444 (OS X 10.7.5)

Possibly introduced after 0.48.

The description summarizes the discussion below (ignoring comments moved off to a separate issue), except perhaps the replication info in the very first comment (inbox#3150 (comment 369229516))

Thank you so much!! ;)

Edited by Nathan Lee
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information