Skip to content

Releases: EconViz/mosaickit

0.5.1

Choose a tag to compare

@yueswater yueswater released this 03 Oct 09:36
787bb63
  • Markers are drawn whole: a marker centred on the plot edge (such as a point on an axis) is no longer cut in half; one centred outside the plot is left out.

0.5.0

Choose a tag to compare

@yueswater yueswater released this 03 Oct 09:30
ee7246f
  • GridLink and CanvasGrid(..., links=...): a line from a point in one cell to a point in another, drawn across the gaps between cells.
  • ArrowLayer honors dashed, dotted and dash-dot strokes: dashed shaft, solid heads.

MosaicKit v0.4.0

Choose a tag to compare

@yueswater yueswater released this 03 Oct 08:59
048c4a5
  • Add SpanBraceLayer(start, end, label, side): a curly brace between two points
    inside the plot (horizontal span: side "above"/"below"; vertical span:
    "left"/"right"). Its label sits past the tip, covering nothing; when there
    is no room there it moves out on a leader.
  • Inside axis-brace labels gain the same leader fallback when nothing past the
    tip is free (previously they warned and overlapped).

MosaicKit v0.3.2

Choose a tag to compare

@yueswater yueswater released this 03 Oct 08:30
c68bac5
  • Point labels treat a region as theirs only when the point is strictly inside
    it; a point on a region's edge (such as a vertex) keeps its label out of the
    region, as before 0.3.1.

MosaicKit v0.3.1

Choose a tag to compare

@yueswater yueswater released this 03 Oct 08:22
6405674
  • Point labels may sit inside a filled region that contains their point (for
    example a point inside a shaded area); other regions are still avoided.

MosaicKit v0.3.0

Choose a tag to compare

@yueswater yueswater released this 03 Oct 06:23
3cef821
  • Themes and styles refer to colors by palette name (Stroke(color="blue")).
    Names resolve against the active palette (Config.palette) when the render
    plan is built, so changing a color once in the palette, in Python or in a
    TOML [palette] table, recolors every role that names it. Renderers still
    receive only concrete colors.
  • The built-in default theme and primitive defaults name their colors
    (blue, red, teal, white, and the grey-* ramp) instead of holding
    copies of DEFAULT_PALETTE values. Rendered output with the default palette
    is unchanged.
  • An unknown color name raises ConfigurationError naming the role, field,
    and palette. A custom Palette must define the names its theme uses; build
    it from DEFAULT_PALETTE.colors to keep the built-in names.
  • TOML config accepts a [palette] table that defines or overrides named
    colors (accent = "#984EA3") on top of DEFAULT_PALETTE.
  • Style color and edge_color values in TOML accept palette names
    (color = "accent") as well as hex. Unknown names raise
    ConfigurationError naming the file and key when the file is loaded.
  • Config carries the palette: Config(palette=...) in Python, defaulting to
    DEFAULT_PALETTE. Behavior without a palette is unchanged.
  • Add PointLabelLayer(point, text), which places its text right beside a point
    so it covers nothing. It tries 16 directions around the point at a few small
    gaps from the point's marker edge (nearest first, upper-right preferred) and
    takes the closest position that stays inside the axes and touches no line,
    marker, filled region, or other text. The point's own marker is never covered.
    When no position is free it takes the one with fewest overlaps and emits a
    LayoutWarning naming the layer.
  • Point labels are placed before region labels, so region callouts avoid them.
  • Add place_point_label to mosaickit.layout. Placement.leader may be
    None (labels drawn without a leader).
  • Label text is measured with its TextStyle.rotation, so rotated region labels
    are placed using their rotated extent.
  • Add AxisMarkLayer (a symbol next to an axis at a value), AxisNoteLayer (an
    explanation further out), and BraceLayer (a curly brace over a span, with an
    optional label). They work on both the x and y axis.
  • Text outside an axis is laid out in columns running outward: marks, then
    outside braces (one column per lane of overlapping braces), then notes. Marks
    and notes are spread along the axis so none overlap. An inside brace's label is
    placed so it covers no line, point, region, or text, and emits LayoutWarning
    when no such spot exists.
  • Add pure layout modules: mosaickit.layout.geometry.brace_outline,
    mosaickit.layout.stack1d (spread, assign_lanes), mosaickit.layout.gutter,
    and mosaickit.layout.placement.place_beside.
  • Add the axes.note role to the default theme (9 pt, grey-600).
  • Add SaveOptions.expand (default True). Visible change: saving grows the
    canvas to include anything drawn past its edges. It never crops, so a diagram
    that fits keeps its CanvasSpec size. Pass expand=False for the old behaviour.
  • Visible change: build_axes, quadrant_axes, and crosshair_axes place axis
    titles past the arrow tips (the x title to the right, the y title above)
    instead of centred on the tip, where they covered the arrowhead.

MosaicKit v0.2.0

Choose a tag to compare

@yueswater yueswater released this 03 Oct 05:39
d161898
  • TextLayer.anchor accepts top-left, top-right, bottom-left, and
    bottom-right. The anchor names the corner of the text box placed at
    position. Existing anchors behave as before.
  • Arrowheads are no longer clipped to the axes, so axis arrows whose tips sit on
    the boundary draw both wings.
  • Axis presets (build_axes, quadrant_axes, crosshair_axes) draw filled
    triangle arrowheads by default instead of open chevrons. Pass a stroke with
    ArrowStyle.OPEN to keep the old look.
  • PathLayer accepts clip (default True). Axis presets set clip=False
    so axis lines on the plot boundary keep their full stroke width instead of
    losing the outer half.
  • Path arrowheads no longer redraw a solid shaft over the last 15% of the path,
    so dashed arrows stay dashed and axis lines keep a uniform width.
  • Add RegionLabelLayer, which names a filled region. With placement="auto"
    the label goes inside the region when it fits (trying short_text second),
    otherwise it becomes a callout: a thin leader and unboxed text placed so it
    does not cover any line, point, filled region, or other text.
  • Add the pure-geometry mosaickit.layout package that makes those decisions.
  • Add LayoutWarning, emitted when no callout position avoids every obstacle.
  • Add Palette, a named color table, and DEFAULT_PALETTE: a grey ramp
    (grey-900 … grey-100, white) plus blue #01A2D9, red #E3120B,
    and teal #00887D.
  • The default theme now takes every color from DEFAULT_PALETTE. Visible
    change: primary, secondary, and accent become the palette's blue, red,
    and teal (previously ColorBrewer Set1 blue, red, and purple). Neutral greys
    are unchanged.
  • Layers declare style_slots (which field holds their explicit style for each
    style slot), and Matplotlib drawing is driven by a per-type registry. Add
    register_builder and register_pass in mosaickit.rendering.matplotlib
    so other packages can add layer types without changing MosaicKit.
  • themes.resolve accepts overrides, applied in order after the theme.
  • Region-label callouts avoid everything drawn on the axes, including layers
    drawn by registered third-party builders.
  • Built-in renderers are loaded by name on first use; the core no longer
    imports the Matplotlib backend.

MosaicKit v0.1.0

Choose a tag to compare

@yueswater yueswater released this 01 Oct 09:11
83fbb75

What's Changed

  • Decouple MosaicKit from BezierKit by @yueswater in #5
  • docs: add MosaicKit branding and package guide by @yueswater in #6

New Contributors

Full Changelog: https://github.com/EconViz/mosaickit/commits/v0.1.0