From 575100e844f6463f497ba523ed20b8cdc099579e Mon Sep 17 00:00:00 2001 From: Graham Nelson Date: Thu, 2 Feb 2023 23:16:53 +0000 Subject: [PATCH] Progress towards extensions containing language bundles --- README.md | 2 +- build.txt | 4 +- docs/core-module/2-pwst.html | 22 ++++- docs/if-module/2-tbf.html | 16 ++- docs/multimedia-module/2-rf.html | 91 +++++++++++------ docs/supervisor-module/2-ce.html | 5 +- docs/supervisor-module/2-cps.html | 2 +- docs/supervisor-module/2-nst.html | 6 +- docs/supervisor-module/3-is2.html | 1 + docs/supervisor-module/5-es.html | 18 +++- docs/supervisor-module/5-ls.html | 37 +++++++ docs/supervisor-module/5-ps2.html | 66 ++++++++----- .../supervisor-module/Chapter 2/Copy Errors.w | 3 + .../Chapter 3/Inform7 Skill.w | 1 + .../Chapter 5/Extension Services.w | 14 ++- .../Chapter 5/Language Services.w | 37 +++++++ .../Chapter 5/Project Services.w | 20 +++- inform7/Figures/memory-diagnostics.txt | 97 ++++++++++--------- inform7/Figures/timings-diagnostics.txt | 27 +++--- .../BasicInformExtrasKit/kit_metadata.json | 2 +- .../Inter/BasicInformKit/kit_metadata.json | 2 +- .../Inter/CommandParserKit/kit_metadata.json | 2 +- .../EnglishLanguageKit/kit_metadata.json | 2 +- .../Inter/WorldModelKit/kit_metadata.json | 2 +- .../Chapter 2/Problems With Source Text.w | 22 ++++- inform7/if-module/Chapter 2/The Blurb File.w | 16 ++- .../Chapter 2/Resource Finder.w | 80 +++++++++------ 27 files changed, 422 insertions(+), 175 deletions(-) diff --git a/README.md b/README.md index 081daaa59..f6021eee8 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Inform 7 -[Version](notes/versioning.md): 10.2.0-beta+6W19 'Krypton' (1 February 2023) +[Version](notes/versioning.md): 10.2.0-beta+6W20 'Krypton' (2 February 2023) ## About Inform diff --git a/build.txt b/build.txt index c96116cda..810167e72 100644 --- a/build.txt +++ b/build.txt @@ -1,3 +1,3 @@ Prerelease: beta -Build Date: 1 February 2023 -Build Number: 6W19 +Build Date: 2 February 2023 +Build Number: 6W20 diff --git a/docs/core-module/2-pwst.html b/docs/core-module/2-pwst.html index da6c2fbd2..eb5286078 100644 --- a/docs/core-module/2-pwst.html +++ b/docs/core-module/2-pwst.html @@ -103,7 +103,7 @@ group. if (CE->copy->found_by) { Problems::quote_work(1, CE->copy->found_by->work); Problems::quote_stream(2, CE->details); - Problems::quote_stream(3, CE->copy->edition->work->genre->genre_name); + SourceProblems::quote_genre(3, CE); StandardProblems::handmade_problem(Task::syntax_tree(), _p_(Untestable)); Problems::issue_problem_segment( "The %3 %1, which your source text makes use of, seems to have " @@ -112,13 +112,23 @@ group. } else { Problems::quote_work(1, CE->copy->edition->work); Problems::quote_stream(2, CE->details); - Problems::quote_stream(3, CE->copy->edition->work->genre->genre_name); + SourceProblems::quote_genre(3, CE); StandardProblems::handmade_problem(Task::syntax_tree(), _p_(Untestable)); Problems::issue_problem_segment( "The %3 %1 seems to have metadata problems. Specifically: %2."); Problems::issue_problem_end(); } break; + case LANGUAGE_UNAVAILABLE_CE: + Problems::quote_work(1, CE->copy->edition->work); + Problems::quote_stream(2, CE->details); + SourceProblems::quote_genre(3, CE); + StandardProblems::handmade_problem(Task::syntax_tree(), _p_(Untestable)); + Problems::issue_problem_segment( + "The %3 %1 seems to need me to know about a non-English language, '%2'. " + "I can't find any definition for this language."); + Problems::issue_problem_end(); + break; case EXT_TITLE_TOO_LONG_CE: { int max = MAX_EXTENSION_TITLE_LENGTH; int overage = CE->details_N - MAX_EXTENSION_TITLE_LENGTH; @@ -603,6 +613,14 @@ group. } } } + +void SourceProblems::quote_genre(int N, copy_error *CE) { + text_stream *name = CE->copy->edition->work->genre->genre_name; + if (Str::eq(name, I"projectbundle")) name = I"project"; + if (Str::eq(name, I"projectfile")) name = I"project"; + if (Str::eq(name, I"extensionbundle")) name = I"extension"; + Problems::quote_stream(N, name); +}