1
0
Fork 0
freesewing/packages/plugin-title
2019-04-19 08:22:59 +02:00
..
src sparkles: Properly formatted title 2019-04-19 08:22:59 +02:00
.editorconfig tada: First commit 2019-04-19 08:22:59 +02:00
.gitignore tada: First commit 2019-04-19 08:22:59 +02:00
.npmignore tada: First commit 2019-04-19 08:22:59 +02:00
LICENSE tada: First commit 2019-04-19 08:22:59 +02:00
package-lock.json sparkles: Properly formatted title 2019-04-19 08:22:59 +02:00
package.json sparkles: Properly formatted title 2019-04-19 08:22:59 +02:00
README.md tada: First commit 2019-04-19 08:22:59 +02:00
rollup.browser.js sparkles: Properly formatted title 2019-04-19 08:22:59 +02:00
rollup.node.js sparkles: Properly formatted title 2019-04-19 08:22:59 +02:00

Freesewing logo

 freesewing
a library for made-to-measure sewing patterns

freesewing / plugins / macro-title

This is a macro for freesewing to add a title to your pattern part.

Install

npm install @freesewing-plugins/macro-title --save

Loading the plugin

Plugins are loaded by the withPlugin method of an instantiated freesewing pattern:

import F from 'freesewing';
import partTitle from '@freesewing-plugins/macro-title';

var pattern = new F.pattern()
  .withPlugin(partTitle);

Using the plugin

This plugin provides the title macro which you can call with the macro method on an instantiated pattern part:

part.macro('title', {
  at: points.titleAnchor
, nr: 2
, name: 'backBlock'
, pattern: 'brian'
});

Parameters

  • at: A point object to anchor the title on
  • nr: The part number
  • name: The part name
  • pattern: The name of the pattern

As all freesewing macros, bundle these parameters into a single object.

Example

FIXME: include example