diff --git a/crates/engine/src/cmd/layout.rs b/crates/engine/src/cmd/layout.rs index c1af5d4944..ee6f5d55c0 100644 --- a/crates/engine/src/cmd/layout.rs +++ b/crates/engine/src/cmd/layout.rs @@ -7,14 +7,14 @@ use std::sync::LazyLock; use rustgis_geom::{Coord, Extent}; use rustgis_map::layout::{ - Arrange, ArrowStyle, Background, CHART_BAR, CHART_BARS, CHART_OUTLINE, ChartOrder, ChartOutline, ClassLabels, CoordFormat, ElementKind, - ExtentIndicator, FeatureCounts, FontFamily, FrameShape, GRID_LABEL_PT, Grid, GridEdges, GridKind, GridStyle, Guides, LAYOUT_TEXT_SIZE, - LINE_SPACING, LayerNames, Layout, LegendFit, LegendSizes, LineDir, LineHead, MAX_CHART_BARS, MAX_CHART_DECIMALS, - MAX_CHART_OUTLINE_WIDTH, MAX_COLORBAR_TICKS, MAX_GRID_WIDTH, MAX_GUIDES, MAX_LEGEND_COLUMNS, MAX_LEGEND_LABEL_CHARS, MAX_LEGEND_LABELS, - MAX_LINE_SPACING, MAX_SCALE_BEFORE_ZERO, MAX_SCALE_DECIMALS, MAX_SCALE_DIVISIONS, MAX_SCALE_SUBDIVISIONS, MAX_SECTIONS, MAX_TICK_MM, - MAX_UNIT_LABEL_CHARS, MIN_ELEMENT_MM, MIN_LINE_SPACING, MapSeries, Orientation, PAGES, SCALE_BAR_TEXT_PT, ScaleBarFit, ScaleBarStyle, - ScaleLabelPosition, ScaleUnits, Section, SectionLine, TABLE_TEXT_PT, TextAlign, TextCase, TextVAlign, TickSide, UnitLabelPosition, - fit_scale, line_angle, line_at_angle, line_length, + Arrange, ArrowStyle, Background, CHART_BAR, CHART_BARS, CHART_OUTLINE, COLORBAR_TEXT_PT, ChartOrder, ChartOutline, ClassLabels, + CoordFormat, ElementKind, ExtentIndicator, FeatureCounts, FontFamily, FrameShape, GRID_LABEL_PT, Grid, GridEdges, GridKind, GridStyle, + Guides, LAYOUT_TEXT_SIZE, LINE_SPACING, LayerNames, Layout, LegendFit, LegendSizes, LineDir, LineHead, MAX_CHART_BARS, + MAX_CHART_DECIMALS, MAX_CHART_OUTLINE_WIDTH, MAX_COLORBAR_DECIMALS, MAX_COLORBAR_TICKS, MAX_GRID_WIDTH, MAX_GUIDES, MAX_LEGEND_COLUMNS, + MAX_LEGEND_LABEL_CHARS, MAX_LEGEND_LABELS, MAX_LINE_SPACING, MAX_SCALE_BEFORE_ZERO, MAX_SCALE_DECIMALS, MAX_SCALE_DIVISIONS, + MAX_SCALE_SUBDIVISIONS, MAX_SECTIONS, MAX_TICK_MM, MAX_UNIT_LABEL_CHARS, MIN_ELEMENT_MM, MIN_LINE_SPACING, MapSeries, Orientation, + PAGES, SCALE_BAR_TEXT_PT, ScaleBarFit, ScaleBarStyle, ScaleLabelPosition, ScaleUnits, Section, SectionLine, TABLE_TEXT_PT, TextAlign, + TextCase, TextVAlign, TickSide, UnitLabelPosition, fit_scale, line_angle, line_at_angle, line_length, }; use rustgis_map::report::StatKind; use rustgis_map::symbology::{Dash, MAX_DASH_STEP, MAX_DASH_STEPS}; @@ -221,7 +221,7 @@ pub fn commands() -> Vec { r##""layerOrder"?: [layer names] (legend: these layers first, in this order, the others after them as the map draws them; the map is not changed), "##, r##""columnBreaks"?: [layer names] (legend: each of these layers starts a column, 5 at most, so "columns" above 1 and the fits that add columns are refused beside them), "##, r##""columns"?: 1..6 (legend: the columns its rows are laid in; default 1; with a fit that adds columns, the fewest it starts from), "##, - r##""textSize"?: points, 4 to 100 (legend: its layers' names and classes' labels, its title, rows, swatches and gaps following in proportion and a point symbol keeping the size the map draws it at; default 9; scaleBar: its labels, the room over the bar and between them following, the bar keeping its size; default 8; table: its text, its rows and columns following; default 8; refused outside that range, and for other kinds unless null, as showNoData is), "##, + r##""textSize"?: points, 4 to 100 (legend: its layers' names and classes' labels, its title, rows, swatches and gaps following in proportion and a point symbol keeping the size the map draws it at; default 9; scaleBar: its labels, the room over the bar and between them following, the bar keeping its size; default 8; table: its text, its rows and columns following; default 8; colorbar: its labels, the bar making room for them; default 8; refused outside that range, and for other kinds unless null, as showNoData is), "##, r##""classLabels"?: {"": {"": ""}} (legend: its own text for a class, by the label the layer shows for it, up to 200 characters; the layer keeps its label; a layer or class it can't find is refused), "##, r##""sizes"?: "rows" (default) | "nested" (legend: a point layer's rows of marker sizes drawn as one block, the markers one inside another on a common base, each led to its value; refused for other kinds), "##, r##""showCounts"?: bool (legend: each class row, and a one-symbol layer's row, ends in the number of features the layer's filters keep; default false; none for rasters, web layers, size and diagram rows, layers read in place other than from a local Shapefile, GeoPackage, FlatGeobuf or GeoParquet (each of those is read whole to count), or Unique Values by an expression over too many features and classes; refused for other kinds), "##, @@ -250,7 +250,7 @@ pub fn commands() -> Vec { r##""other"?: bool (chart: the bars past "bars" gathered in a last Other bar, its statistic over their features, their sum when not grouped, last whatever the order; default false: left out, which a warning says, as it says features with no number left out), "##, r##""stack"?: a field (chart, grouped by another field, summing or counting: each bar split by this field's values, a stretch per value in the key over the bars, the values its bars show by their total, largest first (A to Z when ordered by category), past 8 values 7 and a grey Other, which a warning counts; in the palette diagrams take, or with classes in the colour each value's features share on the map, a value with several keeping its palette colour, which a warning counts; values written are the bar's total; default none), "##, r##""values"?: bool (chart: each bar's value written past its end, its thousands apart with commas; default false), "##, - r##""decimals"?: "auto" (the default: a chart's values up to 2, the zeros they end in dropped; a scale bar's labels each the decimals it needs, as before)|0..6 (chart: its values' decimals)|0..3 (scaleBar: its labels' decimals, fixed, with the thousands set apart), "##, + r##""decimals"?: "auto" (the default: a chart's values up to 2, the zeros they end in dropped; a scale bar's labels each the decimals it needs, as before)|0..6 (chart: its values' decimals)|0..3 (scaleBar: its labels' decimals, fixed, with the thousands set apart)|0..6 (colorbar: its labels' decimals, fixed, with the thousands set apart; "auto", its default, shortens classes' and values' labels), "##, r##""barColor"?: "#RRGGBB"|"#RRGGBBAA" (chart: its bars' colour, default #3B82C4), "##, r##""classes"?: bool (chart: each bar in the colour its features have on the map, by the layer's symbology classes: a bar per feature its feature's, a grouped bar the colour its features share; a bar whose features have several, which a warning counts, and an Other bar keep barColor; default false), "##, r##""labelAlign"?: "left" (the default)|"right" (chart: bars running across have their labels at the left of their column, or at its right against the bars), "##, @@ -340,7 +340,7 @@ pub fn commands() -> Vec { r##""labels"?: {"": "