Giter Club home page Giter Club logo

sfont's People

Contributors

danielecapo avatar davelab6 avatar dented42 avatar samth 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

sfont's Issues

Read and write ufos

The file ufo-read-write.rkt could be split in smaller modules.
While reading a ufo it should signal errors in the file.

Thoughts about improving this project

It's been a very long time since I worked on Sfont. My idea is that the improvements that can be implemented, starting from the v1.2 branch, are:

  • Better UFOs read and write (maybe instead of rewriting all glyphs files the library should be able to only rewrite the glyphs changed);
  • Maybe add some functions to deal with Beziér curves and/or making the Bezier curves functions a separate package (it can be useful for other things than fonts);
  • At the moment accessing and "changing" things inside the hierarchy of structures is not so easy. For example, a user typically would like to move a point of a glyph inside a font, making this in a "functional" style is complicated with deeply nested structures like fonts;
  • Interpolation space should be able to represent interpolations using the model defined in the OpenType specs;
  • The documentation should be rewritten
  • Maybe macros to write new fonts should be redesigned and, possibly, transformed in some kind of “domain specific language”.

Anyone is interested in suggesting improvements?

Package does not install

Matthew Butterick plugged your package, but unfortunately it does not install in racket's HEAD.
racket/racket/share/pkgs/sfont/parametric/mf-paths.rkt:2:9: cannot open module file
module path: #path:/home/ianj/racket/racket/share/pkgs/sfont/parametric/vec.rkt
path: /home/ianj/racket/racket/share/pkgs/sfont/parametric/vec.rkt
system error: No such file or directory; errno=2
context...:
standard-module-name-resolver
/home/ianj/racket/racket/collects/compiler/cm.rkt:345:0: compile-zo*
/home/ianj/racket/racket/collects/compiler/cm.rkt:552:26
/home/ianj/racket/racket/collects/compiler/cm.rkt:545:42
/home/ianj/racket/racket/collects/compiler/cm.rkt:510:0: maybe-compile-zo
/home/ianj/racket/racket/collects/compiler/cm.rkt:622:2: do-check
/home/ianj/racket/racket/collects/compiler/cm.rkt:703:4
/home/ianj/racket/racket/collects/setup/parallel-do.rkt:420:20: loop

sfont-examples/fontwrite-square.rkt violates pict contract

Attempting to execute the square example yields the following error:

dc: contract violation;
 draw proc does not restore the dc state after being called
      draw: #<procedure:...ate/fontpict.rkt:132:6>
  in: (->i
       ((draw
         (-> (is-a?/c dc<%>) real? real? any))
        (w real?)
        (h real?))
       ((d (or/c #f real?)) (a (or/c #f real?)))
       #:pre/name
       (draw)
       "draw proc does not restore the dc state after being called"
       (... draw)
       (p pict?))
  contract from: <pkgs>/pict-lib/pict/main.rkt
  blaming: <pkgs>/sfont/sfont/private/fontpict.rkt
   (assuming the contract is correct)
  at: <pkgs>/pict-lib/pict/main.rkt:73.3

Documentation for font creation is insufficient.

The documentation for font. is sparse. glyph. and component. have no documentation. the square font writer example does give some insight, though it doesn't mention component. at all.

Documentation for these should include descriptions of the functionality, examples, and a more complete BNF grammar for those forms.

Problems in space, parametric and navigator macros

The modules sfont/parametric, sfont/space and sfont/navigator uses a lot of literal-ids in macros (probably not a really good design choice), but they are not defined.
The next commits will fix this and will start to split code in smaller modules.

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.