Python Forum
TTX 3.0 -- From OpenType To XML And Back
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
TTX 3.0 -- From OpenType To XML And Back
#1
I have used this routine previously with Python 2.7 with Adobe's Font Develpoment Kit (FDK) tools which include the .ttx function which exports a TrueType (.ttf) font file to xml, merges a dummy Digital Signature (DSIG) and compiles to a .ttf file again. The .ttf file only needs to have a DSIG table merged into the font for it to be recognised as a valid font in Windows OS. I have the .ttx file AND the .ttf file stored in the same Folder, which is a requirement.

Now that I have updated Python to version 3.7.0 with Adobe's FDK, the same routine fails to work, giving an error of command not found each time. Any help to get me off the starting blocks would be greatly appreciated.

Adrians-iMac-2:Dsig fldr adrianshome$ adddsig /Users/adrianshome/Desktop/Dsig\ fldr/SassoInfProReg.ttf 
-bash: adddsig: command not found
I have also tried
-m
and get
-bash: -m: command not found
Here is my routine for a drag 'n drop form a Folder. . .

Launch Mac OS Terminal
cd Adrians-iMac:~ adrianshome$
Type
 which ttx
/usr/local/bin/ttx
Drag .ttx app to Terminal.

PASTE CODE
FLDR="${HOME}/Desktop/Dsig fldr"
mkdir -p "$FLDR"
cd "$FLDR"
cat > dsig.ttx<<EOF
<?xml version="1.0" encoding="ISO-8859-1"?>
<ttFont sfntVersion="\x00\x01\x00\x00" ttLibVersion="3.0">
<DSIG>
<hexdata>
00000001 00000000
</hexdata>
</DSIG>
</ttFont>
EOF
open .
RETURN
Adrians-iMac:~ adrianshome$ 
ENTER
adddsig (followed by a space)
DRAG FONT FILE TO TERMINAL:
Adrians-iMac:Dsig fldr adrianshome$ adddsig /Users/adrianshome/Desktop/Dsig\ fldr/SassoInfProReg\ copy.ttf


RETURN
Compiling "/Users/adrianshome/Desktop/Dsig fldr/SassoInfProReg.ttx" to "/Users/adrianshome/Desktop/Dsig fldr/SassoInfProReg.ttf"...
Parsing 'DSIG' table...
MERGES ORIGINAL TTF FILE WITH DSIG(check time difference):
Adrians-iMac:~ adrianshome$
Reply


Messages In This Thread
TTX 3.0 -- From OpenType To XML And Back - by Adrian - Oct-11-2018, 01:56 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020