Bytefield Svg Versions Save

Node module that generates byte field diagrams in SVG format

v1.8.0

1 year ago

Added

  • It is now possible to change the horizontal alignment of text labels within draw-box using two new box attributes, :text-anchor and :margin.

v1.7.0

1 year ago

Added

  • A new function, char->int, allowing access to the UTF-16 code units of characters. (Thanks to Gert Goet for this contribution!)
  • Access to the JavaScript String object to support the implementation of char->int.

v1.6.1

2 years ago

Fixed

  • The ability to control substitutions, and thereby (for example) use document attributes to reduce duplication, was broken. Thanks to Jared Reisinger for noticing this and contributing a fix!

v1.6.0

2 years ago

Added

  • A new predefined value, svg-attrs, which starts out as an empty map, but can be redefined to add arbitrary SVG attributes to the top-level SVG node of your diagram (for example, to set a background color for the entire diagram).

v1.5.0

3 years ago

Added

  • Two new functions, wrap-link and wrap-svg which allow you to create hyperlinks and arbitrary SVG elements around sections of your drawings.

v1.4.3

4 years ago

Changed

  • defattrs now takes an attribute expression rather than only a resolved attribute map as its second expression, so you can use the concise attribute mini-language to build new attributes based on existing ones.

Added

  • You can now pass :next-row-height as an attribute to draw-box when you need to change row heights as you draw the first box of a new row. This makes it more practical to have variable-height rows, while still having the automatically-drawn row headers appear in the correct posititons.
  • The user guide now shows examples of how to draw vertical text and boxes which span more than two rows but which are not variable-length gaps.

Fixed

  • Short-lived version 1.4.2 was not properly built for release before publishing to npm.

v1.4.1

4 years ago

Fixed

  • Invoking the generate function with a single argument was not working properly any longer because of a problem handling default JavaScript arguments from ClojureScript code. (Sorry, I am really new at the JavaScript/ClojureScript worlds!)
  • Generation of the user guide using the local extension now uses the new embedded SVG tag mode, to avoid HTML structural issues.

https://github.com/Deep-Symmetry/bytefield-svg/compare/v1.4.0...v1.4.1

v1.4.0

4 years ago

Added

  • The svg element is now rendered with a proper viewPort attribute which allows the host page to make it responsive by styling it with max-width="100%".
  • You can generate a bare svg element for inclusion in an HTML document by supplying the command-line flag --embedded or -e, or invoking the generate function with a new second options object in which the property embedded is true.
  • New helper functions to support drawing bit-fields from integers.
  • New helper functions to support drawing padding until a particular address is reached.
  • A draw-inline-gap function to support drawing discontinuities in single-row diagrams.
  • The ClojureScript namespaces clojure.set and clojure.string and the JavaScript Math object are now available for use by your diagram code.

Fixed

  • A new version of the Small Clojure Interpreter is used, which enables dotimes for index-based iteration within diagrams. Previously it would fail because it delegated to the forbidden, potentially non-terminating loop form.

https://github.com/Deep-Symmetry/bytefield-svg/compare/v1.3.0...v1.4.0

v1.3.0

4 years ago
  • Add and document CLI tool 4ed33fe
  • Update guide links. 9ed83f7
  • Remove stray step number [skip ci] a160021
  • Update read me [skip ci] 3a55d9a
  • Document tspan. 1024538
  • Document text function. 472965e
  • Document next-row and eval-attribute-spec. 3e798ab
  • Document draw-row-header. 682bc36
  • Document draw-related-boxes. 9615383
  • Fix formatting issue. [skip ci] 7272d9f
  • Fix argument identification [skip ci] ca82fa7

https://github.com/Deep-Symmetry/bytefield-svg/compare/v1.2.0...v1.3.0

v1.2.0

4 years ago

This release offers a much more convenient way of manipulating the default column labels.

  • Document draw-line. db2cb64
  • Document draw-gap. c8eef3e
  • Document draw-column-headers 618d955
  • Add explicit zero arity for draw-column-headers. 2862ccb
  • Add fill and line style examples, clarify attribute expansion. bfd1dc0
  • Document draw-boxes. 43f57fa
  • Fix typo. 20097b5
  • Document up through draw-box. 14f9215
  • Add skeleton of functions page. a66e51f
  • First draft of Attributes section. 83f5686
  • First draft of default values section. fdf63dd
  • Start documenting predefined values. f6acb2a
  • Fix typo [skip ci] b7ac123
  • Simplify documentation build process immensely [skip ci] d2a6645

https://github.com/Deep-Symmetry/bytefield-svg/compare/v1.1.0...v1.2.0