Skip to main content

Path stroking for UFO glyphs

Project description

nudelo

This Python module implements round path stroking ("noodling") for kurbopy BezPath objects. It currently exports one function, noodle:

from nudelo import noodle
from kurbopy import BezPath
f = ufoLib2.Font("tests/data/Scurve.ufo")
paths = BezPath.from_drawable(f["A"])

new_paths = []
for path in paths:
    new_paths.extend(noodle(path, width=50, start_cap="butt", end_cap="round"))
  

This may also be used as a fontmake command line plugin:

fontmake --filter 'nudelo::NoodleFilter(pre=True,Width=50)' -u OpenPaths.ufo -o ttf

Or by adding a lib key into the UFO file's lib.plist file:

    <key>com.github.googlei18n.ufo2ft.filters</key>
    <array>
      <dict>
        <key>name</key>
        <string>nudelo.NoodleFilter</string>
        <key>pre</key>
        <true/>
        <key>kwargs</key>
        <dict>
            <key>Width</key>
            <integer>50</integer>
            <key>StartCap</key>
            <string>square</string>
            <key>EndCap</key>
            <string>square</string>
            <key>JoinType</key>
            <string>mitre</string>
            <key>RemoveExternal</key>
            <true/>
        </dict>
      </dict>
    </array>

The name "nudelo" is the Esperanto for "noodle".

License

Apache 2.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nudelo-1.0.0.tar.gz (11.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nudelo-1.0.0-py3-none-any.whl (8.6 kB view details)

Uploaded Python 3

File details

Details for the file nudelo-1.0.0.tar.gz.

File metadata

  • Download URL: nudelo-1.0.0.tar.gz
  • Upload date:
  • Size: 11.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for nudelo-1.0.0.tar.gz
Algorithm Hash digest
SHA256 2130270688cab1d8d6aaad264579911e2a9bdef45e8e4b7dd1c5135efcee0439
MD5 5cc9bead3a0d42a99f060672ca090dbc
BLAKE2b-256 e60377ea0cd2fcef9c0bbbc88a2ab073ff808a6b2e75c6837d424b7b3873c0b0

See more details on using hashes here.

File details

Details for the file nudelo-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: nudelo-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 8.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for nudelo-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4e2ed715c83ee9f80969d333da38f61584e0e8f31f131cd9b471b01a6e69f90f
MD5 0d821b3add6954754725c9153b5f630e
BLAKE2b-256 73268ea2a7a78ebc5b38d9c09624dddaa03a842f93a8d62a0bac358915763c13

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page