Modification of drawing changes non-alphabetic characters

Post questions on how to use or achieve an effect in Inkscape.
ScapeGoat
Posts: 40
Joined: Tue Mar 19, 2013 9:36 am

Modification of drawing changes non-alphabetic characters

Postby ScapeGoat » Thu Aug 22, 2013 1:28 pm

I have a PDF "drawing" consisting of some text (attached). The actual drawing that I am working with is much more elaborate, but this is the minimal example that I came up with to illustrate a problem.

If I make any changes to the file, some non-alphabetic characters change. In this example, the non-alphabetic characters in the 2nd item, last item, and 2nd last item change. The edits I make that induce these unwanted changes (corruptions) could be as simple as performing a single ungrouping of the object (there is only 1 object) or overwriting/deleting some text in the text box.

If I don't do too many change/save (as PDF) cycles, then I can open the PDF with Acrobat and for some magical reason, the corrupted characters do not show. Everything looks fine. I can then print it to PDF again, and when I open the PDF with inkscape, the characters that changed by themselves are no longer changed, which is good. Basically, printing from Acrobat to PDF seems to permanently remove the corruption.

The problem is that if I do too many change/save cycles in inkscape, then the corruptions show up even when I open the PDF in acrobat. I haven't fully characterized how many change/write cycles is too many (it's not a large number) nor what are the key kinds of changes causing the corruptions to be so bad that breach Acrobat's magical immunity. It's a real pain to have to clean up the corruption by feeding it through Acrobat and the PDF printer driver (PDF24) on a frequent basis.

The text has a lot of manual kerning. It's basically kerned to all high heck (it was generated by a venerable schematic tool using PDF24 printer driver). So I really can't do extensive modifications of any kind. However, I can get away with deleting text, which is what I need to do. But it seems that I have to be very careful and repeatedly stream it through Acrobat/PDF24 to prevent corruption.

Does anyone have enough insight into the inner workings of inkscape to suggest what the cause might be, and what I might be able to do to avoid this without abandoning my requirement to modify the text? All I need to be able to do is delete selected text. I'm not interested in overwriting or inserting text because the intense kerning makes that pointless anyway.
Attachments
test.pdf
(8.33 KiB) Downloaded 216 times

v1nce
Posts: 696
Joined: Wed Jan 13, 2010 4:36 am

Re: Modification of drawing changes non-alphabetic character

Postby v1nce » Thu Aug 22, 2013 9:31 pm

What do you mean by "corruption" ? the character is replaced with another one ?

I tried to open your pdf with inkscape and scribus with no luck (lot of missing characters)

Can you use another virtual printer such as http://sourceforge.net/projects/pdfcreator/ and see if it changes anything ?

ScapeGoat
Posts: 40
Joined: Tue Mar 19, 2013 9:36 am

Re: Modification of drawing changes non-alphabetic character

Postby ScapeGoat » Thu Aug 22, 2013 10:37 pm

Interesting that you can't open it in inkscape. Baffling, I mean.

Yes, by corruption, I mean that the non-alphabetic characters (punctuation and even decimal digits) get replaced by bracket symbols and greater-than/less-than symbols.

Unfortunately, it's difficult (meaning not possible) to follow up on your suggestion to try a different printer driver in the short term. I'm in a locked down environment.

Thanks for giving it a look-see.

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Modification of drawing changes non-alphabetic character

Postby Lazur » Thu Aug 22, 2013 11:20 pm

This is what I could see after the opening:
SVG Image

Don't know if that's how it should look.
What I see, is the following:
The font used is ArialMT, not arial. Didn't had it installed,
so downloaded a similar "Arial MT" (from here), which I set for the text.
Font turning to arialmt during the pdf printing from a set arial font might have been.
Like mentioned here : http://forums.augi.com/showthread.php?150317-Cannot-create-Font-ARIAL-MT
The xml editor tells me the text has some weird scaling, namely scale(0.99896997,-1.0010311).
Another thing, all the text is far too small for legible printing.

At that example file font was changed to arial mt, text converted to path, ungrouped and combined together,
and scaled up so it can be legible here.
Is that how it should look, or some characters are missing?

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Modification of drawing changes non-alphabetic character

Postby tylerdurden » Thu Aug 22, 2013 11:24 pm

If printing to pdf returns inconsistent results, I'd reset all the type on the drawing(s), to avoid future problems.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

ScapeGoat
Posts: 40
Joined: Tue Mar 19, 2013 9:36 am

Re: Modification of drawing changes non-alphabetic character

Postby ScapeGoat » Fri Aug 23, 2013 12:49 am

@Lazur: Firewall preventing access to your SVG image. However, if you have Acrobat Reader, it "should" show properly there. I uploaded an image of the proper test.pdf, named test.png. I also uploaded an image of the corrupt file, testCorrupt.png.

@tylerdurden: What do you mean by reset all the type? Is it a specific operation accessible by the menus? I wasn't able to find anything that looked applicable from googling:

inkscape reset-type

By the way, I found that I could use Acrobat Professional to do the deletions. I avoided this path in the past because I really needed the power of Inkscape to resize text and manipulate the schematic. Looks like it's feasible as a 2-step process (Acrobat Professional for the deletions followed by Inkscape for the heavy lifting).
Attachments
testCorrupt.png
testCorrupt.png (20.51 KiB) Viewed 4443 times
test.png
test.png (23.25 KiB) Viewed 4443 times

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Modification of drawing changes non-alphabetic character

Postby Lazur » Fri Aug 23, 2013 1:16 am

Don't know why is that svg blocked, it's a simple dropbox file.
Here is that and the original svg attached.
hlp69.svg
(8.81 KiB) Downloaded 182 times

hlp69II.svg
(122.76 KiB) Downloaded 172 times


I could open that file in inkscape without the described problem I assume from your png-s.
(Though H2O and °C, or even " would look better if corrected.)

Edit: -all with Inkscape 0.48.4 r9939 on win8-
Last edited by Lazur URH on Fri Aug 23, 2013 2:32 am, edited 1 time in total.

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Modification of drawing changes non-alphabetic character

Postby tylerdurden » Fri Aug 23, 2013 1:26 am

ScapeGoat wrote:@tylerdurden: What do you mean by reset all the type? Is it a specific operation accessible by the menus? I wasn't able to find anything that looked applicable from googling:

I'd add a layer and type in good text over where the current text is (for the entire document), then delete the old text. Hamfisted approach maybe, but better than leaving stuff that can come back to bite ya, IMO.

Looking at the xml, the positioning coordinates look whack.
CorrupText.jpg
CorrupText.jpg (88.11 KiB) Viewed 4424 times


Maybe Acrobat Pro will clean those up... feel free to upload an example of where a correction was made with Acrobat, I'd like to see what it makes of those coordinates.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

v1nce
Posts: 696
Joined: Wed Jan 13, 2010 4:36 am

Re: Modification of drawing changes non-alphabetic character

Postby v1nce » Fri Aug 23, 2013 1:54 am

ScapeGoat wrote:Interesting that you can't open it in inkscape. Baffling, I mean.


I'm using a dev version of Inkscape on Linux. With inkscape I only see the last sentence. With scribus I only see a O at the center of the document. The pdf is ok with the OS previewer.

hulf2012
Posts: 716
Joined: Sat Nov 24, 2012 12:37 pm

Re: Modification of drawing changes non-alphabetic character

Postby hulf2012 » Fri Aug 23, 2013 3:11 am

Hello
This problem intrigued me, because it seems that it is a simple text.
I 'm using Inkscape 0.48.4 in Win 7. I don't have, or Inkscape doesn't recognize the ARIAL MT font. So it replaces for ARIAL, or when i uncheck the option for replacing font with SANS.
At first the text is displayed like appears in thePDF.
So you ungroup the text, even Remove the manual kernells in the text menu options etc, etc.
- And here I see the problem: I SAVE as PDF in the SVG dialog (the results seems equal if it is PDF 1.5 or PDF 1.5). I open the newly created PDF in Inkscape again, and the text appears corrupted, with replaced glyphs, or with the space between characters deleted.
- I also have tried a "lorem Ipsum Text", with the extension in Inkscape, with ARIAL font, and with other font and the results are the same: corrupted text, white spaces replaced with letters. I haven't tried with other fonts, just sans-serif fonts.

- So I think it is a problem with the mot###r F#cKing! intern exporter to PDF, it's a pie### of S#it! Some one have contact with the developers here? Are they aware? Or it's a problem with some incompatibility between versions, or something like that?

- A WORKAROUND: Convert the text to paths with Ctrl+Shift+C, allthought you lose the posibility of editing as text, or use PDFCREATOR if possible, because I tested and seems that produce better results.

What a mess!!

Ok, enough distraction ... back to work... I hope!!!
If you have problems:
1.- Post a sample (or samples) of your file please.
2.- Please check here:
http://tavmjong.free.fr/INKSCAPE/MANUAL/html/index.html
3.- If you manage to solve your problem, please post here your solution.

ScapeGoat
Posts: 40
Joined: Tue Mar 19, 2013 9:36 am

Re: Modification of drawing changes non-alphabetic character

Postby ScapeGoat » Sat Aug 24, 2013 2:47 am

It did occur to me, that it might be the exporter, but there was no way for me to be sure. I have to adjust the text, so I can't convert the text to graphics. Thanks for looking in to it, however. As frustrating and time consuming that this has been, I didn't feel it was appropriate to blame Inkscape because, well, it's open source and it's got a hell of a lot of functionality. It's just up to me to find solutions around the deficiencies.

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Modification of drawing changes non-alphabetic character

Postby tylerdurden » Sun Aug 25, 2013 9:25 am

Ja, seems fonts going out to PDF and coming in from PDF have issues...

https://bugs.launchpad.net/inkscape/+bug/1000507

I don't know how Arial on my machine becomes ArialMT in PDFs generated by Inkscape.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Modification of drawing changes non-alphabetic character

Postby tylerdurden » Sun Aug 25, 2013 10:11 pm

tylerdurden wrote:I don't know how Arial on my machine becomes ArialMT in PDFs generated by Inkscape.

FWIW:
"The font name is "Arial" but the "PostScript name" inside the font (i.e., what displays inside of Acrobat or Reader) of that particular font is "ArialMT" where the "MT" is for Monotype, the font foundry from which it originates."

http://lists.frameusers.com/pipermail/f ... 12745.html
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

ScapeGoat
Posts: 40
Joined: Tue Mar 19, 2013 9:36 am

Re: Modification of drawing changes non-alphabetic character

Postby ScapeGoat » Tue Aug 27, 2013 1:20 am

@Lazur: Simple dropbox (containing SVG) blocked due to corporate firewall policies.

@tylerdurden: I did indeed type over texts, but the actual schematic I'm working with is quite a larger and I'll be exporting schematics from the schematic tool to PDf on a frequent basis. For this reason, I was seeking a solution that wasn't manually intense, such as redoing all text. As for the whacked positioning that you saw in the XML, I merely assumed that per-letter positioning was a manifestation of intense manual kerning.

You suggested uploading an example of the inkscape corruption of text and the repair done by Acrobat. Here it is:

1) test.pdf: File from schematic tool

2) test2.dpf: File after one ungroup of the sole object. Text is corrupted in inkscape, but appears fine in Acrobat.

3) test.3pdf: Repaired file after writing from Acrobat. I'm not sure if I'd attribute the repair to Acrobat, as I actually have to print it via PDF24 printer driver before the things look all right in inkscape. If I merely do Save-As from Acrobt, the file still looks corrupt in inkscape. What acrobat seems to do is be immune to the corruption, and the printing process generates a file that looks free of corruption in inkscape.

Please note that the order in which the files seem to be arranged is the reverse of the order in which they are listed above (and the order in which they were uploaded).
Attachments
test3.pdf
(8.1 KiB) Downloaded 185 times
test2.pdf
(21.47 KiB) Downloaded 189 times
test.pdf
(8.33 KiB) Downloaded 175 times

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Modification of drawing changes non-alphabetic character

Postby tylerdurden » Tue Aug 27, 2013 3:09 am

When the PDF files direct from the schematic app are opened in Inkscape, is the text always intact? (Seems that way here.)

If so, I'd bring drawings from the schematic app into Inkscape, lock the intact text on one layer and on a higher layer mask the text that needs correction with white boxes or circles and type text over.

I'd keep that version (as Inkscape SVG) for a "working document" and only output PDF for release documents.

I wouldn't keep re-opening and revising the same PDF files in Inkscape.

testa.svg
(13.99 KiB) Downloaded 176 times

testa.pdf
(20.28 KiB) Downloaded 186 times
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

ScapeGoat
Posts: 40
Joined: Tue Mar 19, 2013 9:36 am

Re: Modification of drawing changes non-alphabetic character

Postby ScapeGoat » Tue Aug 27, 2013 3:47 am

Afternote: Yes, the text in the initial PDF from the schematic app seems fine when opened in inkscape (at least so far).

Understood re. maintaining the file in SVG format for doctoring up.

I have a question about bringing the text to its own layer and locking it in. The text annotates polygons, which I move when I adjust the schematic (the schematic tool generates high nonideal schematics). What is achieved by moving the text to its own layer?

tylerdurden
Posts: 2344
Joined: Sun Apr 14, 2013 12:04 pm
Location: Michigan, USA

Re: Modification of drawing changes non-alphabetic character

Postby tylerdurden » Tue Aug 27, 2013 4:11 am

A layer for just the text makes it easy to sequester: lock, hide, etc. A habit from GIMP. I'm a klutz, likely to bump or alter objects when tweaking other objects.
Have a nice day.

I'm using Inkscape 0.92.2 (5c3e80d, 2017-08-06), 64 bit win8.1

The Inkscape manual has lots of helpful info! http://tavmjong.free.fr/INKSCAPE/MANUAL/html/

ScapeGoat
Posts: 40
Joined: Tue Mar 19, 2013 9:36 am

Re: Modification of drawing changes non-alphabetic character

Postby ScapeGoat » Tue Aug 27, 2013 4:19 am

OK, thanks.


Return to “Help with using Inkscape”

Who is online

Users browsing this forum: No registered users and 7 guests