From f54a3faa39a7118c2380a40eef9478db2c9062ae Mon Sep 17 00:00:00 2001 From: dotCooCoo Date: Mon, 16 Nov 2026 03:24:48 -0800 Subject: [PATCH] Packaging Tools: Check Fold Lines reports overshooting and stacked fold lines - A crease that runs past the cut outline by the tolerance or more is reported as outside, though its hinge is still built. - Two lines that fold, of any role, on top of each other are reported as duplicate; a line drawn twice is still checked for where it lies. - Hidden lines are left out in every scope, members of a selected group included. - The ids scope gets its own noCut message. - The notStraight, ambiguous and summary texts say what the check finds: the summary counts hinges, not creases. - The fold angle fields, which nothing in this change reads, are removed. - A window drawn as open cut lines stays a hole when a cut line crosses it or when slits join it to an outline of open lines, so that three lines meet at a corner. Cut lines drawn whole that cross a cell leave it material. - A slot drawn across the outline is a notch, not a hole, as when the notch is drawn in the outline; a crease in it lies outside the blank. - notStraight measures each hinge piece at its farthest point from the hinge line instead of at five samples. - Cut lines drawn on top of each other so many times that the gap search would look at more than 16,777,216 pairs are reported as tooComplex before the search. --- .../engine/src/cmd/addons/packaging/check.rs | 19 +- .../src/cmd/addons/packaging/check/tests.rs | 15 + crates/three-d/src/fold.rs | 353 ++++++++++++++---- crates/three-d/src/fold/tests.rs | 192 +++++++++- crates/three-d/src/lib.rs | 2 + crates/ui-egui/src/addons/packaging.rs | 2 +- crates/ui-egui/src/addons/packaging/tests.rs | 24 +- crates/ui-egui/src/i18n/bg.tsv | 11 +- crates/ui-egui/src/i18n/bs.tsv | 11 +- crates/ui-egui/src/i18n/ca.tsv | 11 +- crates/ui-egui/src/i18n/cs.tsv | 11 +- crates/ui-egui/src/i18n/da.tsv | 11 +- crates/ui-egui/src/i18n/de.tsv | 11 +- crates/ui-egui/src/i18n/el.tsv | 11 +- crates/ui-egui/src/i18n/es.tsv | 11 +- crates/ui-egui/src/i18n/fi.tsv | 11 +- crates/ui-egui/src/i18n/fr.tsv | 11 +- crates/ui-egui/src/i18n/gu.tsv | 11 +- crates/ui-egui/src/i18n/hi.tsv | 11 +- crates/ui-egui/src/i18n/hu.tsv | 11 +- crates/ui-egui/src/i18n/id.tsv | 11 +- crates/ui-egui/src/i18n/it.tsv | 11 +- crates/ui-egui/src/i18n/ja.tsv | 11 +- crates/ui-egui/src/i18n/ka.tsv | 11 +- crates/ui-egui/src/i18n/ko.tsv | 11 +- crates/ui-egui/src/i18n/nl.tsv | 11 +- crates/ui-egui/src/i18n/pl.tsv | 11 +- crates/ui-egui/src/i18n/pt-br.tsv | 11 +- crates/ui-egui/src/i18n/ru.tsv | 11 +- crates/ui-egui/src/i18n/sv.tsv | 11 +- crates/ui-egui/src/i18n/tr.tsv | 11 +- crates/ui-egui/src/i18n/uk.tsv | 11 +- crates/ui-egui/src/i18n/vi.tsv | 11 +- crates/ui-egui/src/i18n/zh-hans.tsv | 11 +- crates/ui-egui/src/i18n/zh-hant.tsv | 11 +- docs/mcp.md | 14 +- 36 files changed, 681 insertions(+), 248 deletions(-) diff --git a/crates/engine/src/cmd/addons/packaging/check.rs b/crates/engine/src/cmd/addons/packaging/check.rs index 59f195d4df..da8f7f25dd 100644 --- a/crates/engine/src/cmd/addons/packaging/check.rs +++ b/crates/engine/src/cmd/addons/packaging/check.rs @@ -22,7 +22,7 @@ pub fn specs() -> Vec { "Check Fold Lines", ["Object", "Plug-ins", "Packaging Tools"], None, - "{ids?: [id…] (default: the selection), select?: bool (false), tolerance?: pt 0.01..10 (0.1)} check the fold lines (addon.packaging.roles) among the objects (through groups and clip groups), or, while nothing is selected and ids is left out, every fold line of the document that is shown. Cut lines bound the blanks: each connected piece of them that encloses material is one blank, its outline is its largest closed cut line, and a closed cut line inside it is a hole, so a slot drawn as a rectangle across the outline leaves the same material as a notch drawn in it; open cut lines that meet end to end count as one closed cut line. Crease, Partial Cut and Perforation lines divide a blank into panels; the pieces of them between two panels are that pair's hinge. A cut line end that comes within tolerance of another cut line is joined to it. Issues, in this order: noCut, open, looseEnd (errors), gap (a warning: the gap is closed), tooComplex (an error: more than 65,536 segments or 256 panels in a blank), cutOverCrease (an error), duplicate, danglingCrease, noSplit, outside, notStraight (it folds along the line through its longest piece), sliver, ambiguous, loosePanel (joined to the largest panel by no chain of hinges), nonPrinting (warnings). With select, the objects the issues name become the selection, unless no issue names one. Changes nothing in the document → {ok (no error), blanks, panels, hinges, holes, issues: [{severity: error|warning, code, message (English), ids, at?: [x, y]}], scope: ids|selection|document}", + "{ids?: [id…] (default: the selection), select?: bool (false), tolerance?: pt 0.01..10 (0.1)} check the fold lines (addon.packaging.roles) among the objects (through groups and clip groups), or, while nothing is selected and ids is left out, every fold line of the document; hidden lines are left out, also in a selected group. Cut lines bound the blanks: each connected piece of them that encloses material is one blank, its outline is its largest closed cut line, and a closed cut line inside it is a hole, so a slot drawn as a rectangle across the outline leaves the same material as a notch drawn in it; open cut lines that meet end to end count as one closed cut line. Crease, Partial Cut and Perforation lines divide a blank into panels; the pieces of them between two panels are that pair's hinge. A cut line end that comes within tolerance of another cut line is joined to it. Issues, in this order: noCut, open, looseEnd (errors), gap (a warning: the gap is closed), tooComplex (an error: more than 65,536 segments or 256 panels in a blank), cutOverCrease (an error), duplicate (two cut lines, or two lines that fold of any role), danglingCrease, noSplit, outside (wholly, or in part for tolerance or more), notStraight (a hinge's pieces are not on one straight line), sliver, ambiguous, loosePanel (joined to the largest panel by no chain of hinges), nonPrinting (warnings). With select, the objects the issues name become the selection, unless no issue names one. Changes nothing in the document → {ok (no error), blanks, panels, hinges, holes, issues: [{severity: error|warning, code, message (English), ids, at?: [x, y]}], scope: ids|selection|document}", has_doc, check )] @@ -32,19 +32,20 @@ pub fn specs() -> Vec { fn message(code: IssueCode, scope: &str) -> &'static str { match code { IssueCode::NoCut if scope == "document" => "No cut lines are in the document.", + IssueCode::NoCut if scope == "ids" => "No cut lines are among the given objects.", IssueCode::NoCut => "No cut lines are in the selection.", IssueCode::Open => "The cut lines do not enclose an area.", IssueCode::LooseEnd => "A cut line ends without meeting another cut line.", IssueCode::Gap => "A gap between cut lines was closed.", IssueCode::TooComplex => "The fold lines are too complex to check.", IssueCode::CutOverCrease => "A cut line and a crease lie on top of each other.", - IssueCode::Duplicate => "Two lines of the same role lie on top of each other.", + IssueCode::Duplicate => "Two fold lines lie on top of each other.", IssueCode::DanglingCrease => "A crease ends inside a panel.", IssueCode::NoSplit => "A crease does not divide two panels.", - IssueCode::Outside => "A crease lies outside the cut outline.", - IssueCode::NotStraight => "A crease that is not straight is folded along one straight line.", + IssueCode::Outside => "A crease lies outside the cut outline, wholly or in part.", + IssueCode::NotStraight => "The pieces of a hinge are not on one straight line.", IssueCode::Sliver => "A gap between cut lines is too narrow to tell apart.", - IssueCode::Ambiguous => "A cut-out area holds other fold lines.", + IssueCode::Ambiguous => "A cut-out area holds other fold lines or another blank.", IssueCode::LoosePanel => "A panel is not joined to the rest by a crease.", IssueCode::NonPrinting => "A fold line is on a non-printing layer.", } @@ -110,9 +111,11 @@ fn check(s: &mut Session, p: &Value) -> Result { let given = p.get("ids").is_some_and(|v| !v.is_null()); let roots = checked_ids_or_selection(s, p, CHECK)?; let d = &s.doc()?.doc; + // Hidden lines are left out in every scope, members of a selected group included. + let shown = |ids: Vec| ids.into_iter().filter(|id| d.is_visible(*id)).collect::>(); let (scope, targets) = match (given, roots.is_empty()) { - (true, _) => ("ids", role_targets(d, &roots, false).0), - (false, false) => ("selection", role_targets(d, &roots, false).0), + (true, _) => ("ids", shown(role_targets(d, &roots, false).0)), + (false, false) => ("selection", shown(role_targets(d, &roots, false).0)), (false, true) => ("document", shown_targets(d)), }; let table = RoleTable::of(d); @@ -131,7 +134,7 @@ fn check(s: &mut Session, p: &Value) -> Result { non_printing.push(id.0); } segments = segments.saturating_add(path.subpaths.iter().map(|sp| sp.segment_count()).sum()); - lines.push(FoldLine { path, kind: kind(role), angle: None, key: id.0 }); + lines.push(FoldLine { path, kind: kind(role), key: id.0 }); } let (found, mut issues) = blanks(&lines, tolerance); if !non_printing.is_empty() { diff --git a/crates/engine/src/cmd/addons/packaging/check/tests.rs b/crates/engine/src/cmd/addons/packaging/check/tests.rs index 427656fc29..9940761dea 100644 --- a/crates/engine/src/cmd/addons/packaging/check/tests.rs +++ b/crates/engine/src/cmd/addons/packaging/check/tests.rs @@ -62,6 +62,9 @@ fn the_selection_or_ids_limit_the_check_to_their_lines() { assert_eq!(r["issues"][0]["message"], "No cut lines are in the selection."); let r = check(&mut s, json!({ "ids": [outline] })); assert_eq!((r["scope"].as_str(), r["ok"].as_bool(), r["panels"].as_u64()), (Some("ids"), Some(true), Some(1)), "{r}"); + let r = check(&mut s, json!({ "ids": [creases[1]] })); + assert_eq!((r["scope"].as_str(), codes(&r)), (Some("ids"), vec!["noCut"])); + assert_eq!(r["issues"][0]["message"], "No cut lines are among the given objects."); // No fold lines at all in the document. let mut s = session(); let r = check(&mut s, json!({})); @@ -135,6 +138,18 @@ fn hidden_lines_are_left_out_and_lines_on_a_non_printing_layer_are_noted() { s.execute("select.none", &json!({})).unwrap(); let r = check(&mut s, json!({})); assert_eq!((r["panels"].as_u64(), r["hinges"].as_u64()), (Some(4), Some(3)), "{r}"); + // The same in a selected group, and with the group named by `ids`: the hidden member is left + // out too. + let mut s = session(); + let (outline, creases) = tray(&mut s); + s.execute("select.set", &json!({ "ids": [outline, creases[0], creases[1], creases[2], creases[3]] })).unwrap(); + let group = s.execute("object.group", &json!({})).unwrap()["id"].as_u64().unwrap(); + s.execute("layer.setProps", &json!({ "ids": [creases[0]], "visible": false })).unwrap(); + s.execute("select.set", &json!({ "ids": [group] })).unwrap(); + for p in [json!({}), json!({ "ids": [group] })] { + let r = check(&mut s, p); + assert_eq!((r["panels"].as_u64(), r["hinges"].as_u64()), (Some(4), Some(3)), "{r}"); + } // A cut line on a layer that does not print. let mut s = session(); s.execute("layer.new", &json!({ "printable": false })).unwrap(); diff --git a/crates/three-d/src/fold.rs b/crates/three-d/src/fold.rs index c68f8aa6ca..2dbff773f9 100644 --- a/crates/three-d/src/fold.rs +++ b/crates/three-d/src/fold.rs @@ -12,7 +12,7 @@ use std::collections::{HashMap, HashSet}; use vectorcraft_geom::kurbo::{Line, ParamCurveArclen, ParamCurveNearest, PathSeg}; -use vectorcraft_geom::{BezPath, FillRule, ParamCurve, PathData, Point, Rect, Shape as _, SubPath}; +use vectorcraft_geom::{Affine, BezPath, FillRule, ParamCurve, PathData, Point, Rect, Shape as _, SubPath}; use vectorcraft_pathops::{Adjacency, DEFAULT_PRECISION, SHAPE_BUILDER_MAX_SEGMENTS, Shape, adjacency, find_gaps, interior_point, unite_all}; /// Most panels one blank may have. Its hinges are the edges of a planar graph on its panels, so there @@ -34,26 +34,11 @@ pub enum LineKind { Perforation, } -impl LineKind { - /// The angle a line of this kind folds at when it has none of its own, in degrees: Crease and - /// Perforation 90, Partial Cut -90 (VectorCraft's own values); a positive angle folds away from - /// the printed side. A Cut line does not fold: 0. - pub fn default_angle(self) -> f64 { - match self { - LineKind::Cut => 0.0, - LineKind::Crease | LineKind::Perforation => 90.0, - LineKind::PartialCut => -90.0, - } - } -} - -/// A fold line: the path (document coordinates), its kind, its own fold angle in degrees if it has -/// one, and a key the issues name it by. +/// A fold line: the path (document coordinates), its kind, and a key the issues name it by. #[derive(Clone, Debug)] pub struct FoldLine { pub path: PathData, pub kind: LineKind, - pub angle: Option, pub key: u64, } @@ -72,17 +57,16 @@ pub struct Panel { pub area: f64, } -/// The fold between panels `a` and `b` (indices into the blank's panels, `a` < `b`), about the -/// straight line from `from` to `to`, at `angle` degrees, made of the lines `keys`. `straight` is -/// false when its pieces are not on one straight line within the tolerance; it then folds about the -/// line through its longest piece. +/// The hinge between panels `a` and `b` (indices into the blank's panels, `a` < `b`): the straight +/// line from `from` to `to`, made of the lines `keys`. `straight` is false when its pieces are not on +/// one straight line within the tolerance; `from` and `to` are then on the line through its longest +/// piece. #[derive(Clone, Debug)] pub struct Hinge { pub a: usize, pub b: usize, pub from: Point, pub to: Point, - pub angle: f64, pub keys: Vec, pub straight: bool, } @@ -105,13 +89,14 @@ pub enum IssueCode { TooComplex, /// A Cut line and a crease lie on top of each other. CutOverCrease, - /// Two lines of the same kind lie on top of each other. + /// Two Cut lines, or two of the lines that fold (of the same kind or not), lie on top of each + /// other. Duplicate, /// A crease ends inside a panel. DanglingCrease, /// A crease divides no two panels. NoSplit, - /// A crease lies outside every blank. + /// A crease lies outside every blank, wholly, or in part for the tolerance or more. Outside, /// A hinge's pieces are not on one straight line. NotStraight, @@ -221,6 +206,9 @@ pub fn blanks(lines: &[FoldLine], tolerance: f64) -> (Vec, Vec) { return (vec![], vec![Issue::new(IssueCode::NoCut, vec![], None)]); } let folds: Vec<&Piece> = pieces.iter().filter(|p| kind(p) != LineKind::Cut).collect(); + if !gap_work_fits(&cuts, tolerance) { + return (vec![], vec![Issue::new(IssueCode::TooComplex, vec![], None)]); + } let cut_shapes: Vec = cuts.iter().map(|p| shape(p.sp.clone())).collect(); let gaps = find_gaps(&cut_shapes, tolerance); // `find_gaps` takes ends closer than 1/10,000 of the tolerance as joined, which the map may not @@ -271,6 +259,33 @@ pub fn blanks(lines: &[FoldLine], tolerance: f64) -> (Vec, Vec) { (built, sorted(issues)) } +/// Most (open end, Cut segment) pairs within the tolerance of each other that the gap search may +/// look at. +const MAX_GAP_CANDIDATES: usize = 1 << 24; + +/// Whether the gap search over `cuts` stays within [`MAX_GAP_CANDIDATES`]: it looks at the Cut +/// segments within `tolerance` of each open end, and lines drawn on top of each other many times +/// over make that work grow with the square of their number. The count stops at the limit. +fn gap_work_fits(cuts: &[&Piece], tolerance: f64) -> bool { + let boxes: Vec<(Rect, usize)> = cuts + .iter() + .flat_map(|p| { + PathData::single(p.sp.clone()).to_bezpath().segments().map(|s| s.bounding_box().inflate(tolerance, tolerance)).collect::>() + }) + .enumerate() + .map(|(i, b)| (b, i)) + .collect(); + let grid = Cells::new(boxes, 2.0 * tolerance, 4096.0); + let mut work = 0usize; + for e in cuts.iter().flat_map(|p| ends(&p.sp)) { + work = work.saturating_add(grid.near(e, 0.0).len()); + if work > MAX_GAP_CANDIDATES { + return false; + } + } + true +} + fn sorted(mut issues: Vec) -> Vec { issues.sort_by_key(|i| i.code); issues @@ -429,8 +444,9 @@ fn contains(bp: &BezPath, p: Point) -> bool { /// The loops that open Cut pieces and the lines across `gaps` make end to end: each chain of them /// whose every end meets exactly one end of another piece of the chain (within 1e-6), as (index -/// into `cuts` of its first Cut piece, closed path). Pieces that lie on no cycle are left out first; -/// ends where three of the remaining pieces or more meet join nothing. +/// into `cuts` of its first Cut piece, closed path). Pieces that lie on no cycle are left out first. +/// A connected set of the remaining pieces with an end where three or more meet gives the outlines +/// of the faces it encloses instead. fn chains(cuts: &[&Piece], gaps: &[[Point; 2]]) -> Vec<(usize, BezPath)> { const NEAR: f64 = 1e-6; // Cell numbers stay far from the ends of `i64`, so a neighbor's number does not overflow. @@ -477,8 +493,49 @@ fn chains(cuts: &[&Piece], gaps: &[[Point; 2]]) -> Vec<(usize, BezPath)> { for ks in at.values_mut() { ks.retain(|&k| live.get(k) == Some(&true)); } + // The connected pieces of what is left, by node. In a piece where some node joins more than two + // pieces (a window with a cut across it), the loop is the outline of the faces the piece + // encloses; the other pieces are walked end to end below. + let mut group: Vec = (0..firsts.len()).collect(); + for (k, &(_, a, b)) in open.iter().enumerate() { + if live.get(k) == Some(&true) { + let (ra, rb) = (root_of(&mut group, a), root_of(&mut group, b)); + if let Some(slot) = group.get_mut(ra) { + *slot = rb; + } + } + } + let mut branched: HashSet = HashSet::new(); + for (&n, ks) in &at { + if !ks.is_empty() && ks.len() != 2 { + branched.insert(root_of(&mut group, n)); + } + } let mut used: Vec = live.iter().map(|l| !l).collect(); let mut out = vec![]; + let mut joined: HashMap> = HashMap::new(); + for (k, &(_, a, _)) in open.iter().enumerate() { + let r = root_of(&mut group, a); + if used.get(k) == Some(&false) && branched.contains(&r) { + joined.entry(r).or_default().push(k); + if let Some(u) = used.get_mut(k) { + *u = true; + } + } + } + let mut joined: Vec> = joined.into_values().collect(); + joined.sort_unstable(); + for ks in joined { + let Some(first_cut) = ks.iter().filter_map(|&k| open.get(k).and_then(|&(j, _, _)| items.get(j)).and_then(|(i, _)| *i)).min() else { + continue; + }; + let shapes: Vec = ks + .iter() + .filter_map(|&k| open.get(k).and_then(|&(j, _, _)| items.get(j))) + .map(|(_, segs)| Shape::new(PathData::from_bezpath(&BezPath::from_path_segments(segs.iter().copied())), FillRule::NonZero, 0)) + .collect(); + out.extend(enclosed_loops(&shapes).into_iter().map(|bp| (first_cut, bp))); + } for start in 0..open.len() { if used.get(start) != Some(&false) { continue; @@ -534,6 +591,95 @@ fn chains(cuts: &[&Piece], gaps: &[[Point; 2]]) -> Vec<(usize, BezPath)> { out } +/// The loops of a connected set of open Cut pieces `shapes` where some end joins three pieces or +/// more: the outline of all the faces they enclose, and for each group of faces that meet only other +/// faces and are bounded by pieces that meet end to end (a window joined to an outline by two slits, +/// not the middle cell of cut lines that cross), the group's outline, as the pieces of a chain that +/// closes count as one closed Cut line. +fn enclosed_loops(shapes: &[Shape]) -> Vec { + let Some(map) = adjacency(shapes, DEFAULT_PRECISION) else { return vec![] }; + let mut inner = vec![true; map.faces.len()]; + for e in &map.edges { + for (a, b) in [(e.left, e.right), (e.right, e.left)] { + if b.is_none() + && let Some(slot) = a.and_then(|f| inner.get_mut(f)) + { + *slot = false; + } + } + } + let mut group: Vec = (0..map.faces.len()).collect(); + for e in &map.edges { + if let (Some(a), Some(b)) = (e.left, e.right) + && a != b + && inner.get(a) == Some(&true) + && inner.get(b) == Some(&true) + { + let (ra, rb) = (root_of(&mut group, a), root_of(&mut group, b)); + if let Some(slot) = group.get_mut(ra) { + *slot = rb; + } + } + } + let mut sets: HashMap> = HashMap::new(); + for f in (0..map.faces.len()).filter(|&f| inner.get(f) == Some(&true)) { + sets.entry(root_of(&mut group, f)).or_default().push(f); + } + // A group is a loop when its boundary edges come from pieces that lie on that boundary alone, + // that is, pieces that meet end to end round it; pieces of lines that cross it go on past it. + let mut edges_of: HashMap> = HashMap::new(); + for (i, e) in map.edges.iter().enumerate() { + for &s in &e.sources { + edges_of.entry(s).or_default().push(i); + } + } + let side = |g: &mut Vec, f: Option| f.filter(|&f| inner.get(f) == Some(&true)).map(|f| root_of(g, f)); + let mut boundary: HashMap> = HashMap::new(); + for (i, e) in map.edges.iter().enumerate() { + let (l, r) = (side(&mut group, e.left), side(&mut group, e.right)); + if l != r { + for root in [l, r].into_iter().flatten() { + boundary.entry(root).or_default().insert(i); + } + } + } + let whole = |root: &usize| { + boundary.get(root).is_some_and(|edges| { + edges + .iter() + .filter_map(|&i| map.edges.get(i)) + .flat_map(|e| &e.sources) + .all(|s| edges_of.get(s).is_some_and(|all| all.iter().all(|i| edges.contains(i)))) + }) + }; + let mut sets: Vec<(usize, Vec)> = sets.into_iter().filter(|(root, _)| whole(root)).collect(); + sets.push((usize::MAX, (0..map.faces.len()).collect())); + sets.sort_unstable(); + let mut out = vec![]; + for (_, set) in sets { + let faces: Vec<(&PathData, FillRule)> = set.iter().filter_map(|&f| map.faces.get(f)).map(|f| (&f.path, FillRule::NonZero)).collect(); + if !faces.is_empty() { + out.extend(unite_all(&faces).subpaths.into_iter().map(|sp| PathData::single(sp).to_bezpath())); + } + } + out +} + +/// The node that stands for `v`'s set in `group` (a disjoint-set forest), halving the path on the way. +fn root_of(group: &mut [usize], mut v: usize) -> usize { + while let Some(&up) = group.get(v) { + if up == v { + break; + } + let next = group.get(up).copied().unwrap_or(up); + if let Some(slot) = group.get_mut(v) { + *slot = next; + } + v = next; + } + v +} + /// Which of `edges` ((id, end node, end node), nodes below `nodes`) lie on no cycle: the bridges of /// the graph, found depth first without recursion. fn bridges(nodes: usize, edges: &[(usize, usize, usize)]) -> Vec { @@ -809,6 +955,7 @@ impl Material { *h = !unusable(f) && in_outline && cut_out; } } + self.open_notches(piece, fallback.as_ref()); if any { let bound = if outlines.is_empty() { fallback @@ -825,6 +972,45 @@ impl Material { } } + /// Faces of `piece` cut out that meet the outside, directly or through other faces cut out, are + /// a notch, not a hole: they stop being holes. The outside is a usable face that is neither + /// material nor a hole (the part of a slot beyond the outline), or the side with no face of an + /// edge on the piece's outer boundary `outline` (elsewhere a side with no face is a sliver). + fn open_notches(&mut self, piece: usize, outline: Option<&BezPath>) { + let edges = self.edges_by_piece.get(piece).cloned().unwrap_or_default(); + let hole = |s: &Self, f: Option| f.is_some_and(|f| s.hole.get(f) == Some(&true)); + let open = |s: &Self, f: Option| { + f.is_some_and(|f| s.hole.get(f) != Some(&true) && s.material.get(f) != Some(&true) && s.points.get(f).copied().flatten().is_some()) + }; + // Whether `edge` lies on the piece's outer boundary `outline` (its middle within 1e-6 of + // it): its side with no face is then the outside, not a sliver. + let on_outline = |edge: &vectorcraft_pathops::MapEdge| { + let Some(outline) = outline else { return false }; + let segs: Vec = edge.path.to_bezpath().segments().collect(); + let Some(mid) = segs.get(segs.len() / 2).map(|s| s.eval(0.5)) else { return false }; + outline.segments().any(|s| s.nearest(mid, 1e-9).distance_sq <= 1e-12) + }; + let mut next: HashMap> = HashMap::new(); + let mut queue = vec![]; + for edge in edges.iter().filter_map(|&e| self.map.edges.get(e)) { + for (a, b) in [(edge.left, edge.right), (edge.right, edge.left)] { + let Some(f) = a.filter(|_| a != b && hole(self, a)) else { continue }; + if open(self, b) || (b.is_none() && on_outline(edge)) { + queue.push(f); + } else if let Some(g) = b.filter(|_| hole(self, b)) { + next.entry(f).or_default().push(g); + } + } + } + while let Some(f) = queue.pop() { + match self.hole.get_mut(f) { + Some(h) if *h => *h = false, + _ => continue, + } + queue.extend(next.get(&f).into_iter().flatten().copied()); + } + } + /// The face of the Cut lines' map that holds `p`, the smallest when several do. fn face_at(&self, p: Point) -> Option { self.face_cells @@ -865,6 +1051,9 @@ struct HingePiece { lines: Vec, } +/// A hinge piece by the (blank, panel, panel) it lies between. +type PlacedPiece = ((usize, usize, usize), HingePiece); + struct Context<'a> { lines: &'a [FoldLine], pieces: &'a [Piece], @@ -945,9 +1134,9 @@ impl Context<'_> { issues.push(Issue::new(IssueCode::TooComplex, vec![], None)); return vec![]; } - let pieces = self.edges(&places, issues); + let (pieces, outside) = self.edges(&places, issues); let hinged = self.hinges(&mut blanks, pieces, issues); - self.creases(&places, &hinged, issues); + self.creases(&places, &hinged, &outside, issues); self.slivers(issues); self.nested(issues); self.loose_panels(&blanks, &places, issues); @@ -980,9 +1169,10 @@ impl Context<'_> { } /// Overlaps, dangling creases and creases in holes, from the full map's edges → the hinge - /// pieces, by (blank, panel, panel). - fn edges(&self, places: &[Place], issues: &mut Vec) -> Vec<((usize, usize, usize), HingePiece)> { + /// pieces, by (blank, panel, panel), and how long each line runs outside every blank. + fn edges(&self, places: &[Place], issues: &mut Vec) -> (Vec, Vec) { let mut pieces = vec![]; + let mut outside = vec![0.0; self.lines.len()]; let mut seen: HashSet<(IssueCode, Vec)> = HashSet::new(); let mut report = |issues: &mut Vec, code: IssueCode, keys: Vec| { let issue = Issue::new(code, keys, None); @@ -1000,17 +1190,16 @@ impl Context<'_> { report(issues, IssueCode::CutOverCrease, self.keys(by_line.iter().copied())); continue; } - // Two subpaths of one kind on the same edge, from two lines or from one line's own - // subpaths (a compound path); the gap lines are left out. - let drawn: Vec = e.sources.iter().copied().filter(|&s| self.line_of(s).is_some()).collect(); - let mut duplicates: Vec = drawn - .iter() - .filter(|&&s| drawn.iter().any(|&o| o != s && self.kind_of(o) == self.kind_of(s))) - .filter_map(|&s| self.line_of(s)) - .collect(); - duplicates.sort_unstable(); - duplicates.dedup(); - if !duplicates.is_empty() { + // Two subpaths on the same edge, from two lines or from one line's own subpaths (a + // compound path); the gap lines are left out. Past the check above they are all Cut lines + // or all lines that fold. + let mut drawn: Vec = e.sources.iter().copied().filter(|&s| self.line_of(s).is_some()).collect(); + drawn.sort_unstable(); + drawn.dedup(); + if drawn.len() >= 2 { + let mut duplicates: Vec = drawn.iter().filter_map(|&s| self.line_of(s)).collect(); + duplicates.sort_unstable(); + duplicates.dedup(); report(issues, IssueCode::Duplicate, self.keys(duplicates)); } if creases.is_empty() { @@ -1024,14 +1213,34 @@ impl Context<'_> { report(issues, IssueCode::DanglingCrease, self.keys(creases)); } (Place::Hole, _) | (_, Place::Hole) => report(issues, IssueCode::Ambiguous, self.keys(creases)), - _ => {} + _ => { + // A side with no face can also be a sliver inside a blank: the edge counts when + // its middle lies in a face of the Cut lines that is neither material nor a hole + // (a notch), or in no face and outside every blank. + let segs: Vec = e.path.to_bezpath().segments().collect(); + let Some(mid) = segs.get(segs.len() / 2).map(|s| s.eval(0.5)) else { continue }; + let m = self.material; + let away = match m.face_at(mid) { + Some(f) => m.material.get(f) != Some(&true) && m.hole.get(f) != Some(&true), + None => !m.in_a_blank(mid), + }; + if !away { + continue; + } + let length: f64 = segs.iter().map(|s| s.arclen(1e-3)).sum(); + for &line in &creases { + if let Some(o) = outside.get_mut(line) { + *o += length; + } + } + } } } - pieces + (pieces, outside) } /// The hinges `pieces` make, added to `blanks` → the lines with a hinge. - fn hinges(&self, blanks: &mut [Blank], mut pieces: Vec<((usize, usize, usize), HingePiece)>, issues: &mut Vec) -> Vec { + fn hinges(&self, blanks: &mut [Blank], mut pieces: Vec, issues: &mut Vec) -> Vec { pieces.sort_by_key(|p| p.0); let mut hinged = vec![]; let mut start = 0; @@ -1067,29 +1276,24 @@ impl Context<'_> { let sp = p.path.subpaths.first()?; Some((sp.anchors.first()?.p, sp.anchors.last()?.p)) }; - let longest = group.iter().filter_map(|p| Some((*p, chord(p)?))).max_by(|x, y| { - let (lx, ly) = (x.1.0.distance(x.1.1), y.1.0.distance(y.1.1)); - lx.total_cmp(&ly) - })?; - let (p0, p1) = longest.1; + let (p0, p1) = group.iter().filter_map(|p| chord(p)).max_by(|x, y| x.0.distance(x.1).total_cmp(&y.0.distance(y.1)))?; let len = p0.distance(p1); // The longest piece only sets the direction; the length check is on the whole hinge below. if len.is_nan() || len <= 1e-9 { return None; } let d = (p1 - p0) / len; - let off = |p: Point| ((p - p0).cross(d)).abs(); + // Each segment turned so the line through `p0` along `d` is the x axis: the exact bounds + // give how far it strays from the line (y) and its extent along it (x). + let turn = Affine::rotate(-d.y.atan2(d.x)) * Affine::translate(-p0.to_vec2()); let mut straight = true; let (mut lo, mut hi) = (f64::INFINITY, f64::NEG_INFINITY); for p in group { for seg in p.path.to_bezpath().segments() { - for t in [0.0, 0.25, 0.5, 0.75, 1.0] { - let q = seg.eval(t); - straight &= off(q) <= self.tolerance; - let s = (q - p0).dot(d); - lo = lo.min(s); - hi = hi.max(s); - } + let b = (turn * seg).bounding_box(); + straight &= b.y0.abs() <= self.tolerance && b.y1.abs() <= self.tolerance; + lo = lo.min(b.x0); + hi = hi.max(b.x1); } } // The pieces' own length, not the span from the first to the last, which takes in the gaps @@ -1101,23 +1305,21 @@ impl Context<'_> { let mut lines: Vec = group.iter().flat_map(|p| p.lines.iter().copied()).collect(); lines.sort_unstable(); lines.dedup(); - let angle = longest - .0 - .lines - .first() - .and_then(|&l| self.lines.get(l)) - .map(|l| l.angle.filter(|a| a.is_finite()).unwrap_or_else(|| l.kind.default_angle())) - .unwrap_or(90.0); let mut keys = self.keys(lines); keys.sort_unstable(); keys.dedup(); - Some(Hinge { a, b, from: p0 + d * lo, to: p0 + d * hi, angle, keys, straight }) + Some(Hinge { a, b, from: p0 + d * lo, to: p0 + d * hi, keys, straight }) } - /// Creases with no hinge: outside every blank, or dividing no two panels. - fn creases(&self, places: &[Place], hinged: &[usize], issues: &mut Vec) { - let named: HashSet = - issues.iter().filter(|i| i.code != IssueCode::LooseEnd && i.code != IssueCode::Gap).flat_map(|i| i.keys.iter().copied()).collect(); + /// Creases with no hinge: outside every blank, or dividing no two panels; and creases beside a + /// panel that run `outside` every blank (by line) for the tolerance or more. + fn creases(&self, places: &[Place], hinged: &[usize], outside: &[f64], issues: &mut Vec) { + // A line drawn twice is still checked for where it lies. + let named: HashSet = issues + .iter() + .filter(|i| !matches!(i.code, IssueCode::LooseEnd | IssueCode::Gap | IssueCode::Duplicate)) + .flat_map(|i| i.keys.iter().copied()) + .collect(); // Whether each line is drawn (has a usable subpath), and whether one of its edges touches a // panel. let mut drawn = vec![false; self.lines.len()]; @@ -1137,11 +1339,16 @@ impl Context<'_> { } } for (line, l) in self.lines.iter().enumerate() { - if l.kind == LineKind::Cut || hinged.binary_search(&line).is_ok() || named.contains(&l.key) || drawn.get(line) != Some(&true) { + if l.kind == LineKind::Cut || drawn.get(line) != Some(&true) { continue; } - let code = if on_panel.get(line) == Some(&true) { IssueCode::NoSplit } else { IssueCode::Outside }; - issues.push(Issue::new(code, vec![l.key], None)); + let beside = on_panel.get(line) == Some(&true); + if hinged.binary_search(&line).is_err() && !named.contains(&l.key) { + issues.push(Issue::new(if beside { IssueCode::NoSplit } else { IssueCode::Outside }, vec![l.key], None)); + } + if beside && outside.get(line).is_some_and(|&o| o >= self.tolerance) { + issues.push(Issue::new(IssueCode::Outside, vec![l.key], None)); + } } } @@ -1219,7 +1426,7 @@ impl Context<'_> { /// The base panel of `panels`: the largest by area; panels whose areas differ by less than 1e-9 of /// the larger tie, and the tie goes to the one whose inside point is highest on the page, then /// leftmost. -pub fn base_panel(panels: &[Panel]) -> Option { +fn base_panel(panels: &[Panel]) -> Option { let top = panels.iter().map(|p| p.area).fold(f64::NEG_INFINITY, f64::max); if !top.is_finite() { return None; diff --git a/crates/three-d/src/fold/tests.rs b/crates/three-d/src/fold/tests.rs index a3f2c68d37..ef014300c0 100644 --- a/crates/three-d/src/fold/tests.rs +++ b/crates/three-d/src/fold/tests.rs @@ -13,7 +13,7 @@ fn poly(points: &[(f64, f64)], closed: bool) -> PathData { } fn line(kind: LineKind, points: &[(f64, f64)], closed: bool, key: u64) -> FoldLine { - FoldLine { path: poly(points, closed), kind, angle: None, key } + FoldLine { path: poly(points, closed), kind, key } } fn cut(points: &[(f64, f64)], key: u64) -> FoldLine { @@ -131,7 +131,7 @@ fn a_tray_has_a_base_four_walls_and_four_hinges() { assert_eq!(areas(&b[0]), vec![1_800_000, 1_800_000, 3_000_000, 3_000_000, 6_000_000]); assert_eq!(b[0].hinges.len(), 4); for h in &b[0].hinges { - assert!(h.straight && h.angle == 90.0 && h.keys.len() == 1, "{h:?}"); + assert!(h.straight && h.keys.len() == 1, "{h:?}"); assert!((h.from.distance(h.to) - if h.keys[0] % 2 == 0 { 100.0 } else { 60.0 }).abs() < 1e-6, "{h:?}"); } assert_eq!(base_panel(&b[0].panels).map(|i| (b[0].panels[i].area).round()), Some(6000.0)); @@ -188,7 +188,7 @@ fn a_round_tuck_flap_folds_like_any_panel() { bp.curve_to(p(100.0, 10.0), p(80.0, 0.0), p(50.0, 0.0)); bp.curve_to(p(20.0, 0.0), p(0.0, 10.0), p(0.0, 40.0)); bp.close_path(); - let lines = vec![FoldLine { path: PathData::from_bezpath(&bp), kind: LineKind::Cut, angle: None, key: 1 }, crease((0.0, 40.0), (100.0, 40.0), 2)]; + let lines = vec![FoldLine { path: PathData::from_bezpath(&bp), kind: LineKind::Cut, key: 1 }, crease((0.0, 40.0), (100.0, 40.0), 2)]; let (b, issues) = check(&lines); assert!(issues.is_empty(), "{issues:?}"); assert_eq!(b[0].panels.len(), 2); @@ -353,7 +353,7 @@ fn an_outline_drawn_twice_keeps_its_material() { // The same two squares as the subpaths of one compound path. let mut twice = poly(&square, true); twice.subpaths.extend(poly(&square, true).subpaths); - let (b, issues) = check(&[FoldLine { path: twice, kind: LineKind::Cut, angle: None, key: 1 }]); + let (b, issues) = check(&[FoldLine { path: twice, kind: LineKind::Cut, key: 1 }]); assert_eq!(codes(&issues), vec!["duplicate"], "{issues:?}"); assert_eq!(issues[0].keys, vec![1]); assert_eq!(areas(&b[0]), vec![10_000_000]); @@ -412,6 +412,150 @@ fn a_window_of_open_lines_with_a_slit_to_its_corner_is_still_a_hole() { let (b, issues) = check(&lines); assert!(issues.is_empty(), "{issues:?}"); assert_eq!((b[0].holes.len(), areas(&b[0])), (1, areas(&closed[0]))); + // A cut across the window of open lines, so that three lines meet at two of its corners. + let mut lines = vec![cut(&corners, 1), line(LineKind::Cut, &[(40.0, 0.0), (40.0, 40.0)], false, 2)]; + for k in 0..4 { + lines.push(line(LineKind::Cut, &[window[k], window[(k + 1) % 4]], false, 3 + k as u64)); + } + lines.push(line(LineKind::Cut, &[(40.0, 40.0), (60.0, 60.0)], false, 20)); + let (b, issues) = check(&lines); + assert!(issues.is_empty(), "{issues:?}"); + assert_eq!((b[0].holes.len(), areas(&b[0])), (1, areas(&closed[0]))); + // The outline and the window both as open lines, joined by two slits: the same as when both are + // closed. + let slits = [line(LineKind::Cut, &[(0.0, 0.0), (40.0, 40.0)], false, 30), line(LineKind::Cut, &[(100.0, 100.0), (60.0, 60.0)], false, 31)]; + let (want, want_issues) = check(&[cut(&corners, 1), cut(&window, 3), slits[0].clone(), slits[1].clone()]); + let mut lines: Vec = (0..4).map(|k| line(LineKind::Cut, &[corners[k], corners[(k + 1) % 4]], false, 10 + k as u64)).collect(); + for k in 0..4 { + lines.push(line(LineKind::Cut, &[window[k], window[(k + 1) % 4]], false, 3 + k as u64)); + } + lines.extend(slits); + let (b, issues) = check(&lines); + assert_eq!(codes(&issues), codes(&want_issues), "{issues:?}"); + assert_eq!((b[0].holes.len(), areas(&b[0])), (want[0].holes.len(), areas(&want[0]))); + assert_eq!(want[0].holes.len(), 1); +} + +#[test] +fn a_slot_drawn_across_the_outline_is_a_notch_not_a_hole() { + let outline = || cut(&[(0.0, 0.0), (100.0, 0.0), (100.0, 100.0), (0.0, 100.0)], 1); + let (b, issues) = check(&[outline(), cut(&[(48.0, -10.0), (52.0, -10.0), (52.0, 20.0), (48.0, 20.0)], 2)]); + assert!(issues.is_empty(), "{issues:?}"); + assert!(b[0].holes.is_empty(), "{:?}", b[0].holes); + let notched = cut(&[(0.0, 0.0), (48.0, 0.0), (48.0, 20.0), (52.0, 20.0), (52.0, 0.0), (100.0, 0.0), (100.0, 100.0), (0.0, 100.0)], 1); + assert_eq!(areas(&b[0]), areas(&check(std::slice::from_ref(¬ched)).0[0])); + // A crease in the notch lies outside the blank, and one that runs on into it from a panel too. + let slot = || cut(&[(48.0, -10.0), (52.0, -10.0), (52.0, 20.0), (48.0, 20.0)], 2); + let (_, issues) = check(&[outline(), slot(), crease((49.0, 5.0), (51.0, 5.0), 3)]); + assert_eq!(codes(&issues), vec!["outside"], "{issues:?}"); + let (_, issues) = check(&[outline(), slot(), crease((50.0, 5.0), (50.0, 100.0), 3)]); + let (_, want) = check(&[notched, crease((50.0, 5.0), (50.0, 100.0), 3)]); + assert_eq!(codes(&issues), codes(&want), "{issues:?}"); + assert!(codes(&issues).contains(&"outside"), "{issues:?}"); + // A cutout whose top side lies on the outline opens onto the outside directly. + let flush = || cut(&[(48.0, 0.0), (52.0, 0.0), (52.0, 20.0), (48.0, 20.0)], 2); + let (b, issues) = check(&[outline(), flush()]); + assert!(b[0].holes.is_empty() && !codes(&issues).contains(&"ambiguous"), "{:?} {issues:?}", b[0].holes); + let (_, issues) = check(&[outline(), flush(), crease((49.0, 5.0), (51.0, 5.0), 3)]); + assert!(codes(&issues).contains(&"outside") && !codes(&issues).contains(&"ambiguous"), "{issues:?}"); + // A window joined to the outline by a slit stays a hole when a cut across it leaves a sliver. + let window = || cut(&[(40.0, 40.0), (60.0, 40.0), (60.0, 60.0), (40.0, 60.0)], 4); + let slit = || line(LineKind::Cut, &[(40.0, 0.0), (40.0, 40.0)], false, 5); + let (b, _) = check(&[outline(), window(), slit(), line(LineKind::Cut, &[(40.0, 40.004), (60.0, 40.004)], false, 6)]); + assert_eq!(b[0].holes.len(), 1, "{:?}", b[0].holes); + // And a window 0.004 pt below the outline, joined to it at both corners, leaving a sliver. + let near = cut(&[(40.0, 0.004), (60.0, 0.004), (60.0, 20.0), (40.0, 20.0)], 4); + let joins = [line(LineKind::Cut, &[(40.0, 0.0), (40.0, 0.004)], false, 5), line(LineKind::Cut, &[(60.0, 0.0), (60.0, 0.004)], false, 6)]; + let (b, _) = check(&[outline(), near, joins[0].clone(), joins[1].clone()]); + assert_eq!(b[0].holes.len(), 1, "{:?}", b[0].holes); +} + +#[test] +fn many_small_outlines_of_open_lines_fit_the_gap_search() { + // 784 unit squares 3 pt apart, each four open lines, at a tolerance of 0.5 pt. + let mut lines = vec![]; + for i in 0..28u64 { + for j in 0..28u64 { + let (x, y) = (3.0 * i as f64, 3.0 * j as f64); + let c = [(x, y), (x + 1.0, y), (x + 1.0, y + 1.0), (x, y + 1.0)]; + for k in 0..4 { + lines.push(line(LineKind::Cut, &[c[k], c[(k + 1) % 4]], false, 4 * (28 * i + j) + k as u64)); + } + } + } + let (b, issues) = blanks(&lines, 0.5); + assert!(!codes(&issues).contains(&"tooComplex"), "{issues:?}"); + assert_eq!(b.len(), 784); +} + +#[test] +fn thousands_of_cut_lines_on_top_of_each_other_are_too_complex_before_the_gap_search() { + let lines: Vec = (0..3000u64).map(|k| line(LineKind::Cut, &[(0.0, 0.0), (100.0, 0.0)], false, k)).collect(); + let (b, issues) = check(&lines); + assert_eq!(codes(&issues), vec!["tooComplex"], "{issues:?}"); + assert!(b.is_empty()); +} + +#[test] +fn cut_lines_that_cross_an_outline_of_open_lines_leave_every_cell_material() { + // A 90 pt square whose sides are open lines ending every 30 pt, and four cut lines right across + // it: nine pieces of material, as with a closed outline. + let mut lines = vec![]; + for k in 0..3 { + let (a, b) = (30.0 * k as f64, 30.0 * (k + 1) as f64); + for (i, seg) in [[(a, 0.0), (b, 0.0)], [(90.0, a), (90.0, b)], [(b, 90.0), (a, 90.0)], [(0.0, b), (0.0, a)]].iter().enumerate() { + lines.push(line(LineKind::Cut, seg, false, 10 + 4 * k as u64 + i as u64)); + } + } + let across = [[(30.0, 0.0), (30.0, 90.0)], [(60.0, 0.0), (60.0, 90.0)], [(0.0, 30.0), (90.0, 30.0)], [(0.0, 60.0), (90.0, 60.0)]]; + for (i, seg) in across.iter().enumerate() { + lines.push(line(LineKind::Cut, seg, false, 30 + i as u64)); + } + let mut closed = vec![cut(&[(0.0, 0.0), (90.0, 0.0), (90.0, 90.0), (0.0, 90.0)], 1)]; + closed.extend(lines.iter().skip(12).cloned()); + let (want, want_issues) = check(&closed); + let (b, issues) = check(&lines); + assert_eq!(codes(&issues), codes(&want_issues), "{issues:?}"); + let pieces = |b: &[Blank]| b.iter().map(|x| (x.panels.len(), x.holes.len())).collect::>(); + assert_eq!(pieces(&b), pieces(&want)); + assert_eq!(b.iter().map(|x| x.panels.len()).sum::(), 9); + // With the crossing lines drawn in 30 pt pieces, the four pieces round the middle cell meet end + // to end and count as one closed cut line, whether the outline is closed or drawn in pieces. + let mut split = vec![]; + for (i, seg) in across.iter().enumerate() { + let (a, b) = (seg[0], seg[1]); + for k in 0..3 { + let at = |t: f64| (a.0 + (b.0 - a.0) * t, a.1 + (b.1 - a.1) * t); + split.push(line(LineKind::Cut, &[at(k as f64 / 3.0), at((k + 1) as f64 / 3.0)], false, 40 + 3 * i as u64 + k as u64)); + } + } + let mut closed = vec![cut(&[(0.0, 0.0), (90.0, 0.0), (90.0, 90.0), (0.0, 90.0)], 1)]; + closed.extend(split.iter().cloned()); + let (want, want_issues) = check(&closed); + let mut open: Vec = lines.iter().take(12).cloned().collect(); + open.extend(split); + let (b, issues) = check(&open); + assert_eq!(codes(&issues), codes(&want_issues), "{issues:?}"); + assert_eq!(pieces(&b), pieces(&want)); +} + +#[test] +fn a_curved_crease_is_measured_at_its_farthest_point_from_its_line() { + // A crease from corner to corner of a square: its curve strays about 10.1 pt from the diagonal, + // where samples at quarters of it see 9.8 pt. + let off = 35.0 / 2f64.sqrt(); + let mut bp = BezPath::new(); + bp.move_to(p(0.0, 0.0)); + bp.curve_to(p(10000.0 / 3.0 - off, 10000.0 / 3.0 + off), p(20000.0 / 3.0 + off, 20000.0 / 3.0 - off), p(10000.0, 10000.0)); + let lines = vec![ + cut(&[(0.0, 0.0), (10000.0, 0.0), (10000.0, 10000.0), (0.0, 10000.0)], 1), + FoldLine { path: PathData::from_bezpath(&bp), kind: LineKind::Crease, key: 2 }, + ]; + let (b, issues) = blanks(&lines, 10.0); + assert_eq!(codes(&issues), vec!["notStraight"], "{issues:?}"); + assert_eq!(b[0].hinges.len(), 1); + let (_, issues) = blanks(&lines, 10.5); + assert!(issues.is_empty(), "{issues:?}"); } #[test] @@ -541,6 +685,38 @@ fn lines_on_top_of_each_other_are_reported() { assert_eq!(issues[0].keys, vec![10, 20]); assert_eq!(b[0].hinges.len(), 4); assert_eq!(b[0].hinges.iter().find(|h| h.keys.contains(&20)).map(|h| h.keys.clone()), Some(vec![10, 20])); + + // A perforation over a crease, lines of two kinds that fold. + let mut lines = tray(); + lines.push(line(LineKind::Perforation, &[(130.0, 30.0), (30.0, 30.0)], false, 20)); + let (_, issues) = check(&lines); + assert_eq!(codes(&issues), vec!["duplicate"], "{issues:?}"); + assert_eq!(issues[0].keys, vec![10, 20]); + + // A crease drawn twice outside the blank is reported where it lies as well. + let mut lines = tray(); + lines.push(crease((200.0, 0.0), (250.0, 0.0), 20)); + lines.push(crease((250.0, 0.0), (200.0, 0.0), 21)); + let (_, issues) = check(&lines); + assert_eq!(codes(&issues), vec!["duplicate", "outside", "outside"], "{issues:?}"); + assert_eq!((issues[1].keys.clone(), issues[2].keys.clone()), (vec![20], vec![21])); +} + +#[test] +fn a_crease_that_runs_past_the_outline_is_reported() { + let outline = || cut(&[(0.0, 0.0), (100.0, 0.0), (100.0, 50.0), (0.0, 50.0)], 1); + // 5 pt past the outline at each end: the hinge is built, and the line is reported. + let (b, issues) = check(&[outline(), crease((50.0, -5.0), (50.0, 55.0), 2)]); + assert_eq!(codes(&issues), vec!["outside"], "{issues:?}"); + assert_eq!(issues[0].keys, vec![2]); + assert_eq!(b[0].hinges.len(), 1); + // Past it by less than the tolerance: no issue. + let (b, issues) = check(&[outline(), crease((50.0, -0.05), (50.0, 50.0), 2)]); + assert!(issues.is_empty(), "{issues:?}"); + assert_eq!(b[0].hinges.len(), 1); + // A crease drawn round a sliver inside the blank does not run outside it. + let (_, issues) = check(&[outline(), line(LineKind::Crease, &[(50.0, 10.0), (50.004, 10.0), (50.004, 40.0), (50.0, 40.0)], true, 2)]); + assert!(!codes(&issues).contains(&"outside"), "{issues:?}"); } #[test] @@ -682,15 +858,15 @@ fn lines_in_a_hole_are_ambiguous() { } #[test] -fn partial_cuts_fold_the_other_way_and_a_line_s_own_angle_wins() { +fn partial_cuts_and_perforations_make_hinges_as_creases_do() { let mut lines = tray(); lines[1].kind = LineKind::PartialCut; - lines[2].angle = Some(45.0); lines[3].kind = LineKind::Perforation; let (b, issues) = check(&lines); assert!(issues.is_empty(), "{issues:?}"); - let angle = |key: u64| b[0].hinges.iter().find(|h| h.keys == vec![key]).map(|h| h.angle); - assert_eq!((angle(10), angle(11), angle(12), angle(13)), (Some(-90.0), Some(45.0), Some(90.0), Some(90.0))); + let mut keys: Vec> = b[0].hinges.iter().map(|h| h.keys.clone()).collect(); + keys.sort_unstable(); + assert_eq!(keys, vec![vec![10], vec![11], vec![12], vec![13]]); } #[test] diff --git a/crates/three-d/src/lib.rs b/crates/three-d/src/lib.rs index 01b5c75d9f..f232d265e9 100644 --- a/crates/three-d/src/lib.rs +++ b/crates/three-d/src/lib.rs @@ -4,6 +4,8 @@ //! Open profiles optionally close their circular ends with caps, and a partial sweep its cut sides. Faces are projected and sorted back to front, //! then flat or smoothly shaded with vector gradients. This preview uses a painter's algorithm, not a depth buffer: //! intersecting profiles can have ambiguous visibility and are not solid modelling inputs. +//! +//! [`fold`] finds the panels and hinges of a flat packaging blank from its fold lines. #![forbid(unsafe_code)] pub mod fold; diff --git a/crates/ui-egui/src/addons/packaging.rs b/crates/ui-egui/src/addons/packaging.rs index 1e827a7efc..54f233d945 100644 --- a/crates/ui-egui/src/addons/packaging.rs +++ b/crates/ui-egui/src/addons/packaging.rs @@ -92,7 +92,7 @@ impl Checked { fn summary(&self) -> String { let errors = self.issues.iter().filter(|i| i.error).count(); crate::i18n::fmt( - "Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings}", + "Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings}", &[ ("panels", &self.panels.to_string()), ("hinges", &self.hinges.to_string()), diff --git a/crates/ui-egui/src/addons/packaging/tests.rs b/crates/ui-egui/src/addons/packaging/tests.rs index 808956e4d7..93fbb2b8d2 100644 --- a/crates/ui-egui/src/addons/packaging/tests.rs +++ b/crates/ui-egui/src/addons/packaging/tests.rs @@ -183,10 +183,10 @@ fn check_fold_lines_lists_its_issues_in_the_panel_until_the_document_changes() { assert!(!crate::panel_docking::showing(&app.ui, ID)); menus::invoke(&mut app, CHECK, item.params.clone()); assert!(crate::panel_docking::showing(&app.ui, ID), "the panel opens"); - assert_eq!(app.ui.status, "Panels: 2, creases: 1, errors: 1, warnings: 0"); + assert_eq!(app.ui.status, "Panels: 2, hinges: 1, errors: 1, warnings: 0"); let text = frames(&mut app, &ctx, None); assert!(text.contains("A cut line ends without meeting another cut line."), "{text}"); - assert!(text.contains("Panels: 2, creases: 1, errors: 1, warnings: 0") && text.contains("Select"), "{text}"); + assert!(text.contains("Panels: 2, hinges: 1, errors: 1, warnings: 0") && text.contains("Select"), "{text}"); // Any change to the document takes the list away. app.run("shape.rectangle", json!({"x": 0, "y": 0, "width": 5, "height": 5})).unwrap(); let text = frames(&mut app, &ctx, None); @@ -209,7 +209,7 @@ fn the_check_button_checks_and_clicking_an_issue_selects_its_lines() { // A clean blank: no issues. app.run("edit.clear", json!({})).unwrap(); let text = frames(&mut app, &ctx, Some("Check")); - assert!(text.contains("No issues found.") && text.contains("Panels: 2, creases: 1, errors: 0, warnings: 0"), "{text}"); + assert!(text.contains("No issues found.") && text.contains("Panels: 2, hinges: 1, errors: 0, warnings: 0"), "{text}"); } #[test] @@ -220,25 +220,27 @@ fn issues_and_the_summary_show_in_the_interface_language() { let text = frames(&mut app, &ctx, Some(crate::i18n::t("Check"))); crate::i18n::set_current(crate::i18n::Lang::EN); assert!(!text.contains("A cut line ends") && !text.contains("Panels:"), "{text}"); - assert!(text.contains("Schnittlinie") && text.contains('2'), "{text}"); + assert!(text.contains("Eine Schnittlinie endet, ohne auf eine andere Schnittlinie zu treffen."), "{text}"); + assert!(text.contains("Felder: 2, Scharniere: 1, Fehler: 1, Warnungen: 0"), "{text}"); } -/// The messages `addon.packaging.check` gives its issues, one for each code (two for `noCut`). -const ISSUE_MESSAGES: [&str; 16] = [ +/// The messages `addon.packaging.check` gives its issues, one for each code (three for `noCut`). +const ISSUE_MESSAGES: [&str; 17] = [ "No cut lines are in the selection.", "No cut lines are in the document.", + "No cut lines are among the given objects.", "The cut lines do not enclose an area.", "A cut line ends without meeting another cut line.", "A gap between cut lines was closed.", "The fold lines are too complex to check.", "A cut line and a crease lie on top of each other.", - "Two lines of the same role lie on top of each other.", + "Two fold lines lie on top of each other.", "A crease ends inside a panel.", "A crease does not divide two panels.", - "A crease lies outside the cut outline.", - "A crease that is not straight is folded along one straight line.", + "A crease lies outside the cut outline, wholly or in part.", + "The pieces of a hinge are not on one straight line.", "A gap between cut lines is too narrow to tell apart.", - "A cut-out area holds other fold lines.", + "A cut-out area holds other fold lines or another blank.", "A panel is not joined to the rest by a crease.", "A fold line is on a non-printing layer.", ]; @@ -250,7 +252,7 @@ fn every_issue_message_translates_in_every_complete_message_catalog() { "ca", "nl", "da", ] { let lang = crate::i18n::Lang::from_code(code).unwrap(); - for m in ISSUE_MESSAGES.into_iter().chain(["Panels: 3, creases: 2, errors: 1, warnings: 0"]) { + for m in ISSUE_MESSAGES.into_iter().chain(["Panels: 3, hinges: 2, errors: 1, warnings: 0"]) { assert_ne!(crate::i18n::message(lang, m), m, "{code}: {m}"); } } diff --git a/crates/ui-egui/src/i18n/bg.tsv b/crates/ui-egui/src/i18n/bg.tsv index ab9ed92de5..7beb9f89eb 100644 --- a/crates/ui-egui/src/i18n/bg.tsv +++ b/crates/ui-egui/src/i18n/bg.tsv @@ -7093,14 +7093,15 @@ breakText Glyphs Глифи @msg A gap between cut lines was closed. Процеп между линии за рязане беше затворен. @msg The fold lines are too complex to check. Линиите на сгъване са твърде сложни за проверка. @msg A cut line and a crease lie on top of each other. Линия за рязане и линия за биговане лежат една върху друга. -@msg Two lines of the same role lie on top of each other. Две линии от един и същи вид лежат една върху друга. +@msg No cut lines are among the given objects. Сред дадените обекти няма линии за рязане. +@msg Two fold lines lie on top of each other. Две линии на сгъване лежат една върху друга. @msg A crease ends inside a panel. Линия за биговане завършва вътре в панел. @msg A crease does not divide two panels. Линия за биговане не разделя два панела. -@msg A crease lies outside the cut outline. Линия за биговане лежи извън контура за рязане. -@msg A crease that is not straight is folded along one straight line. Линия за биговане, която не е права, се сгъва по една права линия. +@msg A crease lies outside the cut outline, wholly or in part. Линия за биговане лежи изцяло или отчасти извън контура за рязане. +@msg The pieces of a hinge are not on one straight line. Частите на една панта не лежат на една права линия. @msg A gap between cut lines is too narrow to tell apart. Процеп между линии за рязане е твърде тесен, за да се различи. -@msg A cut-out area holds other fold lines. Изрязана област съдържа други линии на сгъване. +@msg A cut-out area holds other fold lines or another blank. Изрязана област съдържа други линии на сгъване или друг разкрой. @msg A panel is not joined to the rest by a crease. Панел не е свързан с останалите с линия за биговане. @msg A fold line is on a non-printing layer. Линия на сгъване е на слой, който не се печата. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Панели: {panels}, бигове: {hinges}, грешки: {errors}, предупреждения: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Панели: {panels}, панти: {hinges}, грешки: {errors}, предупреждения: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer трябва да е "singleLine", "everyLine", "standardSingleLine" или "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/bs.tsv b/crates/ui-egui/src/i18n/bs.tsv index d6cc94f911..22c2d3b7c7 100644 --- a/crates/ui-egui/src/i18n/bs.tsv +++ b/crates/ui-egui/src/i18n/bs.tsv @@ -7146,14 +7146,15 @@ shape Open Otvoren @msg A gap between cut lines was closed. Razmak između linija rezanja je zatvoren. @msg The fold lines are too complex to check. Linije savijanja su previše složene za provjeru. @msg A cut line and a crease lie on top of each other. Linija rezanja i linija bigovanja leže jedna preko druge. -@msg Two lines of the same role lie on top of each other. Dvije linije iste vrste leže jedna preko druge. +@msg No cut lines are among the given objects. Među zadanim objektima nema linija rezanja. +@msg Two fold lines lie on top of each other. Dvije linije savijanja leže jedna preko druge. @msg A crease ends inside a panel. Linija bigovanja završava unutar panela. @msg A crease does not divide two panels. Linija bigovanja ne razdvaja dva panela. -@msg A crease lies outside the cut outline. Linija bigovanja leži izvan konture rezanja. -@msg A crease that is not straight is folded along one straight line. Linija bigovanja koja nije ravna savija se duž jedne prave linije. +@msg A crease lies outside the cut outline, wholly or in part. Linija bigovanja leži potpuno ili djelimično izvan konture rezanja. +@msg The pieces of a hinge are not on one straight line. Dijelovi jedne šarke ne leže na jednoj pravoj liniji. @msg A gap between cut lines is too narrow to tell apart. Razmak između linija rezanja je preuzak da bi se razlikovao. -@msg A cut-out area holds other fold lines. Izrezana površina sadrži druge linije savijanja. +@msg A cut-out area holds other fold lines or another blank. Izrezana površina sadrži druge linije savijanja ili drugi kroj. @msg A panel is not joined to the rest by a crease. Panel nije povezan s ostatkom nijednom linijom bigovanja. @msg A fold line is on a non-printing layer. Linija savijanja je na sloju koji se ne štampa. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Paneli: {panels}, bigovi: {hinges}, greške: {errors}, upozorenja: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Paneli: {panels}, šarke: {hinges}, greške: {errors}, upozorenja: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer mora biti "singleLine", "everyLine", "standardSingleLine" ili "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/ca.tsv b/crates/ui-egui/src/i18n/ca.tsv index 0089095906..683dcc0d93 100644 --- a/crates/ui-egui/src/i18n/ca.tsv +++ b/crates/ui-egui/src/i18n/ca.tsv @@ -7954,14 +7954,15 @@ breakText Glyphs Glifs @msg A gap between cut lines was closed. S’ha tancat un buit entre línies de tall. @msg The fold lines are too complex to check. Les línies de plegat són massa complexes per comprovar-les. @msg A cut line and a crease lie on top of each other. Una línia de tall i una d’hendit estan superposades. -@msg Two lines of the same role lie on top of each other. Dues línies del mateix tipus estan superposades. +@msg No cut lines are among the given objects. No hi ha cap línia de tall entre els objectes indicats. +@msg Two fold lines lie on top of each other. Dues línies de plegat estan superposades. @msg A crease ends inside a panel. Una línia d’hendit acaba dins d’un panell. @msg A crease does not divide two panels. Una línia d’hendit no separa dos panells. -@msg A crease lies outside the cut outline. Una línia d’hendit és fora del contorn de tall. -@msg A crease that is not straight is folded along one straight line. Una línia d’hendit que no és recta es plega al llarg d’una sola línia recta. +@msg A crease lies outside the cut outline, wholly or in part. Una línia d’hendit és fora del contorn de tall, del tot o en part. +@msg The pieces of a hinge are not on one straight line. Els trams d’una frontissa no són en una sola línia recta. @msg A gap between cut lines is too narrow to tell apart. Un buit entre línies de tall és massa estret per distingir-lo. -@msg A cut-out area holds other fold lines. Una àrea retallada conté altres línies de plegat. +@msg A cut-out area holds other fold lines or another blank. Una àrea retallada conté altres línies de plegat o un altre troquelat. @msg A panel is not joined to the rest by a crease. Un panell no està unit a la resta per cap línia d’hendit. @msg A fold line is on a non-printing layer. Una línia de plegat és en una capa que no s’imprimeix. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Panells: {panels}, hendits: {hinges}, errors: {errors}, avisos: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Panells: {panels}, frontisses: {hinges}, errors: {errors}, avisos: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer ha de ser "singleLine", "everyLine", "standardSingleLine" o "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/cs.tsv b/crates/ui-egui/src/i18n/cs.tsv index 299aa6cedc..69e387e26c 100644 --- a/crates/ui-egui/src/i18n/cs.tsv +++ b/crates/ui-egui/src/i18n/cs.tsv @@ -9751,13 +9751,14 @@ breakText Glyphs Glyfy @msg A gap between cut lines was closed. Mezera mezi liniemi řezu byla uzavřena. @msg The fold lines are too complex to check. Linie skladu jsou příliš složité na kontrolu. @msg A cut line and a crease lie on top of each other. Linie řezu a linie bigu leží přes sebe. -@msg Two lines of the same role lie on top of each other. Dvě linie stejného typu leží přes sebe. +@msg No cut lines are among the given objects. Mezi zadanými objekty nejsou žádné linie řezu. +@msg Two fold lines lie on top of each other. Dvě linie skladu leží přes sebe. @msg A crease ends inside a panel. Linie bigu končí uvnitř panelu. @msg A crease does not divide two panels. Linie bigu nerozděluje dva panely. -@msg A crease lies outside the cut outline. Linie bigu leží mimo obrys řezu. -@msg A crease that is not straight is folded along one straight line. Linie bigu, která není rovná, se ohýbá podél jedné přímky. +@msg A crease lies outside the cut outline, wholly or in part. Linie bigu leží zcela nebo zčásti mimo obrys řezu. +@msg The pieces of a hinge are not on one straight line. Části jednoho pantu neleží na jedné přímce. @msg A gap between cut lines is too narrow to tell apart. Mezera mezi liniemi řezu je příliš úzká na rozlišení. -@msg A cut-out area holds other fold lines. Vyříznutá oblast obsahuje další linie skladu. +@msg A cut-out area holds other fold lines or another blank. Vyříznutá oblast obsahuje další linie skladu nebo jiný přířez. @msg A panel is not joined to the rest by a crease. Panel není se zbytkem spojen žádnou linií bigu. @msg A fold line is on a non-printing layer. Linie skladu je na netisknutelné vrstvě. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Panely: {panels}, bigy: {hinges}, chyby: {errors}, upozornění: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Panely: {panels}, panty: {hinges}, chyby: {errors}, upozornění: {warnings} diff --git a/crates/ui-egui/src/i18n/da.tsv b/crates/ui-egui/src/i18n/da.tsv index 647596237c..395a2d01c4 100644 --- a/crates/ui-egui/src/i18n/da.tsv +++ b/crates/ui-egui/src/i18n/da.tsv @@ -9853,14 +9853,15 @@ breakText Glyphs Glyffer @msg A gap between cut lines was closed. Et mellemrum mellem skærelinjer blev lukket. @msg The fold lines are too complex to check. Foldelinjerne er for komplekse til at kontrollere. @msg A cut line and a crease lie on top of each other. En skærelinje og en rillelinje ligger oven på hinanden. -@msg Two lines of the same role lie on top of each other. To linjer af samme type ligger oven på hinanden. +@msg No cut lines are among the given objects. Der er ingen skærelinjer blandt de angivne objekter. +@msg Two fold lines lie on top of each other. To foldelinjer ligger oven på hinanden. @msg A crease ends inside a panel. En rillelinje slutter inde i et panel. @msg A crease does not divide two panels. En rillelinje deler ikke to paneler. -@msg A crease lies outside the cut outline. En rillelinje ligger uden for skærekonturen. -@msg A crease that is not straight is folded along one straight line. En rillelinje, der ikke er lige, foldes langs én ret linje. +@msg A crease lies outside the cut outline, wholly or in part. En rillelinje ligger helt eller delvist uden for skærekonturen. +@msg The pieces of a hinge are not on one straight line. Delene af et hængsel ligger ikke på én ret linje. @msg A gap between cut lines is too narrow to tell apart. Et mellemrum mellem skærelinjer er for smalt til at skelne. -@msg A cut-out area holds other fold lines. Et udskåret område indeholder andre foldelinjer. +@msg A cut-out area holds other fold lines or another blank. Et udskåret område indeholder andre foldelinjer eller et andet emne. @msg A panel is not joined to the rest by a crease. Et panel er ikke forbundet med resten af en rillelinje. @msg A fold line is on a non-printing layer. En foldelinje ligger på et lag, der ikke udskrives. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Paneler: {panels}, riller: {hinges}, fejl: {errors}, advarsler: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Paneler: {panels}, hængsler: {hinges}, fejl: {errors}, advarsler: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer skal være "singleLine", "everyLine", "standardSingleLine" eller "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/de.tsv b/crates/ui-egui/src/i18n/de.tsv index 4be132dc4f..f9df67b2bc 100644 --- a/crates/ui-egui/src/i18n/de.tsv +++ b/crates/ui-egui/src/i18n/de.tsv @@ -9349,13 +9349,14 @@ breakText Glyphs Glyphen @msg A gap between cut lines was closed. Eine Lücke zwischen Schnittlinien wurde geschlossen. @msg The fold lines are too complex to check. Die Faltlinien sind zu komplex für die Prüfung. @msg A cut line and a crease lie on top of each other. Eine Schnittlinie und eine Rilllinie liegen übereinander. -@msg Two lines of the same role lie on top of each other. Zwei Linien derselben Linienart liegen übereinander. +@msg No cut lines are among the given objects. Die angegebenen Objekte enthalten keine Schnittlinien. +@msg Two fold lines lie on top of each other. Zwei Faltlinien liegen übereinander. @msg A crease ends inside a panel. Eine Rilllinie endet innerhalb eines Felds. @msg A crease does not divide two panels. Eine Rilllinie trennt keine zwei Felder. -@msg A crease lies outside the cut outline. Eine Rilllinie liegt außerhalb der Schnittkontur. -@msg A crease that is not straight is folded along one straight line. Eine nicht gerade Rilllinie wird entlang einer geraden Linie gefaltet. +@msg A crease lies outside the cut outline, wholly or in part. Eine Rilllinie liegt ganz oder teilweise außerhalb der Schnittkontur. +@msg The pieces of a hinge are not on one straight line. Die Teile eines Scharniers liegen nicht auf einer geraden Linie. @msg A gap between cut lines is too narrow to tell apart. Eine Lücke zwischen Schnittlinien ist zu schmal, um sie zu unterscheiden. -@msg A cut-out area holds other fold lines. Ein ausgeschnittener Bereich enthält weitere Faltlinien. +@msg A cut-out area holds other fold lines or another blank. Ein ausgeschnittener Bereich enthält weitere Faltlinien oder einen anderen Zuschnitt. @msg A panel is not joined to the rest by a crease. Ein Feld ist durch keine Rilllinie mit den übrigen verbunden. @msg A fold line is on a non-printing layer. Eine Faltlinie liegt auf einer nicht druckbaren Ebene. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Felder: {panels}, Rilllinien: {hinges}, Fehler: {errors}, Warnungen: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Felder: {panels}, Scharniere: {hinges}, Fehler: {errors}, Warnungen: {warnings} diff --git a/crates/ui-egui/src/i18n/el.tsv b/crates/ui-egui/src/i18n/el.tsv index 05c6a32103..b27f4b5867 100644 --- a/crates/ui-egui/src/i18n/el.tsv +++ b/crates/ui-egui/src/i18n/el.tsv @@ -7928,14 +7928,15 @@ breakText Glyphs Γλύφοι @msg A gap between cut lines was closed. Ένα κενό ανάμεσα σε γραμμές κοπής κλείστηκε. @msg The fold lines are too complex to check. Οι γραμμές δίπλωσης είναι πολύ σύνθετες για έλεγχο. @msg A cut line and a crease lie on top of each other. Μια γραμμή κοπής και μια γραμμή πτύχωσης βρίσκονται η μία πάνω στην άλλη. -@msg Two lines of the same role lie on top of each other. Δύο γραμμές του ίδιου τύπου βρίσκονται η μία πάνω στην άλλη. +@msg No cut lines are among the given objects. Τα δοσμένα αντικείμενα δεν περιέχουν γραμμές κοπής. +@msg Two fold lines lie on top of each other. Δύο γραμμές δίπλωσης βρίσκονται η μία πάνω στην άλλη. @msg A crease ends inside a panel. Μια γραμμή πτύχωσης τελειώνει μέσα σε ένα πάνελ. @msg A crease does not divide two panels. Μια γραμμή πτύχωσης δεν χωρίζει δύο πάνελ. -@msg A crease lies outside the cut outline. Μια γραμμή πτύχωσης βρίσκεται έξω από το περίγραμμα κοπής. -@msg A crease that is not straight is folded along one straight line. Μια γραμμή πτύχωσης που δεν είναι ευθεία διπλώνεται κατά μήκος μίας ευθείας. +@msg A crease lies outside the cut outline, wholly or in part. Μια γραμμή πτύχωσης βρίσκεται εν όλω ή εν μέρει έξω από το περίγραμμα κοπής. +@msg The pieces of a hinge are not on one straight line. Τα τμήματα ενός μεντεσέ δεν βρίσκονται σε μία ευθεία. @msg A gap between cut lines is too narrow to tell apart. Ένα κενό ανάμεσα σε γραμμές κοπής είναι πολύ στενό για να διακριθεί. -@msg A cut-out area holds other fold lines. Μια αποκομμένη περιοχή περιέχει άλλες γραμμές δίπλωσης. +@msg A cut-out area holds other fold lines or another blank. Μια αποκομμένη περιοχή περιέχει άλλες γραμμές δίπλωσης ή άλλο ανάπτυγμα. @msg A panel is not joined to the rest by a crease. Ένα πάνελ δεν συνδέεται με τα υπόλοιπα με καμία γραμμή πτύχωσης. @msg A fold line is on a non-printing layer. Μια γραμμή δίπλωσης βρίσκεται σε επίπεδο που δεν εκτυπώνεται. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Πάνελ: {panels}, πτυχώσεις: {hinges}, σφάλματα: {errors}, προειδοποιήσεις: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Πάνελ: {panels}, μεντεσέδες: {hinges}, σφάλματα: {errors}, προειδοποιήσεις: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" το composer πρέπει να είναι "singleLine", "everyLine", "standardSingleLine" ή "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/es.tsv b/crates/ui-egui/src/i18n/es.tsv index 12e483f369..f2f1b14574 100644 --- a/crates/ui-egui/src/i18n/es.tsv +++ b/crates/ui-egui/src/i18n/es.tsv @@ -7915,14 +7915,15 @@ breakText Glyphs Glifos @msg A gap between cut lines was closed. Se cerró un hueco entre líneas de corte. @msg The fold lines are too complex to check. Las líneas de plegado son demasiado complejas para comprobarlas. @msg A cut line and a crease lie on top of each other. Una línea de corte y una de hendido están superpuestas. -@msg Two lines of the same role lie on top of each other. Dos líneas del mismo tipo están superpuestas. +@msg No cut lines are among the given objects. No hay líneas de corte entre los objetos indicados. +@msg Two fold lines lie on top of each other. Dos líneas de plegado están superpuestas. @msg A crease ends inside a panel. Una línea de hendido termina dentro de un panel. @msg A crease does not divide two panels. Una línea de hendido no separa dos paneles. -@msg A crease lies outside the cut outline. Una línea de hendido está fuera del contorno de corte. -@msg A crease that is not straight is folded along one straight line. Una línea de hendido que no es recta se pliega a lo largo de una sola línea recta. +@msg A crease lies outside the cut outline, wholly or in part. Una línea de hendido está fuera del contorno de corte, total o parcialmente. +@msg The pieces of a hinge are not on one straight line. Los tramos de una bisagra no están en una sola línea recta. @msg A gap between cut lines is too narrow to tell apart. Un hueco entre líneas de corte es demasiado estrecho para distinguirlo. -@msg A cut-out area holds other fold lines. Un área recortada contiene otras líneas de plegado. +@msg A cut-out area holds other fold lines or another blank. Un área recortada contiene otras líneas de plegado u otro troquelado. @msg A panel is not joined to the rest by a crease. Un panel no está unido al resto por ninguna línea de hendido. @msg A fold line is on a non-printing layer. Una línea de plegado está en una capa que no se imprime. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Paneles: {panels}, hendidos: {hinges}, errores: {errors}, advertencias: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Paneles: {panels}, bisagras: {hinges}, errores: {errors}, advertencias: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer debe ser "singleLine", "everyLine", "standardSingleLine" o "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/fi.tsv b/crates/ui-egui/src/i18n/fi.tsv index db6163e7e3..7350f840e6 100644 --- a/crates/ui-egui/src/i18n/fi.tsv +++ b/crates/ui-egui/src/i18n/fi.tsv @@ -8011,14 +8011,15 @@ breakText Glyphs Merkit @msg A gap between cut lines was closed. Leikkausviivojen välinen rako suljettiin. @msg The fold lines are too complex to check. Taittoviivat ovat liian monimutkaisia tarkistettaviksi. @msg A cut line and a crease lie on top of each other. Leikkausviiva ja nuuttausviiva ovat päällekkäin. -@msg Two lines of the same role lie on top of each other. Kaksi samantyyppistä viivaa on päällekkäin. +@msg No cut lines are among the given objects. Annetuissa objekteissa ei ole leikkausviivoja. +@msg Two fold lines lie on top of each other. Kaksi taittoviivaa on päällekkäin. @msg A crease ends inside a panel. Nuuttausviiva päättyy paneelin sisään. @msg A crease does not divide two panels. Nuuttausviiva ei jaa kahta paneelia. -@msg A crease lies outside the cut outline. Nuuttausviiva on leikkausääriviivan ulkopuolella. -@msg A crease that is not straight is folded along one straight line. Nuuttausviiva, joka ei ole suora, taitetaan yhtä suoraa viivaa pitkin. +@msg A crease lies outside the cut outline, wholly or in part. Nuuttausviiva on kokonaan tai osittain leikkausääriviivan ulkopuolella. +@msg The pieces of a hinge are not on one straight line. Saranan osat eivät ole yhdellä suoralla. @msg A gap between cut lines is too narrow to tell apart. Leikkausviivojen välinen rako on liian kapea erotettavaksi. -@msg A cut-out area holds other fold lines. Leikattu alue sisältää muita taittoviivoja. +@msg A cut-out area holds other fold lines or another blank. Leikattu alue sisältää muita taittoviivoja tai toisen aihion. @msg A panel is not joined to the rest by a crease. Paneelia ei ole liitetty muihin millään nuuttausviivalla. @msg A fold line is on a non-printing layer. Taittoviiva on tasolla, jota ei tulosteta. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Paneelit: {panels}, nuuttaukset: {hinges}, virheet: {errors}, varoitukset: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Paneelit: {panels}, saranat: {hinges}, virheet: {errors}, varoitukset: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer on oltava "singleLine", "everyLine", "standardSingleLine" tai "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/fr.tsv b/crates/ui-egui/src/i18n/fr.tsv index 7ae0eab9c6..d720f44899 100644 --- a/crates/ui-egui/src/i18n/fr.tsv +++ b/crates/ui-egui/src/i18n/fr.tsv @@ -9736,14 +9736,15 @@ breakText Glyphs Glyphes @msg A gap between cut lines was closed. Un écart entre des lignes de découpe a été fermé. @msg The fold lines are too complex to check. Les lignes de pliage sont trop complexes pour être vérifiées. @msg A cut line and a crease lie on top of each other. Une ligne de découpe et une ligne de rainage se superposent. -@msg Two lines of the same role lie on top of each other. Deux lignes du même type se superposent. +@msg No cut lines are among the given objects. Les objets indiqués ne contiennent aucune ligne de découpe. +@msg Two fold lines lie on top of each other. Deux lignes de pliage se superposent. @msg A crease ends inside a panel. Une ligne de rainage se termine à l’intérieur d’un panneau. @msg A crease does not divide two panels. Une ligne de rainage ne sépare pas deux panneaux. -@msg A crease lies outside the cut outline. Une ligne de rainage se trouve hors du contour de découpe. -@msg A crease that is not straight is folded along one straight line. Une ligne de rainage qui n’est pas droite est pliée le long d’une seule ligne droite. +@msg A crease lies outside the cut outline, wholly or in part. Une ligne de rainage se trouve en tout ou en partie hors du contour de découpe. +@msg The pieces of a hinge are not on one straight line. Les morceaux d’une charnière ne sont pas sur une seule ligne droite. @msg A gap between cut lines is too narrow to tell apart. Un écart entre des lignes de découpe est trop étroit pour être distingué. -@msg A cut-out area holds other fold lines. Une zone découpée contient d’autres lignes de pliage. +@msg A cut-out area holds other fold lines or another blank. Une zone découpée contient d’autres lignes de pliage ou un autre flan. @msg A panel is not joined to the rest by a crease. Un panneau n’est relié au reste par aucune ligne de rainage. @msg A fold line is on a non-printing layer. Une ligne de pliage se trouve sur un calque non imprimable. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} {panels} panneau(x), {hinges} rainage(s), {errors} erreur(s), {warnings} avertissement(s) +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} {panels} panneau(x), {hinges} charnière(s), {errors} erreur(s), {warnings} avertissement(s) @msg {_1} × {_2} pixels is too large for GIF (at most 65535 pixels a side): lower the resolution {_1} × {_2} pixels, c’est trop grand pour le GIF (65535 pixels par côté au plus) : réduisez la résolution diff --git a/crates/ui-egui/src/i18n/gu.tsv b/crates/ui-egui/src/i18n/gu.tsv index d7b10bf7c0..ee792315ff 100644 --- a/crates/ui-egui/src/i18n/gu.tsv +++ b/crates/ui-egui/src/i18n/gu.tsv @@ -4855,16 +4855,17 @@ swatch [Registration] [રજિસ્ટ્રેશન] @msg A gap between cut lines was closed. કટ લાઇન્સ વચ્ચેનો ગેપ બંધ કરવામાં આવ્યો. @msg The fold lines are too complex to check. ફોલ્ડ લાઇન્સ ચેક કરવા માટે ખૂબ જટિલ છે. @msg A cut line and a crease lie on top of each other. એક કટ લાઇન અને એક ક્રીઝ લાઇન એકબીજા પર છે. -@msg Two lines of the same role lie on top of each other. એક જ પ્રકારની બે લાઇન્સ એકબીજા પર છે. +@msg No cut lines are among the given objects. આપેલા ઑબ્જેક્ટ્સમાં કોઈ કટ લાઇન નથી. +@msg Two fold lines lie on top of each other. બે ફોલ્ડ લાઇન્સ એકબીજા પર છે. @msg A crease ends inside a panel. એક ક્રીઝ લાઇન પેનલની અંદર પૂરી થાય છે. @msg A crease does not divide two panels. એક ક્રીઝ લાઇન બે પેનલને અલગ કરતી નથી. -@msg A crease lies outside the cut outline. એક ક્રીઝ લાઇન કટ આઉટલાઇનની બહાર છે. -@msg A crease that is not straight is folded along one straight line. સીધી ન હોય તેવી ક્રીઝ લાઇન એક સીધી લાઇન પર ફોલ્ડ થાય છે. +@msg A crease lies outside the cut outline, wholly or in part. એક ક્રીઝ લાઇન પૂરેપૂરી અથવા આંશિક રીતે કટ આઉટલાઇનની બહાર છે. +@msg The pieces of a hinge are not on one straight line. એક હિન્જના ભાગો એક સીધી લાઇન પર નથી. @msg A gap between cut lines is too narrow to tell apart. કટ લાઇન્સ વચ્ચેનો ગેપ ઓળખવા માટે ખૂબ સાંકડો છે. -@msg A cut-out area holds other fold lines. એક કટ-આઉટ વિસ્તારમાં બીજી ફોલ્ડ લાઇન્સ છે. +@msg A cut-out area holds other fold lines or another blank. એક કટ-આઉટ વિસ્તારમાં બીજી ફોલ્ડ લાઇન્સ અથવા બીજું બ્લેન્ક છે. @msg A panel is not joined to the rest by a crease. એક પેનલ કોઈ ક્રીઝ લાઇનથી બાકીના સાથે જોડાયેલી નથી. @msg A fold line is on a non-printing layer. એક ફોલ્ડ લાઇન નોન-પ્રિન્ટિંગ લેયર પર છે. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} પેનલ: {panels}, ક્રીઝ: {hinges}, ભૂલો: {errors}, ચેતવણીઓ: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} પેનલ: {panels}, હિન્જ: {hinges}, ભૂલો: {errors}, ચેતવણીઓ: {warnings} Middle Eastern & South Asian Single-line Composer સિંગલ-લાઇન કમ્પોઝર (મધ્ય પૂર્વ અને દક્ષિણ એશિયા) Middle Eastern & South Asian Every-line Composer એવરી-લાઇન કમ્પોઝર (મધ્ય પૂર્વ અને દક્ષિણ એશિયા) Standard Single-line Composer સ્ટાન્ડર્ડ સિંગલ-લાઇન કમ્પોઝર diff --git a/crates/ui-egui/src/i18n/hi.tsv b/crates/ui-egui/src/i18n/hi.tsv index f632881023..7398511e77 100644 --- a/crates/ui-egui/src/i18n/hi.tsv +++ b/crates/ui-egui/src/i18n/hi.tsv @@ -9356,13 +9356,14 @@ theme Appearance अपीयरेंस @msg A gap between cut lines was closed. कट लाइनों के बीच का गैप बंद कर दिया गया। @msg The fold lines are too complex to check. फ़ोल्ड लाइनें चेक करने के लिए बहुत जटिल हैं। @msg A cut line and a crease lie on top of each other. एक कट लाइन और एक क्रीज़ लाइन एक-दूसरे के ऊपर हैं। -@msg Two lines of the same role lie on top of each other. एक ही प्रकार की दो लाइनें एक-दूसरे के ऊपर हैं। +@msg No cut lines are among the given objects. दिए गए ऑब्जेक्ट में कोई कट लाइन नहीं है। +@msg Two fold lines lie on top of each other. दो फ़ोल्ड लाइनें एक-दूसरे के ऊपर हैं। @msg A crease ends inside a panel. एक क्रीज़ लाइन किसी पैनल के अंदर खत्म होती है। @msg A crease does not divide two panels. एक क्रीज़ लाइन दो पैनलों को अलग नहीं करती। -@msg A crease lies outside the cut outline. एक क्रीज़ लाइन कट आउटलाइन के बाहर है। -@msg A crease that is not straight is folded along one straight line. जो क्रीज़ लाइन सीधी नहीं है, वह एक सीधी लाइन पर फ़ोल्ड होती है। +@msg A crease lies outside the cut outline, wholly or in part. एक क्रीज़ लाइन पूरी तरह या आंशिक रूप से कट आउटलाइन के बाहर है। +@msg The pieces of a hinge are not on one straight line. एक हिंज के हिस्से एक सीधी लाइन पर नहीं हैं। @msg A gap between cut lines is too narrow to tell apart. कट लाइनों के बीच का गैप पहचानने के लिए बहुत पतला है। -@msg A cut-out area holds other fold lines. एक कट-आउट एरिया में दूसरी फ़ोल्ड लाइनें हैं। +@msg A cut-out area holds other fold lines or another blank. एक कट-आउट एरिया में दूसरी फ़ोल्ड लाइनें या दूसरा ब्लैंक है। @msg A panel is not joined to the rest by a crease. कोई पैनल किसी क्रीज़ लाइन से बाकी से जुड़ा नहीं है। @msg A fold line is on a non-printing layer. एक फ़ोल्ड लाइन नॉन-प्रिंटिंग लेयर पर है। -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} पैनल: {panels}, क्रीज़: {hinges}, एरर: {errors}, वॉर्निंग: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} पैनल: {panels}, हिंज: {hinges}, एरर: {errors}, वॉर्निंग: {warnings} diff --git a/crates/ui-egui/src/i18n/hu.tsv b/crates/ui-egui/src/i18n/hu.tsv index 5ecfe58e72..97cac8096b 100644 --- a/crates/ui-egui/src/i18n/hu.tsv +++ b/crates/ui-egui/src/i18n/hu.tsv @@ -9739,13 +9739,14 @@ breakText Glyphs Glifák @msg A gap between cut lines was closed. A vágóvonalak közötti rés le lett zárva. @msg The fold lines are too complex to check. A hajtásvonalak túl összetettek az ellenőrzéshez. @msg A cut line and a crease lie on top of each other. Egy vágóvonal és egy bigvonal egymáson fekszik. -@msg Two lines of the same role lie on top of each other. Két azonos típusú vonal egymáson fekszik. +@msg No cut lines are among the given objects. A megadott objektumok között nincs vágóvonal. +@msg Two fold lines lie on top of each other. Két hajtásvonal egymáson fekszik. @msg A crease ends inside a panel. Egy bigvonal egy panelen belül ér véget. @msg A crease does not divide two panels. Egy bigvonal nem választ el két panelt. -@msg A crease lies outside the cut outline. Egy bigvonal a vágási körvonalon kívül van. -@msg A crease that is not straight is folded along one straight line. Egy nem egyenes bigvonal egyetlen egyenes mentén hajlik. +@msg A crease lies outside the cut outline, wholly or in part. Egy bigvonal teljesen vagy részben a vágási körvonalon kívül van. +@msg The pieces of a hinge are not on one straight line. Egy zsanér részei nem egy egyenesen vannak. @msg A gap between cut lines is too narrow to tell apart. A vágóvonalak közötti rés túl keskeny a megkülönböztetéshez. -@msg A cut-out area holds other fold lines. Egy kivágott terület további hajtásvonalakat tartalmaz. +@msg A cut-out area holds other fold lines or another blank. Egy kivágott terület további hajtásvonalakat vagy egy másik kiterítéket tartalmaz. @msg A panel is not joined to the rest by a crease. Egy panelt egyetlen bigvonal sem köt a többihez. @msg A fold line is on a non-printing layer. Egy hajtásvonal nem nyomtatható rétegen van. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Panelek: {panels}, bigek: {hinges}, hibák: {errors}, figyelmeztetések: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Panelek: {panels}, zsanérok: {hinges}, hibák: {errors}, figyelmeztetések: {warnings} diff --git a/crates/ui-egui/src/i18n/id.tsv b/crates/ui-egui/src/i18n/id.tsv index cd2ad82864..5e7d456bc2 100644 --- a/crates/ui-egui/src/i18n/id.tsv +++ b/crates/ui-egui/src/i18n/id.tsv @@ -7108,14 +7108,15 @@ breakText Glyphs Glif @msg A gap between cut lines was closed. Celah di antara garis potong telah ditutup. @msg The fold lines are too complex to check. Garis lipat terlalu rumit untuk diperiksa. @msg A cut line and a crease lie on top of each other. Sebuah garis potong dan sebuah garis lekuk bertumpuk. -@msg Two lines of the same role lie on top of each other. Dua garis dengan jenis yang sama bertumpuk. +@msg No cut lines are among the given objects. Tidak ada garis potong di antara objek yang diberikan. +@msg Two fold lines lie on top of each other. Dua garis lipat bertumpuk. @msg A crease ends inside a panel. Sebuah garis lekuk berakhir di dalam panel. @msg A crease does not divide two panels. Sebuah garis lekuk tidak membagi dua panel. -@msg A crease lies outside the cut outline. Sebuah garis lekuk berada di luar kontur potong. -@msg A crease that is not straight is folded along one straight line. Garis lekuk yang tidak lurus dilipat di sepanjang satu garis lurus. +@msg A crease lies outside the cut outline, wholly or in part. Sebuah garis lekuk berada seluruhnya atau sebagian di luar kontur potong. +@msg The pieces of a hinge are not on one straight line. Bagian-bagian sebuah engsel tidak berada pada satu garis lurus. @msg A gap between cut lines is too narrow to tell apart. Celah di antara garis potong terlalu sempit untuk dibedakan. -@msg A cut-out area holds other fold lines. Area yang dipotong berisi garis lipat lain. +@msg A cut-out area holds other fold lines or another blank. Area yang dipotong berisi garis lipat lain atau bentangan lain. @msg A panel is not joined to the rest by a crease. Sebuah panel tidak tersambung ke bagian lain oleh garis lekuk apa pun. @msg A fold line is on a non-printing layer. Sebuah garis lipat berada di lapisan yang tidak dicetak. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Panel: {panels}, lekuk: {hinges}, galat: {errors}, peringatan: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Panel: {panels}, engsel: {hinges}, galat: {errors}, peringatan: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer harus "singleLine", "everyLine", "standardSingleLine", atau "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/it.tsv b/crates/ui-egui/src/i18n/it.tsv index b34cf145a7..366a9f6940 100644 --- a/crates/ui-egui/src/i18n/it.tsv +++ b/crates/ui-egui/src/i18n/it.tsv @@ -9383,13 +9383,14 @@ breakText Glyphs Glifi @msg A gap between cut lines was closed. È stato chiuso uno spazio tra linee di taglio. @msg The fold lines are too complex to check. Le linee di piega sono troppo complesse da verificare. @msg A cut line and a crease lie on top of each other. Una linea di taglio e una di cordonatura sono sovrapposte. -@msg Two lines of the same role lie on top of each other. Due linee dello stesso tipo sono sovrapposte. +@msg No cut lines are among the given objects. Tra gli oggetti indicati non ci sono linee di taglio. +@msg Two fold lines lie on top of each other. Due linee di piega sono sovrapposte. @msg A crease ends inside a panel. Una linea di cordonatura termina all’interno di un pannello. @msg A crease does not divide two panels. Una linea di cordonatura non divide due pannelli. -@msg A crease lies outside the cut outline. Una linea di cordonatura si trova fuori dal contorno di taglio. -@msg A crease that is not straight is folded along one straight line. Una linea di cordonatura non diritta viene piegata lungo un’unica linea retta. +@msg A crease lies outside the cut outline, wholly or in part. Una linea di cordonatura si trova del tutto o in parte fuori dal contorno di taglio. +@msg The pieces of a hinge are not on one straight line. I tratti di una cerniera non sono su un’unica linea retta. @msg A gap between cut lines is too narrow to tell apart. Uno spazio tra linee di taglio è troppo stretto per essere distinto. -@msg A cut-out area holds other fold lines. Un’area ritagliata contiene altre linee di piega. +@msg A cut-out area holds other fold lines or another blank. Un’area ritagliata contiene altre linee di piega o un altro fustellato. @msg A panel is not joined to the rest by a crease. Un pannello non è unito al resto da alcuna linea di cordonatura. @msg A fold line is on a non-printing layer. Una linea di piega si trova su un livello non stampabile. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Pannelli: {panels}, cordonature: {hinges}, errori: {errors}, avvisi: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Pannelli: {panels}, cerniere: {hinges}, errori: {errors}, avvisi: {warnings} diff --git a/crates/ui-egui/src/i18n/ja.tsv b/crates/ui-egui/src/i18n/ja.tsv index a224dec9f0..70dc053e36 100644 --- a/crates/ui-egui/src/i18n/ja.tsv +++ b/crates/ui-egui/src/i18n/ja.tsv @@ -9450,13 +9450,14 @@ breakText Glyphs 字形 @msg A gap between cut lines was closed. カット線間の隙間を閉じました。 @msg The fold lines are too complex to check. 折り線が複雑すぎるためチェックできません。 @msg A cut line and a crease lie on top of each other. カット線と筋入れ線が重なっています。 -@msg Two lines of the same role lie on top of each other. 同じ種類の線が 2 本重なっています。 +@msg No cut lines are among the given objects. 指定したオブジェクトにカット線がありません。 +@msg Two fold lines lie on top of each other. 折り線が 2 本重なっています。 @msg A crease ends inside a panel. 筋入れ線がパネルの内側で終わっています。 @msg A crease does not divide two panels. 筋入れ線が 2 つのパネルを分けていません。 -@msg A crease lies outside the cut outline. 筋入れ線がカットの輪郭の外側にあります。 -@msg A crease that is not straight is folded along one straight line. まっすぐでない筋入れ線は 1 本の直線に沿って折られます。 +@msg A crease lies outside the cut outline, wholly or in part. 筋入れ線の全体または一部がカットの輪郭の外側にあります。 +@msg The pieces of a hinge are not on one straight line. ヒンジの各部分が 1 本の直線上にありません。 @msg A gap between cut lines is too narrow to tell apart. カット線間の隙間が狭すぎて区別できません。 -@msg A cut-out area holds other fold lines. 切り抜かれた領域に他の折り線があります。 +@msg A cut-out area holds other fold lines or another blank. 切り抜かれた領域に他の折り線または別の展開図があります。 @msg A panel is not joined to the rest by a crease. パネルがどの筋入れ線でも他とつながっていません。 @msg A fold line is on a non-printing layer. 折り線が印刷しないレイヤーにあります。 -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} パネル: {panels}、筋入れ: {hinges}、エラー: {errors}、警告: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} パネル: {panels}、ヒンジ: {hinges}、エラー: {errors}、警告: {warnings} diff --git a/crates/ui-egui/src/i18n/ka.tsv b/crates/ui-egui/src/i18n/ka.tsv index 406a43c301..70016438d2 100644 --- a/crates/ui-egui/src/i18n/ka.tsv +++ b/crates/ui-egui/src/i18n/ka.tsv @@ -10019,14 +10019,15 @@ font-script Japanese იაპონური @msg A gap between cut lines was closed. ჭრის ხაზებს შორის ღრეჩო დაიხურა. @msg The fold lines are too complex to check. მოკეცვის ხაზები შესამოწმებლად ზედმეტად რთულია. @msg A cut line and a crease lie on top of each other. ჭრის ხაზი და ბიგის ხაზი ერთმანეთზე დევს. -@msg Two lines of the same role lie on top of each other. ერთი ტიპის ორი ხაზი ერთმანეთზე დევს. +@msg No cut lines are among the given objects. მითითებულ ობიექტებში ჭრის ხაზები არ არის. +@msg Two fold lines lie on top of each other. მოკეცვის ორი ხაზი ერთმანეთზე დევს. @msg A crease ends inside a panel. ბიგის ხაზი პანელის შიგნით მთავრდება. @msg A crease does not divide two panels. ბიგის ხაზი ორ პანელს არ ყოფს. -@msg A crease lies outside the cut outline. ბიგის ხაზი ჭრის კონტურის გარეთაა. -@msg A crease that is not straight is folded along one straight line. ბიგის ხაზი, რომელიც სწორი არ არის, ერთი სწორი ხაზის გასწვრივ იკეცება. +@msg A crease lies outside the cut outline, wholly or in part. ბიგის ხაზი მთლიანად ან ნაწილობრივ ჭრის კონტურის გარეთაა. +@msg The pieces of a hinge are not on one straight line. ანჯამის ნაწილები ერთ სწორ ხაზზე არ დევს. @msg A gap between cut lines is too narrow to tell apart. ჭრის ხაზებს შორის ღრეჩო ზედმეტად ვიწროა გასარჩევად. -@msg A cut-out area holds other fold lines. ამოჭრილი არე სხვა მოკეცვის ხაზებს შეიცავს. +@msg A cut-out area holds other fold lines or another blank. ამოჭრილი არე სხვა მოკეცვის ხაზებს ან სხვა ნამზადს შეიცავს. @msg A panel is not joined to the rest by a crease. პანელი დანარჩენს არცერთი ბიგის ხაზით არ უერთდება. @msg A fold line is on a non-printing layer. მოკეცვის ხაზი არასაბეჭდ შრეზეა. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} პანელები: {panels}, ბიგები: {hinges}, შეცდომები: {errors}, გაფრთხილებები: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} პანელები: {panels}, ანჯამები: {hinges}, შეცდომები: {errors}, გაფრთხილებები: {warnings} @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer უნდა იყოს "singleLine", "everyLine", "standardSingleLine" ან "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/ko.tsv b/crates/ui-egui/src/i18n/ko.tsv index 219bd8aa76..7b2822cb49 100644 --- a/crates/ui-egui/src/i18n/ko.tsv +++ b/crates/ui-egui/src/i18n/ko.tsv @@ -9346,13 +9346,14 @@ breakText Glyphs 글리프 @msg A gap between cut lines was closed. 재단선 사이의 틈을 닫았습니다. @msg The fold lines are too complex to check. 접는 선이 너무 복잡해서 검사할 수 없습니다. @msg A cut line and a crease lie on top of each other. 재단선과 오시선이 겹쳐 있습니다. -@msg Two lines of the same role lie on top of each other. 같은 종류의 선 두 개가 겹쳐 있습니다. +@msg No cut lines are among the given objects. 지정한 개체에 재단선이 없습니다. +@msg Two fold lines lie on top of each other. 접는 선 두 개가 겹쳐 있습니다. @msg A crease ends inside a panel. 오시선이 패널 안에서 끝납니다. @msg A crease does not divide two panels. 오시선이 두 패널을 나누지 않습니다. -@msg A crease lies outside the cut outline. 오시선이 재단 윤곽선 밖에 있습니다. -@msg A crease that is not straight is folded along one straight line. 곧지 않은 오시선은 하나의 직선을 따라 접힙니다. +@msg A crease lies outside the cut outline, wholly or in part. 오시선의 전체 또는 일부가 재단 윤곽선 밖에 있습니다. +@msg The pieces of a hinge are not on one straight line. 힌지의 조각들이 한 직선 위에 있지 않습니다. @msg A gap between cut lines is too narrow to tell apart. 재단선 사이의 틈이 너무 좁아 구별할 수 없습니다. -@msg A cut-out area holds other fold lines. 잘라 낸 영역에 다른 접는 선이 있습니다. +@msg A cut-out area holds other fold lines or another blank. 잘라 낸 영역에 다른 접는 선이나 다른 전개도가 있습니다. @msg A panel is not joined to the rest by a crease. 패널이 어떤 오시선으로도 나머지와 연결되어 있지 않습니다. @msg A fold line is on a non-printing layer. 접는 선이 인쇄되지 않는 레이어에 있습니다. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} 패널: {panels}, 오시: {hinges}, 오류: {errors}, 경고: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} 패널: {panels}, 힌지: {hinges}, 오류: {errors}, 경고: {warnings} diff --git a/crates/ui-egui/src/i18n/nl.tsv b/crates/ui-egui/src/i18n/nl.tsv index 62c2566f13..4d8b5b3170 100644 --- a/crates/ui-egui/src/i18n/nl.tsv +++ b/crates/ui-egui/src/i18n/nl.tsv @@ -9784,13 +9784,14 @@ breakText Glyphs Glyphs @msg A gap between cut lines was closed. Een opening tussen snijlijnen is gesloten. @msg The fold lines are too complex to check. De vouwlijnen zijn te complex om te controleren. @msg A cut line and a crease lie on top of each other. Een snijlijn en een rillijn liggen over elkaar. -@msg Two lines of the same role lie on top of each other. Twee lijnen van dezelfde soort liggen over elkaar. +@msg No cut lines are among the given objects. De opgegeven objecten bevatten geen snijlijnen. +@msg Two fold lines lie on top of each other. Twee vouwlijnen liggen over elkaar. @msg A crease ends inside a panel. Een rillijn eindigt binnen een paneel. @msg A crease does not divide two panels. Een rillijn verdeelt geen twee panelen. -@msg A crease lies outside the cut outline. Een rillijn ligt buiten de snijcontour. -@msg A crease that is not straight is folded along one straight line. Een rillijn die niet recht is, wordt langs één rechte lijn gevouwen. +@msg A crease lies outside the cut outline, wholly or in part. Een rillijn ligt geheel of gedeeltelijk buiten de snijcontour. +@msg The pieces of a hinge are not on one straight line. De delen van een scharnier liggen niet op één rechte lijn. @msg A gap between cut lines is too narrow to tell apart. Een opening tussen snijlijnen is te smal om te onderscheiden. -@msg A cut-out area holds other fold lines. Een uitgesneden gebied bevat andere vouwlijnen. +@msg A cut-out area holds other fold lines or another blank. Een uitgesneden gebied bevat andere vouwlijnen of een andere uitslag. @msg A panel is not joined to the rest by a crease. Een paneel is door geen rillijn met de rest verbonden. @msg A fold line is on a non-printing layer. Een vouwlijn staat op een laag die niet wordt afgedrukt. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Panelen: {panels}, rillijnen: {hinges}, fouten: {errors}, waarschuwingen: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Panelen: {panels}, scharnieren: {hinges}, fouten: {errors}, waarschuwingen: {warnings} diff --git a/crates/ui-egui/src/i18n/pl.tsv b/crates/ui-egui/src/i18n/pl.tsv index 587884f787..22fd391c14 100644 --- a/crates/ui-egui/src/i18n/pl.tsv +++ b/crates/ui-egui/src/i18n/pl.tsv @@ -9604,13 +9604,14 @@ breakText Glyphs Glify @msg A gap between cut lines was closed. Zamknięto przerwę między liniami cięcia. @msg The fold lines are too complex to check. Linie zgięcia są zbyt złożone, aby je sprawdzić. @msg A cut line and a crease lie on top of each other. Linia cięcia i linia bigowania leżą na sobie. -@msg Two lines of the same role lie on top of each other. Dwie linie tego samego rodzaju leżą na sobie. +@msg No cut lines are among the given objects. Wśród podanych obiektów nie ma linii cięcia. +@msg Two fold lines lie on top of each other. Dwie linie zgięcia leżą na sobie. @msg A crease ends inside a panel. Linia bigowania kończy się wewnątrz panelu. @msg A crease does not divide two panels. Linia bigowania nie rozdziela dwóch paneli. -@msg A crease lies outside the cut outline. Linia bigowania leży poza konturem cięcia. -@msg A crease that is not straight is folded along one straight line. Linia bigowania, która nie jest prosta, jest zginana wzdłuż jednej linii prostej. +@msg A crease lies outside the cut outline, wholly or in part. Linia bigowania leży całkowicie lub częściowo poza konturem cięcia. +@msg The pieces of a hinge are not on one straight line. Części zawiasu nie leżą na jednej linii prostej. @msg A gap between cut lines is too narrow to tell apart. Przerwa między liniami cięcia jest zbyt wąska, aby ją rozróżnić. -@msg A cut-out area holds other fold lines. Wycięty obszar zawiera inne linie zgięcia. +@msg A cut-out area holds other fold lines or another blank. Wycięty obszar zawiera inne linie zgięcia lub inny wykrój. @msg A panel is not joined to the rest by a crease. Panel nie jest połączony z resztą żadną linią bigowania. @msg A fold line is on a non-printing layer. Linia zgięcia znajduje się na warstwie niedrukowanej. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Panele: {panels}, bigi: {hinges}, błędy: {errors}, ostrzeżenia: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Panele: {panels}, zawiasy: {hinges}, błędy: {errors}, ostrzeżenia: {warnings} diff --git a/crates/ui-egui/src/i18n/pt-br.tsv b/crates/ui-egui/src/i18n/pt-br.tsv index 4e1f704ec8..3802eda3d0 100644 --- a/crates/ui-egui/src/i18n/pt-br.tsv +++ b/crates/ui-egui/src/i18n/pt-br.tsv @@ -9822,13 +9822,14 @@ swatch Yellow Green Verde-amarelado @msg A gap between cut lines was closed. Uma lacuna entre linhas de corte foi fechada. @msg The fold lines are too complex to check. As linhas de dobra são complexas demais para verificar. @msg A cut line and a crease lie on top of each other. Uma linha de corte e uma de vinco estão sobrepostas. -@msg Two lines of the same role lie on top of each other. Duas linhas do mesmo tipo estão sobrepostas. +@msg No cut lines are among the given objects. Não há linhas de corte entre os objetos indicados. +@msg Two fold lines lie on top of each other. Duas linhas de dobra estão sobrepostas. @msg A crease ends inside a panel. Uma linha de vinco termina dentro de um painel. @msg A crease does not divide two panels. Uma linha de vinco não divide dois painéis. -@msg A crease lies outside the cut outline. Uma linha de vinco está fora do contorno de corte. -@msg A crease that is not straight is folded along one straight line. Uma linha de vinco que não é reta é dobrada ao longo de uma única linha reta. +@msg A crease lies outside the cut outline, wholly or in part. Uma linha de vinco está total ou parcialmente fora do contorno de corte. +@msg The pieces of a hinge are not on one straight line. As partes de uma dobradiça não estão em uma única linha reta. @msg A gap between cut lines is too narrow to tell apart. Uma lacuna entre linhas de corte é estreita demais para ser distinguida. -@msg A cut-out area holds other fold lines. Uma área recortada contém outras linhas de dobra. +@msg A cut-out area holds other fold lines or another blank. Uma área recortada contém outras linhas de dobra ou outra planificação. @msg A panel is not joined to the rest by a crease. Um painel não está unido ao restante por nenhuma linha de vinco. @msg A fold line is on a non-printing layer. Uma linha de dobra está em uma camada não imprimível. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Painéis: {panels}, vincos: {hinges}, erros: {errors}, avisos: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Painéis: {panels}, dobradiças: {hinges}, erros: {errors}, avisos: {warnings} diff --git a/crates/ui-egui/src/i18n/ru.tsv b/crates/ui-egui/src/i18n/ru.tsv index 2c6dec01d4..dae5c2fb75 100644 --- a/crates/ui-egui/src/i18n/ru.tsv +++ b/crates/ui-egui/src/i18n/ru.tsv @@ -9843,15 +9843,16 @@ shape Open Открытый @msg A gap between cut lines was closed. Зазор между линиями реза закрыт. @msg The fold lines are too complex to check. Линии сгиба слишком сложны для проверки. @msg A cut line and a crease lie on top of each other. Линия реза и линия биговки лежат друг на друге. -@msg Two lines of the same role lie on top of each other. Две линии одного типа лежат друг на друге. +@msg No cut lines are among the given objects. Среди указанных объектов нет линий реза. +@msg Two fold lines lie on top of each other. Две линии сгиба лежат друг на друге. @msg A crease ends inside a panel. Линия биговки заканчивается внутри панели. @msg A crease does not divide two panels. Линия биговки не разделяет две панели. -@msg A crease lies outside the cut outline. Линия биговки лежит за пределами контура реза. -@msg A crease that is not straight is folded along one straight line. Непрямая линия биговки сгибается по одной прямой. +@msg A crease lies outside the cut outline, wholly or in part. Линия биговки целиком или частично лежит за пределами контура реза. +@msg The pieces of a hinge are not on one straight line. Части шарнира не лежат на одной прямой. @msg A gap between cut lines is too narrow to tell apart. Зазор между линиями реза слишком узок, чтобы его различить. -@msg A cut-out area holds other fold lines. Вырезанная область содержит другие линии сгиба. +@msg A cut-out area holds other fold lines or another blank. Вырезанная область содержит другие линии сгиба или другую развёртку. @msg A panel is not joined to the rest by a crease. Панель не соединена с остальными ни одной линией биговки. @msg A fold line is on a non-printing layer. Линия сгиба находится на непечатаемом слое. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Панели: {panels}, биговки: {hinges}, ошибки: {errors}, предупреждения: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Панели: {panels}, шарниры: {hinges}, ошибки: {errors}, предупреждения: {warnings} @msg {w} × {h} pixels is too large for PSD (at most {MAX_SIDE} pixels a side): lower the resolution {w} × {h} пикселей — слишком большой размер для PSD (не более {MAX_SIDE} пикселей по стороне): уменьшите разрешение @msg composer must be "singleLine", "everyLine", "standardSingleLine" or "standardEveryLine" composer должен быть "singleLine", "everyLine", "standardSingleLine" или "standardEveryLine" diff --git a/crates/ui-egui/src/i18n/sv.tsv b/crates/ui-egui/src/i18n/sv.tsv index c0ac175345..dd66fc3bee 100644 --- a/crates/ui-egui/src/i18n/sv.tsv +++ b/crates/ui-egui/src/i18n/sv.tsv @@ -9434,14 +9434,15 @@ digits Hindi Hindi @msg A gap between cut lines was closed. Ett mellanrum mellan skärlinjer stängdes. @msg The fold lines are too complex to check. Falslinjerna är för komplexa för att kontrollera. @msg A cut line and a crease lie on top of each other. En skärlinje och en biglinje ligger ovanpå varandra. -@msg Two lines of the same role lie on top of each other. Två linjer av samma typ ligger ovanpå varandra. +@msg No cut lines are among the given objects. Det finns inga skärlinjer bland de angivna objekten. +@msg Two fold lines lie on top of each other. Två falslinjer ligger ovanpå varandra. @msg A crease ends inside a panel. En biglinje slutar inuti en panel. @msg A crease does not divide two panels. En biglinje delar inte två paneler. -@msg A crease lies outside the cut outline. En biglinje ligger utanför skärkonturen. -@msg A crease that is not straight is folded along one straight line. En biglinje som inte är rak falsas längs en rak linje. +@msg A crease lies outside the cut outline, wholly or in part. En biglinje ligger helt eller delvis utanför skärkonturen. +@msg The pieces of a hinge are not on one straight line. Delarna av ett gångjärn ligger inte på en rak linje. @msg A gap between cut lines is too narrow to tell apart. Ett mellanrum mellan skärlinjer är för smalt för att skilja ut. -@msg A cut-out area holds other fold lines. Ett utskuret område innehåller andra falslinjer. +@msg A cut-out area holds other fold lines or another blank. Ett utskuret område innehåller andra falslinjer eller ett annat ämne. @msg A panel is not joined to the rest by a crease. En panel är inte förbunden med resten av någon biglinje. @msg A fold line is on a non-printing layer. En falslinje ligger på ett lager som inte skrivs ut. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Paneler: {panels}, bigningar: {hinges}, fel: {errors}, varningar: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Paneler: {panels}, gångjärn: {hinges}, fel: {errors}, varningar: {warnings} @msg {w} × {h} pixels is too large for PSD (at most {MAX_SIDE} pixels a side): lower the resolution {w} × {h} pixlar är för stort för PSD (högst {MAX_SIDE} pixlar per sida): sänk upplösningen diff --git a/crates/ui-egui/src/i18n/tr.tsv b/crates/ui-egui/src/i18n/tr.tsv index 6dded8c1d7..72c2146903 100644 --- a/crates/ui-egui/src/i18n/tr.tsv +++ b/crates/ui-egui/src/i18n/tr.tsv @@ -9705,13 +9705,14 @@ breakText Glyphs Glifler @msg A gap between cut lines was closed. Kesim çizgileri arasındaki bir boşluk kapatıldı. @msg The fold lines are too complex to check. Katlama çizgileri denetlenemeyecek kadar karmaşık. @msg A cut line and a crease lie on top of each other. Bir kesim çizgisi ile bir pilyaj çizgisi üst üste. -@msg Two lines of the same role lie on top of each other. Aynı türden iki çizgi üst üste. +@msg No cut lines are among the given objects. Belirtilen nesneler arasında kesim çizgisi yok. +@msg Two fold lines lie on top of each other. İki katlama çizgisi üst üste. @msg A crease ends inside a panel. Bir pilyaj çizgisi bir panelin içinde bitiyor. @msg A crease does not divide two panels. Bir pilyaj çizgisi iki paneli ayırmıyor. -@msg A crease lies outside the cut outline. Bir pilyaj çizgisi kesim konturunun dışında. -@msg A crease that is not straight is folded along one straight line. Düz olmayan bir pilyaj çizgisi tek bir düz çizgi boyunca katlanır. +@msg A crease lies outside the cut outline, wholly or in part. Bir pilyaj çizgisi tamamen veya kısmen kesim konturunun dışında. +@msg The pieces of a hinge are not on one straight line. Bir menteşenin parçaları tek bir düz çizgi üzerinde değil. @msg A gap between cut lines is too narrow to tell apart. Kesim çizgileri arasındaki bir boşluk ayırt edilemeyecek kadar dar. -@msg A cut-out area holds other fold lines. Kesilip çıkarılmış bir alan başka katlama çizgileri içeriyor. +@msg A cut-out area holds other fold lines or another blank. Kesilip çıkarılmış bir alan başka katlama çizgileri veya başka bir açınım içeriyor. @msg A panel is not joined to the rest by a crease. Bir panel geri kalanlara hiçbir pilyaj çizgisiyle bağlı değil. @msg A fold line is on a non-printing layer. Bir katlama çizgisi yazdırılmayan bir katmanda. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Paneller: {panels}, pilyajlar: {hinges}, hatalar: {errors}, uyarılar: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Paneller: {panels}, menteşeler: {hinges}, hatalar: {errors}, uyarılar: {warnings} diff --git a/crates/ui-egui/src/i18n/uk.tsv b/crates/ui-egui/src/i18n/uk.tsv index 84eb22f968..912ae3ac65 100644 --- a/crates/ui-egui/src/i18n/uk.tsv +++ b/crates/ui-egui/src/i18n/uk.tsv @@ -9358,13 +9358,14 @@ breakText Glyphs Гліфи @msg A gap between cut lines was closed. Зазор між лініями різу закрито. @msg The fold lines are too complex to check. Лінії згину надто складні для перевірки. @msg A cut line and a crease lie on top of each other. Лінія різу та лінія біговки лежать одна на одній. -@msg Two lines of the same role lie on top of each other. Дві лінії одного типу лежать одна на одній. +@msg No cut lines are among the given objects. Серед указаних об’єктів немає ліній різу. +@msg Two fold lines lie on top of each other. Дві лінії згину лежать одна на одній. @msg A crease ends inside a panel. Лінія біговки закінчується всередині панелі. @msg A crease does not divide two panels. Лінія біговки не розділяє двох панелей. -@msg A crease lies outside the cut outline. Лінія біговки лежить поза контуром різу. -@msg A crease that is not straight is folded along one straight line. Непряма лінія біговки згинається вздовж однієї прямої. +@msg A crease lies outside the cut outline, wholly or in part. Лінія біговки повністю або частково лежить поза контуром різу. +@msg The pieces of a hinge are not on one straight line. Частини шарніра не лежать на одній прямій. @msg A gap between cut lines is too narrow to tell apart. Зазор між лініями різу надто вузький, щоб його розрізнити. -@msg A cut-out area holds other fold lines. Вирізана область містить інші лінії згину. +@msg A cut-out area holds other fold lines or another blank. Вирізана область містить інші лінії згину або іншу розгортку. @msg A panel is not joined to the rest by a crease. Панель не з’єднана з рештою жодною лінією біговки. @msg A fold line is on a non-printing layer. Лінія згину лежить на шарі, що не друкується. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Панелі: {panels}, біговки: {hinges}, помилки: {errors}, попередження: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Панелі: {panels}, шарніри: {hinges}, помилки: {errors}, попередження: {warnings} diff --git a/crates/ui-egui/src/i18n/vi.tsv b/crates/ui-egui/src/i18n/vi.tsv index 00ac3f7289..8edb621949 100644 --- a/crates/ui-egui/src/i18n/vi.tsv +++ b/crates/ui-egui/src/i18n/vi.tsv @@ -7468,16 +7468,17 @@ breakText Glyphs Glyph @msg A gap between cut lines was closed. Đã đóng một khe hở giữa các đường cắt. @msg The fold lines are too complex to check. Các đường gấp quá phức tạp để kiểm tra. @msg A cut line and a crease lie on top of each other. Một đường cắt và một đường cấn nằm chồng lên nhau. -@msg Two lines of the same role lie on top of each other. Hai đường cùng loại nằm chồng lên nhau. +@msg No cut lines are among the given objects. Các đối tượng đã chỉ định không có đường cắt nào. +@msg Two fold lines lie on top of each other. Hai đường gấp nằm chồng lên nhau. @msg A crease ends inside a panel. Một đường cấn kết thúc bên trong một mặt. @msg A crease does not divide two panels. Một đường cấn không chia tách hai mặt. -@msg A crease lies outside the cut outline. Một đường cấn nằm ngoài đường viền cắt. -@msg A crease that is not straight is folded along one straight line. Đường cấn không thẳng được gấp theo một đường thẳng. +@msg A crease lies outside the cut outline, wholly or in part. Một đường cấn nằm hoàn toàn hoặc một phần ngoài đường viền cắt. +@msg The pieces of a hinge are not on one straight line. Các đoạn của một bản lề không nằm trên một đường thẳng. @msg A gap between cut lines is too narrow to tell apart. Khe hở giữa các đường cắt quá hẹp để phân biệt. -@msg A cut-out area holds other fold lines. Một vùng bị cắt bỏ chứa các đường gấp khác. +@msg A cut-out area holds other fold lines or another blank. Một vùng bị cắt bỏ chứa các đường gấp khác hoặc một khuôn trải khác. @msg A panel is not joined to the rest by a crease. Một mặt không được nối với phần còn lại bằng đường cấn nào. @msg A fold line is on a non-printing layer. Một đường gấp nằm trên lớp không in. -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} Mặt: {panels}, đường cấn: {hinges}, lỗi: {errors}, cảnh báo: {warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} Mặt: {panels}, bản lề: {hinges}, lỗi: {errors}, cảnh báo: {warnings} # Messages of the effects, 3D, image export, color profiles, swatch exchange files, color books and DXF import. @msg 3D effects require finite coordinates within 100 million points Hiệu ứng 3D yêu cầu tọa độ hữu hạn trong phạm vi 100 triệu điểm diff --git a/crates/ui-egui/src/i18n/zh-hans.tsv b/crates/ui-egui/src/i18n/zh-hans.tsv index 40f821ffe4..c6b454a593 100644 --- a/crates/ui-egui/src/i18n/zh-hans.tsv +++ b/crates/ui-egui/src/i18n/zh-hans.tsv @@ -9589,14 +9589,15 @@ breakText Glyphs 字形 @msg A gap between cut lines was closed. 已闭合切割线之间的间隙。 @msg The fold lines are too complex to check. 折线过于复杂,无法检查。 @msg A cut line and a crease lie on top of each other. 一条切割线与一条压痕线重叠。 -@msg Two lines of the same role lie on top of each other. 两条同类线条重叠。 +@msg No cut lines are among the given objects. 指定的对象中没有切割线。 +@msg Two fold lines lie on top of each other. 两条折线重叠。 @msg A crease ends inside a panel. 一条压痕线在面板内部结束。 @msg A crease does not divide two panels. 一条压痕线没有分隔两个面板。 -@msg A crease lies outside the cut outline. 一条压痕线位于切割轮廓之外。 -@msg A crease that is not straight is folded along one straight line. 不直的压痕线沿一条直线折叠。 +@msg A crease lies outside the cut outline, wholly or in part. 一条压痕线全部或部分位于切割轮廓之外。 +@msg The pieces of a hinge are not on one straight line. 铰链的各段不在一条直线上。 @msg A gap between cut lines is too narrow to tell apart. 切割线之间的间隙太窄,无法区分。 -@msg A cut-out area holds other fold lines. 一个镂空区域包含其他折线。 +@msg A cut-out area holds other fold lines or another blank. 一个镂空区域包含其他折线或另一个展开图。 @msg A panel is not joined to the rest by a crease. 一个面板没有通过任何压痕线与其余部分相连。 @msg A fold line is on a non-printing layer. 一条折线位于不打印的图层上。 -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} 面板:{panels},压痕:{hinges},错误:{errors},警告:{warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} 面板:{panels},铰链:{hinges},错误:{errors},警告:{warnings} @msg {w} × {h} pixels is too large for PSD (at most {MAX_SIDE} pixels a side): lower the resolution {w} × {h} 像素对 PSD 而言过大 (每边最多 {MAX_SIDE} 像素):请降低分辨率 diff --git a/crates/ui-egui/src/i18n/zh-hant.tsv b/crates/ui-egui/src/i18n/zh-hant.tsv index 434723a718..576eea439e 100644 --- a/crates/ui-egui/src/i18n/zh-hant.tsv +++ b/crates/ui-egui/src/i18n/zh-hant.tsv @@ -9399,14 +9399,15 @@ breakText Glyphs 字符 @msg A gap between cut lines was closed. 已封閉切割線之間的間隙。 @msg The fold lines are too complex to check. 摺線過於複雜,無法檢查。 @msg A cut line and a crease lie on top of each other. 一條切割線與一條壓痕線重疊。 -@msg Two lines of the same role lie on top of each other. 兩條同類線條重疊。 +@msg No cut lines are among the given objects. 指定的物件中沒有切割線。 +@msg Two fold lines lie on top of each other. 兩條摺線重疊。 @msg A crease ends inside a panel. 一條壓痕線在面板內部結束。 @msg A crease does not divide two panels. 一條壓痕線沒有分隔兩個面板。 -@msg A crease lies outside the cut outline. 一條壓痕線位於切割輪廓之外。 -@msg A crease that is not straight is folded along one straight line. 不直的壓痕線沿一條直線摺疊。 +@msg A crease lies outside the cut outline, wholly or in part. 一條壓痕線全部或部分位於切割輪廓之外。 +@msg The pieces of a hinge are not on one straight line. 鉸鏈的各段不在一條直線上。 @msg A gap between cut lines is too narrow to tell apart. 切割線之間的間隙太窄,無法區分。 -@msg A cut-out area holds other fold lines. 一個鏤空區域包含其他摺線。 +@msg A cut-out area holds other fold lines or another blank. 一個鏤空區域包含其他摺線或另一個展開圖。 @msg A panel is not joined to the rest by a crease. 一個面板沒有透過任何壓痕線與其餘部分相連。 @msg A fold line is on a non-printing layer. 一條摺線位於不列印的圖層上。 -@msg Panels: {panels}, creases: {hinges}, errors: {errors}, warnings: {warnings} 面板:{panels},壓痕:{hinges},錯誤:{errors},警告:{warnings} +@msg Panels: {panels}, hinges: {hinges}, errors: {errors}, warnings: {warnings} 面板:{panels},鉸鏈:{hinges},錯誤:{errors},警告:{warnings} @msg {what} would print on more than {MAX_TILES} tiles: scale it down {what} 會列印在超過 {MAX_TILES} 個拼貼上:請縮小 diff --git a/docs/mcp.md b/docs/mcp.md index e552ec49b7..97e4907ea6 100644 --- a/docs/mcp.md +++ b/docs/mcp.md @@ -13087,8 +13087,8 @@ panel's menu opens it as Role Swatches…. `addon.packaging.check` (`{ids?, select?: false, tolerance?: 0.1}`) finds the blanks, panels and hinges that the fold lines make and lists what is wrong with them. It checks the fold lines among the objects (the selection by default), -through groups and clip groups, or every fold line of the document that is shown while nothing is selected and `ids` is -left out. `tolerance` is in points, from 0.01 to 10; a value outside that range, or one that is not a number or a length +through groups and clip groups, or every fold line of the document while nothing is selected and `ids` is left out. +Hidden lines are left out in every case, also inside a selected group. `tolerance` is in points, from 0.01 to 10; a value outside that range, or one that is not a number or a length such as `"2 mm"`, is an error. The command does not change the document and records no undo step. - Cut lines bound the material. Each connected piece of cut lines that encloses material is one blank. Its outline is its @@ -13105,17 +13105,17 @@ warnings. | Code | Reported when | |---|---| -| `noCut` | No cut line is among the objects. | +| `noCut` | No cut line is among the objects. The message names the selection, the objects `ids` gives, or the document. | | `open` | The cut lines enclose no area. | | `looseEnd` | An end of a cut line meets no other fold line within `tolerance`, and no gap is closed at it. `at` is the end. | | `gap` | An end of a cut line lies within `tolerance` of another cut line without touching it; the panels are built with the gap closed. `at` is the end. | | `tooComplex` | The lines have more than 65,536 segments, or a blank has more than 256 panels. | | `cutOverCrease` | A cut line and a crease, partial cut or perforation lie on top of each other. | -| `duplicate` | Two lines of the same role, or two subpaths of one line, lie on top of each other. | +| `duplicate` | Two cut lines, two crease, partial cut or perforation lines (of the same role or not), or two subpaths of one line, lie on top of each other. | | `danglingCrease` | A crease ends inside a panel. | | `noSplit` | A crease divides no two panels. | -| `outside` | A crease lies outside every blank. | -| `notStraight` | The pieces of a hinge are not on one straight line within `tolerance`; it folds along the line through its longest piece. | +| `outside` | A crease lies outside every blank, or runs outside it for `tolerance` or more. | +| `notStraight` | The pieces of a hinge are not on one straight line within `tolerance`. | | `sliver` | A gap between lines inside a blank is narrower than 0.01 pt. | | `ambiguous` | A hole holds creases, or a blank lies inside another blank's hole. | | `loosePanel` | A panel is joined to its blank's largest panel by no chain of hinges. | @@ -13125,7 +13125,7 @@ Result: `{ok, blanks, panels, hinges, holes, issues: [{severity, code, message, no issue is an error. `message` is in English, and the Fold Lines panel shows it in the interface language. `ids` names the objects each issue is about. With `select: true`, those objects become the selection; when no issue names an object, the selection stays as it is. The Fold Lines panel's Check button runs the same check, shows a summary line -(panels, creases, errors and warnings) and lists the issues; clicking an issue or its Select button selects its objects. +(panels, hinges, errors and warnings) and lists the issues; clicking an issue or its Select button selects its objects. The list is shown until the document changes. ```json