public sealed class ZplCutPlan
Where a Zebra printer with cutter cuts the labels of one render call (ZplRenderer.LastCutPlan): one ZplLabelCut per printed label plus diagnostics. Rules (ZPL II Programming Guide ^MM, ^PQ, ^XB, ^CN, ^KV, ^JU, ~JK) are described in docs-internal/chaos-printer.md.
Properties
| Property | Type | Description |
CutAfter { get; } | IReadOnlyList<int> | Indexes of the labels after which the printer cuts. |
CutCount { get; } | int | Number of cuts. |
CutsPreviousJob { get; } | bool | A ~JK in this job cut the label that the previous job (an earlier render call) left waiting in ^MMD. |
Diagnostics { get; } | IReadOnlyList<ZplDiagnostic> | Hints such as ^MMD without ~JK or cutter mode without cutter (codes in ZplCutDiagnosticCodes). |
static Empty { get; } | ZplCutPlan | An empty plan (no labels). |
Labels { get; } | IReadOnlyList<ZplLabelCut> | One entry per printed label, in print order. |
Methods
| Method Signature | Returns | Description |
static # Analyze(string zpl, ZplRenderSettings? settings = default) | ZplCutPlan | Renders zpl with a fresh renderer and returns its cut plan (the bitmaps are discarded). Pass the settings of the target printer (dpi, label size, ZplRenderSettings.CutterInstalled, ZplRenderSettings.MaxQuantity). |
# ToJson(bool indented = false) | string | The plan as JSON: {"labels":[{"index":0,"copy":0,"mode":"Cutter","cut":true,"reason":"EveryLabel", "pauseAfter":false,"partialCutMm":0}],"cutAfter":[0],"cutsPreviousJob":false,"diagnostics":[{"code","severity","message","command"}]}. |