@@ -79,6 +79,7 @@ fn run(app: &mut SlideApp, id: &str, p: Value) {
7979 let _ = app. run ( id, p) ;
8080}
8181
82+ /// Insert a table from the stable row/column fields behind translated captions.
8283fn dlg_table ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
8384 let lang = app. lang ( ) ;
8485 field ( ui, d, i18n:: text ( lang, "dialog.table.columns" ) , "cols" , "5" ) ;
@@ -91,6 +92,7 @@ fn dlg_table(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
9192 ok || cancel
9293}
9394
95+ /// Edit exact slide dimensions and display localized preset names without changing preset identities.
9496fn dlg_slide_size ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
9597 let lang = app. lang ( ) ;
9698 let cur = app. session . active ( ) . map ( |s| s. doc . slide_size ) . unwrap_or ( deckcraft_model:: defaults:: WIDE ) ;
@@ -141,6 +143,7 @@ fn dlg_slide_size(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
141143 ok || cancel
142144}
143145
146+ /// Apply header/footer choices without rewriting untouched date-format values.
144147fn dlg_header_footer ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
145148 let lang = app. lang ( ) ;
146149 let hf = app. session . active ( ) . map ( |s| s. doc . header_footer . clone ( ) ) . unwrap_or_default ( ) ;
@@ -200,6 +203,7 @@ fn dlg_header_footer(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
200203 apply || apply_all || d. fields . contains_key ( "cancel" )
201204}
202205
206+ /// Edit hyperlink display fields while preserving stored link kinds and target parameters.
203207fn dlg_hyperlink ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
204208 let lang = app. lang ( ) ;
205209 let seed = hyperlink_seed_of ( app. session . active ( ) ) ;
@@ -250,6 +254,7 @@ fn dlg_hyperlink(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
250254 ok || cancel
251255}
252256
257+ /// Configure playback options with translated captions and the existing show values.
253258fn dlg_setup_show ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
254259 let lang = app. lang ( ) ;
255260 let sh = app. session . active ( ) . map ( |s| s. doc . show . clone ( ) ) . unwrap_or_default ( ) ;
@@ -294,6 +299,7 @@ fn dlg_setup_show(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
294299 ok || cancel
295300}
296301
302+ /// Resolve save/discard/cancel decisions for dirty presentations before application exit.
297303fn dlg_quit ( app : & mut SlideApp , ui : & mut Ui , _d : & mut Dialog ) -> bool {
298304 let lang = app. lang ( ) ;
299305 let names: Vec < String > = app. session . documents ( ) . iter ( ) . filter ( |d| d. is_dirty ( ) ) . map ( |d| d. title ( ) ) . collect ( ) ;
@@ -338,6 +344,7 @@ fn dlg_quit(app: &mut SlideApp, ui: &mut Ui, _d: &mut Dialog) -> bool {
338344 done
339345}
340346
347+ /// Resolve save/discard/cancel for the active presentation.
341348fn dlg_close ( app : & mut SlideApp , ui : & mut Ui , _d : & mut Dialog ) -> bool {
342349 let lang = app. lang ( ) ;
343350 // File › Close and Ctrl+W on a presentation with unsaved changes.
@@ -374,6 +381,7 @@ fn dlg_close(app: &mut SlideApp, ui: &mut Ui, _d: &mut Dialog) -> bool {
374381 done
375382}
376383
384+ /// Post nonempty user-authored comment text through the existing comment command.
377385fn dlg_comment ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
378386 let lang = app. lang ( ) ;
379387 let mut v = d. get ( "text" , "" ) ;
@@ -490,6 +498,7 @@ fn dlg_bullets(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
490498 ok || cancel || none
491499}
492500
501+ /// Edit shape interaction settings while retaining their stored action kinds and targets.
493502fn dlg_action ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
494503 let lang = app. lang ( ) ;
495504 use deckcraft_model:: text:: Action ;
@@ -615,6 +624,7 @@ fn dlg_action(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
615624 ok || cancel
616625}
617626
627+ /// Edit descriptive text and the decorative flag without translating user-authored content.
618628fn dlg_alt_text ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
619629 let lang = app. lang ( ) ;
620630 let ( cur, deco_now) = app
@@ -639,6 +649,7 @@ fn dlg_alt_text(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
639649 ok || cancel
640650}
641651
652+ /// Insert slides from the entered outline, keeping the outline text literal.
642653fn dlg_outline ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
643654 let lang = app. lang ( ) ;
644655 ui. label ( i18n:: text ( lang, "dialog.outline.description" ) ) ;
@@ -652,6 +663,7 @@ fn dlg_outline(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
652663 ok || cancel
653664}
654665
666+ /// Choose source slides for reuse while preserving presentation names and command parameters.
655667fn dlg_reuse_slides ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
656668 let lang = app. lang ( ) ;
657669 let path = d. params . get ( "path" ) . and_then ( Value :: as_str) . unwrap_or ( "" ) . to_string ( ) ;
@@ -716,6 +728,7 @@ fn dlg_reuse_slides(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
716728 cancel
717729}
718730
731+ /// Rename a section, shape or layout while preserving its target identity.
719732fn dlg_rename_section ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
720733 let lang = app. lang ( ) ;
721734 let cur = d. params . get ( "name" ) . and_then ( Value :: as_str) . unwrap_or ( "" ) . to_string ( ) ;
@@ -732,6 +745,7 @@ fn dlg_rename_section(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
732745 ok || cancel
733746}
734747
748+ /// Choose an export action using localized captions and the existing export parameters.
735749fn dlg_export ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
736750 let lang = app. lang ( ) ;
737751 ui. label ( i18n:: text ( lang, "dialog.export.description" ) ) ;
@@ -878,6 +892,7 @@ fn dlg_replace_fonts(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
878892 cancel
879893}
880894
895+ /// Display localized symbol-group captions and insert the selected original character.
881896fn dlg_symbol ( app : & mut SlideApp , ui : & mut Ui , _d : & mut Dialog ) -> bool {
882897 let lang = app. lang ( ) ;
883898 ui. label ( i18n:: text ( lang, "dialog.symbol.description" ) ) ;
@@ -906,6 +921,7 @@ fn dlg_symbol(app: &mut SlideApp, ui: &mut Ui, _d: &mut Dialog) -> bool {
906921 ok || cancel
907922}
908923
924+ /// Insert an equation from literal user input behind localized dialog captions.
909925fn dlg_equation ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
910926 let lang = app. lang ( ) ;
911927 ui. label ( i18n:: text ( lang, "dialog.equation.description" ) ) ;
@@ -947,6 +963,7 @@ fn dlg_paste_special(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
947963 ok || cancel
948964}
949965
966+ /// Review spelling results and route actions to their original slide and shape identifiers.
950967fn dlg_spelling ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
951968 let lang = app. lang ( ) ;
952969 // Words skipped with Ignore All while the dialog is open, one per line.
@@ -1091,6 +1108,7 @@ fn dlg_spelling(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
10911108 ok || cancel
10921109}
10931110
1111+ /// Display accessibility results and navigate to the original reported object.
10941112fn dlg_accessibility ( app : & mut SlideApp , ui : & mut Ui , _d : & mut Dialog ) -> bool {
10951113 let lang = app. lang ( ) ;
10961114 let v = app. session . execute ( "review.accessibility" , & json ! ( { } ) ) . unwrap_or_default ( ) ;
@@ -1120,6 +1138,7 @@ fn dlg_accessibility(app: &mut SlideApp, ui: &mut Ui, _d: &mut Dialog) -> bool {
11201138 ok || cancel
11211139}
11221140
1141+ /// Set text proofing language independently of the interface-language choice.
11231142fn dlg_language ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
11241143 let ui_lang = app. lang ( ) ;
11251144 // Starts from the selected text's language and Do Not Check Spelling.
@@ -1169,6 +1188,7 @@ fn dlg_language(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
11691188 ok || cancel
11701189}
11711190
1191+ /// Manage custom shows without translating their names or stored slide lists.
11721192fn dlg_custom_show ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
11731193 let lang = app. lang ( ) ;
11741194 let shows = app. session . active ( ) . map ( |s| s. doc . custom_shows . clone ( ) ) . unwrap_or_default ( ) ;
@@ -1199,6 +1219,7 @@ fn dlg_custom_show(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
11991219 ok || cancel
12001220}
12011221
1222+ /// Edit literal chart data behind localized controls and retain the existing grid format.
12021223fn dlg_chart_data ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
12031224 let lang = app. lang ( ) ;
12041225 let ch = app. session . active ( ) . and_then ( |s| {
@@ -1253,6 +1274,7 @@ fn dlg_chart_data(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
12531274 ok || cancel
12541275}
12551276
1277+ /// Apply media trimming and fade values through the existing command fields.
12561278fn dlg_trim ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
12571279 let lang = app. lang ( ) ;
12581280 let seed = trim_seed ( app. session . active ( ) ) ;
@@ -1276,6 +1298,7 @@ fn dlg_trim(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
12761298 ok || cancel
12771299}
12781300
1301+ /// Insert the chosen SmartArt kind with literal user-authored item text.
12791302fn dlg_smartart ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
12801303 let lang = app. lang ( ) ;
12811304 ui. label ( i18n:: text ( lang, "dialog.smartart.description" ) ) ;
@@ -1305,6 +1328,7 @@ fn dlg_smartart(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
13051328 ok || cancel
13061329}
13071330
1331+ /// Switch credit sections by stable keys while localizing their visible captions.
13081332fn dlg_about ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
13091333 let lang = app. lang ( ) ;
13101334 let tab = d. get ( "tab" , "about" ) ;
@@ -1330,6 +1354,7 @@ fn dlg_about(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
13301354 ok || cancel
13311355}
13321356
1357+ /// Edit autocorrection preferences without translating user-defined replacements.
13331358fn dlg_autocorrect ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
13341359 let lang = app. lang ( ) ;
13351360 let pr = & mut app. session . prefs ;
@@ -1376,6 +1401,7 @@ fn dlg_autocorrect(app: &mut SlideApp, ui: &mut Ui, d: &mut Dialog) -> bool {
13761401 ok || cancel
13771402}
13781403
1404+ /// Preview preferences and restore the opening snapshot, including language, on cancellation.
13791405fn dlg_preferences ( app : & mut SlideApp , ui : & mut Ui , d : & mut Dialog ) -> bool {
13801406 let lang = app. lang ( ) ;
13811407 // The controls apply as they change, so the dialog remembers what it opened with and
0 commit comments