VectorCraft: An open-source, vector art tool written by scratch in pure Rust
MCP: a cancelled export keeps no partly drawn tile or raster, and its message is translated (#2165)
bflatastic51f8582c25e4
diff --git a/crates/render/src/fx.rs b/crates/render/src/fx.rsindex 3082d49aa..1fc0b5a03 100644--- a/crates/render/src/fx.rs+++ b/crates/render/src/fx.rs@@ -1284,7 +1284,10 @@ impl Renderer {}}let image = std::sync::Arc::new(pm);- if let Some(((key, made), inputs)) = key.zip(made).zip(inputs) {+ // A cancelled export drew part of the content: that raster isn't kept for later frames.+ if !vectorcraft_doc::cancel::is_cancelled()+ && let Some(((key, made), inputs)) = key.zip(made).zip(inputs)+ {let anchor = content.reach.origin();let p = f.view * anchor;let rel = (x0 - p.x, y0 - p.y);diff --git a/crates/render/src/pattern.rs b/crates/render/src/pattern.rsindex 7008e1ecb..0f31a9e32 100644--- a/crates/render/src/pattern.rs+++ b/crates/render/src/pattern.rs@@ -258,7 +258,11 @@ pub(crate) fn set_pattern_paint(ctx: &mut RenderContext, name: &str, xf: Affine,let pm = Arc::new(pm);let (sx, sy) = (w as f64 / pw, h as f64 / ph);let deps = crate::fx::Reads::of_all(def.art.iter().map(|a| &**a)).any().then(|| Deps::of(doc));+ // A cancelled export drew part of the tile: it isn't kept for later frames.CACHE.with(|c| {+ if vectorcraft_doc::cancel::is_cancelled() {+ return;+ }let mut c = c.borrow_mut();let tiles = &mut c.tiles[ink as usize];let (t, bytes) = (tiles.tick(), size_of::<TileEntry>() + w as usize * h as usize * 4);diff --git a/crates/ui-egui/src/i18n/cs.tsv b/crates/ui-egui/src/i18n/cs.tsvindex c82dac4bd..d30d0166c 100644--- a/crates/ui-egui/src/i18n/cs.tsv+++ b/crates/ui-egui/src/i18n/cs.tsv@@ -5001,3 +5001,4 @@ mark-style Japanese Japonské@msg no symbol named `{n}` žádný symbol s názvem `{n}`@msg a mask has more than one art block maska má více než jeden blok kresby@msg mask art ends outside a mask dictionary kresba masky končí mimo slovník masky+@msg cancelled; nothing was changed zrušeno; nic nebylo změněnodiff --git a/crates/ui-egui/src/i18n/de.tsv b/crates/ui-egui/src/i18n/de.tsvindex 4dab81245..92074af90 100644--- a/crates/ui-egui/src/i18n/de.tsv+++ b/crates/ui-egui/src/i18n/de.tsv@@ -4538,3 +4538,4 @@ theme Appearance Erscheinungsbild@msg no symbol named `{n}` kein Symbol namens `{n}`@msg a mask has more than one art block eine Maske enthält mehr als einen Grafikblock@msg mask art ends outside a mask dictionary die Maskengrafik endet außerhalb eines Maskenwörterbuchs+@msg cancelled; nothing was changed abgebrochen; es wurde nichts geändertdiff --git a/crates/ui-egui/src/i18n/el.tsv b/crates/ui-egui/src/i18n/el.tsvindex 7a7faf3ef..5cc3023d9 100644--- a/crates/ui-egui/src/i18n/el.tsv+++ b/crates/ui-egui/src/i18n/el.tsv@@ -4953,3 +4953,4 @@ effect Points Σημεία@msg no symbol named `{n}` κανένα σύμβολο με όνομα `{n}`@msg a mask has more than one art block η μάσκα έχει περισσότερα από ένα μπλοκ γραφικών@msg mask art ends outside a mask dictionary τα γραφικά της μάσκας τελειώνουν έξω από το λεξικό της μάσκας+@msg cancelled; nothing was changed ακυρώθηκε· δεν άλλαξε τίποταdiff --git a/crates/ui-egui/src/i18n/es.tsv b/crates/ui-egui/src/i18n/es.tsvindex 5b9a77e07..ce0da6fe8 100644--- a/crates/ui-egui/src/i18n/es.tsv+++ b/crates/ui-egui/src/i18n/es.tsv@@ -4943,3 +4943,4 @@ mark-style Japanese Japonesas@msg no symbol named `{n}` no hay ningún símbolo llamado `{n}`@msg a mask has more than one art block una máscara tiene más de un bloque de ilustración@msg mask art ends outside a mask dictionary la ilustración de la máscara termina fuera de un diccionario de máscara+@msg cancelled; nothing was changed cancelado; no se ha cambiado nadadiff --git a/crates/ui-egui/src/i18n/fi.tsv b/crates/ui-egui/src/i18n/fi.tsvindex c56c95af8..4e5bb0b35 100644--- a/crates/ui-egui/src/i18n/fi.tsv+++ b/crates/ui-egui/src/i18n/fi.tsv@@ -4965,3 +4965,4 @@ mark-style Japanese Japanilainen@msg no symbol named `{n}` symbolia nimeltä `{n}` ei ole@msg a mask has more than one art block maskissa on useampi kuin yksi grafiikkalohko@msg mask art ends outside a mask dictionary maskin grafiikka päättyy maskin sanakirjan ulkopuolelle+@msg cancelled; nothing was changed peruutettu; mitään ei muutettudiff --git a/crates/ui-egui/src/i18n/fr.tsv b/crates/ui-egui/src/i18n/fr.tsvindex 747fdce72..6c011a2ce 100644--- a/crates/ui-egui/src/i18n/fr.tsv+++ b/crates/ui-egui/src/i18n/fr.tsv@@ -5000,3 +5000,4 @@ theme Appearance Apparence@msg no symbol named `{n}` aucun symbole nommé `{n}`@msg a mask has more than one art block un masque contient plusieurs blocs graphiques@msg mask art ends outside a mask dictionary les éléments graphiques du masque se terminent en dehors d’un dictionnaire de masque+@msg cancelled; nothing was changed annulé ; rien n'a été modifiédiff --git a/crates/ui-egui/src/i18n/hu.tsv b/crates/ui-egui/src/i18n/hu.tsvindex d3de3b4f7..27a6eb2b5 100644--- a/crates/ui-egui/src/i18n/hu.tsv+++ b/crates/ui-egui/src/i18n/hu.tsv@@ -4968,3 +4968,4 @@ imageTrace Outline Körvonal@msg no symbol named `{n}` nincs `{n}` nevű szimbólum@msg a mask has more than one art block egy maszk egynél több grafikai blokkot tartalmaz@msg mask art ends outside a mask dictionary a maszk grafikája a maszk szótárán kívül ér véget+@msg cancelled; nothing was changed megszakítva; semmi sem változottdiff --git a/crates/ui-egui/src/i18n/it.tsv b/crates/ui-egui/src/i18n/it.tsvindex cf158f674..7cffb8995 100644--- a/crates/ui-egui/src/i18n/it.tsv+++ b/crates/ui-egui/src/i18n/it.tsv@@ -4578,3 +4578,4 @@ lighting Light Luce@msg no symbol named `{n}` nessun simbolo denominato `{n}`@msg a mask has more than one art block una maschera contiene più di un blocco grafico@msg mask art ends outside a mask dictionary la grafica della maschera termina fuori da un dizionario di maschera+@msg cancelled; nothing was changed annullato; non è stato modificato nulladiff --git a/crates/ui-egui/src/i18n/ja.tsv b/crates/ui-egui/src/i18n/ja.tsvindex 1e7363b0d..abe633da1 100644--- a/crates/ui-egui/src/i18n/ja.tsv+++ b/crates/ui-egui/src/i18n/ja.tsv@@ -4619,3 +4619,4 @@ lighting Light ライト@msg no symbol named `{n}` `{n}` という名前のシンボルはありません@msg a mask has more than one art block マスクに複数のアートブロックがあります@msg mask art ends outside a mask dictionary マスクのアートがマスク辞書の外で終わっています+@msg cancelled; nothing was changed キャンセルしました。何も変更されていませんdiff --git a/crates/ui-egui/src/i18n/ko.tsv b/crates/ui-egui/src/i18n/ko.tsvindex f344bd74d..2d36be8b6 100644--- a/crates/ui-egui/src/i18n/ko.tsv+++ b/crates/ui-egui/src/i18n/ko.tsv@@ -4542,3 +4542,4 @@ lighting Light 광원@msg no symbol named `{n}` 이름이 `{n}`인 심볼이 없습니다@msg a mask has more than one art block 마스크에 아트 블록이 두 개 이상 있습니다@msg mask art ends outside a mask dictionary 마스크 아트가 마스크 사전 밖에서 끝납니다+@msg cancelled; nothing was changed 취소됨; 변경된 내용이 없습니다diff --git a/crates/ui-egui/src/i18n/pl.tsv b/crates/ui-egui/src/i18n/pl.tsvindex f393772ab..08b10404f 100644--- a/crates/ui-egui/src/i18n/pl.tsv+++ b/crates/ui-egui/src/i18n/pl.tsv@@ -4846,3 +4846,4 @@ mark-style Japanese Japońskie@msg no symbol named `{n}` brak symbolu o nazwie `{n}`@msg a mask has more than one art block maska ma więcej niż jeden blok grafiki@msg mask art ends outside a mask dictionary grafika maski kończy się poza słownikiem maski+@msg cancelled; nothing was changed anulowano; nic nie zostało zmienionediff --git a/crates/ui-egui/src/i18n/pt-br.tsv b/crates/ui-egui/src/i18n/pt-br.tsvindex 52ddf636d..4fe9c2ca5 100644--- a/crates/ui-egui/src/i18n/pt-br.tsv+++ b/crates/ui-egui/src/i18n/pt-br.tsv@@ -4918,3 +4918,4 @@ mark-style Japanese Japonesas@msg no symbol named `{n}` nenhum símbolo chamado `{n}`@msg a mask has more than one art block uma máscara contém mais de um bloco de arte@msg mask art ends outside a mask dictionary a arte da máscara termina fora de um dicionário de máscara+@msg cancelled; nothing was changed cancelado; nada foi alteradodiff --git a/crates/ui-egui/src/i18n/ru.tsv b/crates/ui-egui/src/i18n/ru.tsvindex d7967aeba..c3ca047a8 100644--- a/crates/ui-egui/src/i18n/ru.tsv+++ b/crates/ui-egui/src/i18n/ru.tsv@@ -4574,3 +4574,4 @@ lighting Light Свет@msg no symbol named `{n}` нет символа с именем `{n}`@msg a mask has more than one art block маска содержит более одного блока графики@msg mask art ends outside a mask dictionary графика маски заканчивается за пределами словаря маски+@msg cancelled; nothing was changed отменено; ничего не измененоdiff --git a/crates/ui-egui/src/i18n/sv.tsv b/crates/ui-egui/src/i18n/sv.tsvindex 1f623cfbc..367aeab82 100644--- a/crates/ui-egui/src/i18n/sv.tsv+++ b/crates/ui-egui/src/i18n/sv.tsv@@ -4957,3 +4957,4 @@ theme Appearance Utseende@msg no symbol named `{n}` ingen symbol med namnet `{n}`@msg a mask has more than one art block en mask innehåller mer än ett grafikblock@msg mask art ends outside a mask dictionary maskens grafik slutar utanför en maskordlista+@msg cancelled; nothing was changed avbrutet; inget ändradesdiff --git a/crates/ui-egui/src/i18n/uk.tsv b/crates/ui-egui/src/i18n/uk.tsvindex 509f2507f..22c386082 100644--- a/crates/ui-egui/src/i18n/uk.tsv+++ b/crates/ui-egui/src/i18n/uk.tsv@@ -4558,3 +4558,4 @@ lighting Light Світло@msg no symbol named `{n}` немає символу з назвою `{n}`@msg a mask has more than one art block маска містить більше одного блоку графіки@msg mask art ends outside a mask dictionary графіка маски закінчується за межами словника маски+@msg cancelled; nothing was changed скасовано; нічого не зміненоdiff --git a/crates/ui-egui/src/i18n/vi.tsv b/crates/ui-egui/src/i18n/vi.tsvindex 250c3e2bc..62232418c 100644--- a/crates/ui-egui/src/i18n/vi.tsv+++ b/crates/ui-egui/src/i18n/vi.tsv@@ -4558,3 +4558,4 @@ theme Appearance Giao diện@msg no symbol named `{n}` không có biểu tượng nào tên `{n}`@msg a mask has more than one art block mặt nạ có nhiều hơn một khối đồ họa@msg mask art ends outside a mask dictionary đồ họa mặt nạ kết thúc bên ngoài từ điển mặt nạ+@msg cancelled; nothing was changed đã hủy; không có gì thay đổidiff --git a/crates/ui-egui/src/i18n/zh-hans.tsv b/crates/ui-egui/src/i18n/zh-hans.tsvindex bc23a1fcf..3e5782fd2 100644--- a/crates/ui-egui/src/i18n/zh-hans.tsv+++ b/crates/ui-egui/src/i18n/zh-hans.tsv@@ -4106,3 +4106,4 @@ lighting Light 光源Movie Clip 影片剪辑@msg name is empty 名称为空@msg no symbol named `{n}` 没有名为 `{n}` 的符号+@msg cancelled; nothing was changed 已取消;未做任何更改