Giter Club home page Giter Club logo

css3fontconverter's People

Contributors

arrens-maglr avatar bertyhell avatar patrickheck avatar shehi avatar zoltan-dulac avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

css3fontconverter's Issues

Stylesheet directory

When I run the script on linux, stylesheet.css is generated on the user’s root folder. Maybe the output path could be added as an option?

Cygwin and conversion problem

After installation of cygwin 220 i added a directory css3Font to the cygwin-home and copied some ttf files into c:\cygwin64\home\w1, where also css3Fontconverter resides, but i get the bash - answer after change into that directory : convertFonts.sh not found .
"ls" shows the file - and i have all win10-rights.
"type convertFonts.sh" gives the same not-found - error
---- i changed then to the win10 - cmd , but EOTFAST-1.exe somefont.ttf a.woff (also other formats) gave me (successfully written) several fonts, which are completely unreadable by fontforge.
( Fonts from https://github.com/adobe-fonts/)

Building character ranges or specific subsets?

I'm attempting to convert a 20mb font, and it produces ~20mb files in every format. Is there a way to only convert a subset of the font (eg. only uppercase and lowercase)?

I was able to do this with fontforge using these instructions, but it would be nice to have a cleaner way to do it.

Adobe FDK autohint broken on MacOS 10.9.4

A run with "autohint=adobe" failed to do any autohinting. A quick test with the command line parameters in the script gave this result:

autohint -q -o foobar-Calendas_Plus.otf Calendas_Plus.otf Hinting font Calendas_Plus.otf. Start time: Mon Aug 18 23:32:15 2014. Traceback (most recent call last): File "/Users/xxx/bin/FDK/Tools/osx/../SharedData/FDKScripts/autohint.py", line 1343, in <module> main() File "/Users/xxx/bin/FDK/Tools/osx/../SharedData/FDKScripts/autohint.py", line 1333, in main hintFile(options) File "/Users/xxx/bin/FDK/Tools/osx/../SharedData/FDKScripts/autohint.py", line 1073, in hintFile fdGlyphDict, fontDictList = fontData.getfdInfo(psName, path, options.allow_no_blues, options.noFlex, options.vCounterGlyphs, options.hCounterGlyphs, glyphList) File "/opt/local/libexec/FDK/Tools/SharedData/FDKScripts/BezTools.py", line 1345, in getfdInfo fdDict = self.getFontInfo(fontPSName, inputPath, allow_no_blues, noFlex, vCounterGlyphs, hCounterGlyphs, fdIndex) File "/opt/local/libexec/FDK/Tools/SharedData/FDKScripts/BezTools.py", line 1290, in getFontInfo raise ACFontError("Error: font has neither StemSnapV nor StdVW!") NameError: name 'ACFontError' is not defined

.otf to .ttf

I get this issue during the conversion .otf > .ttf:

SetFontNames: Invalid character in PostScript name token (probably fontname): : /freefont-gnu/FreeSerifBoldItalic

FreeSerifBoldItalic actually doesn’t exist. I just have FreeSerifBoldItalic.otf. Maybe the issue comes from this name?

[Enhancement] Certain font name prefixes are missing (semi vs demi, extra-bold etc)

Hey @zoltan-dulac :

As I was working with certain fonts from Google WebFonts, I noticed you are missing certain font name prefixes when convertFonts.sh is determining the numeric value for font-weight CSS property.

As a basis, let's look at OpenSans fonts: https://github.com/google/fonts/tree/master/apache/opensans

As you can see, this font has SemiBold variants. Your blog at:

http://www.useragentman.com/blog/2013/09/20/better-web-typography-with-font-weight-autohinting-and-font-feature-settings/#comment-911845

does list only DemiBold with weight value of 600. I believe SemiBold also should be treated with the same value.

Additionally, your table in that blog-post also mentions ExtraBold with font-weight value 800. However when I converting OpenSans, I got following CSS output:

@font-face {
  font-family: 'OpenSans';
  src: url('public/fonts/opensans/OpenSans-ExtraBold.eot?') format('eot'),
       url('public/fonts/opensans/OpenSans-ExtraBold.woff2') format('woff2'),
       url('public/fonts/opensans/OpenSans-ExtraBold.woff') format('woff'),
       url('public/fonts/opensans/OpenSans-ExtraBold.ttf')  format('truetype');
  font-weight: 700;
  font-style: normal;
}

As you can see the font-weight value in the output is 700 instead of 800. Is this a bug?

That's it for the moment. Thanks a lot for such a wonderful tool! :)

--autohint gives "No such file or directory"

% ./convertFonts.sh --autohint SourceSansPro-Regular.ttf
Hinting SourceSansPro-Regular.ttf ...
ttfautohint: unrecognized option '--components'
Converting hinted-SourceSansPro-Regular to eot (hinted-SourceSansPro-Regular.ttf)
which: no EOTFAST-1 in (/usr/local/sbin:/usr/local/bin:/usr/bin)
(Using ttf2eot)
could not open input file hinted-SourceSansPro-Regular.ttf, No such file or directory
Converting hinted-SourceSansPro-Regular to svg
PythonUI_Init()
Converting hinted-SourceSansPro-Regular to woff
# fatal error: unable to open file hinted-SourceSansPro-Regular.ttf
Writing Stylesheet ...
Font: hinted-PythonUI_Init()
grep: hinted-SourceSansPro-Regular.svg: No such file or directory
DONE!

Script fails when there are spaces in filename.

I have a font called 'Playlist Script.otf'. When I pass it to the script (./convertFonts.sh 'Playlist Script.otf'), I get an error One of the files you want to convert (Playlist) is not a file. Bailing.

Typo in line 529 prevents TTF files to be generated

#.. If this is an OTF Font, then convert it to TTF. if [ "$IS_OTF" = "0" ] then if [ ! -f $FIL E_STUB.ttf ] then toTTF $NEW_FILE fi NEW_FILE="$FILE_STUB.ttf" fi

The space in if [ ! -f $FILE_STUB.ttf ] should be removed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.