Quick disclaimer: there are a couple of subtle extensions to the Expression Language format. They will be available in 0.4.2. They are the colon handling for row functions, and the optional capitalization of all function names. This will go even further to improve clarity and simplify translation. All of these changes will be backwards compatible with the 0.4.x syntax.
[ add comment ] | [ 0 trackbacks ] | permalink
In order to demonstrate the usefulness of writing a markup language for knitting patterns, I have written Gauge Transformer 0.1, the first application in the KnitML Transform sub-project. It takes a pattern's original gauge and transforms it to the gauge you specify, providing simple, row-by-row guidance about alterations. The knitter is informed of the difference between the number of stitches the pattern specifies and the number of stitches they should actually knit. If the row has decreases or increases in it, Gauge Transformer provides the number of stitches expected at the completion of the row.
The complete transformer has been done in one 161-line file (only 92 of which have code). All hail Groovy!
The software is set up very similarly to KnitML. Set the JAVA_HOME environment variable to a Java 5 installation, set the GAUGE_TRANS_HOME to the directory you unzip the download into, and add %GAUGE_TRANS_HOME%\bin to your system path. There is a user's guide in the docs section which describes (oddly enough) correct usage.
Give it a try, and let me know what you think!
[ 1 comment ] ( 31 views ) | [ 0 trackbacks ] | permalink
KnitML 0.4.1 has been released. This is primarily a bug fix version (Bug 31), but also has full Spanish translations for the pattern renderer as well as annotation support for rows.
The annotation support will be very important for the KnitML Gauge Transformer subproject, which will translate a KnitML pattern to any specified gauge. Hopefully I will released 0.1 of Gauge Transformer next week.
[ add comment ] | [ 0 trackbacks ] | permalink
It is my great pleasure to inform you that KnitML 0.4 has been released. Perhaps most significant in this release is the completion of critical chapters to the User's Guide. The guide now provides a full reference to Knitting EL functions and their XML equivalents. Between the function reference, the samples, and the full XML Schema documentation, there should now be plenty to get you started.
Once you've downloaded the zip file, unzip the file to the directory of your choice. For example, if you unzip the file to "C:\Program Files" the KnitML root directory will be "C:\Program Files\knitml-0.4". Open the user's guide (users-guide.html or users-guide.pdf) found in the docs subdirectory of the KnitML root directory. Follow the installation instructions. Sample KnitML files are in the samples subdirectory.
The following new features are now supported by the specification and all of the software:
- Increases
- Stitch crosses (i.e. cables)
- Custom inline / block instruction definitions
- Instruction merging
- Combining block instructions together to be knit simultaneously (e.g. a body pattern repeat with an edge pattern repeat)
There have been some schema changes which will most likely result in incompatibilities with previously written KnitML patterns. The changes are very straightforward and mostly deal with element and attribute name changes. For instance, all attributes with 'idref' in their name became 'ref'. The changes were made to favor simplicity and uniformity across the schema. If you have questions about the specific changes (or why your pattern no longer works), please feel free to contact me and I can help you out.
We need someone who knows Spanish to finish providing a Spanish translation to the pattern renderer / sample patterns. If you are interested, please let me know.
If you have ideas for what kinds of features you would like to see in the 0.5 release, please submit an enhancement request to the issue tracker.
This release has been a long time in coming. Thank you for your continued interest in making the knitting world a better place!
[ 5 comments ] ( 45 views ) | [ 0 trackbacks ] | permalink
The code now uses JiBX to bind from XML to a native Java object model. dom4j is no longer used in the project. The repeat elements have been simplified and AspectJ / Spring contexts are no longer required for correct operation. So those issues are now put to rest.
The instruction and row mechanism is now much simpler. Instructions are now either block instructions (which consist only of rows) or inline instructions (can occur within a row). Block instructions can now be merged together in parallel (by row) or serially (by instruction).
You will soon be able to define a structure which can repeat different sets of instructions together. For instance, a 9-row instruction repeat (e.g. the body of a sweater) and a 2-row repeat (e.g. seed stitch) can be described and processed together. This would have the effect of "work body of sweater to marker, then work seed stitch to end." It's very useful to be able to express this as a designer. Some knitters may prefer to think about the pattern this way, or they may want an explicit set of rows printed out for them. The knitter will have that choice.
In other updates, multiple row definitions per element are now fully processed and supported by the validator.
The downside is that there is a bug in JiBX which, when combined with a major bug in the Maven Assembly Plugin, causes the KnitML build to fail. I think I have a workaround, but it's tenuous and fragile. Hopefully the JiBX issue will be fixed soon and I can unhack by Maven POM.
[ add comment ] | [ 0 trackbacks ] | permalink

Archives



