From e2424c06d3bfa552f35fb288429c3ef4e5357cc7 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Thu, 24 Mar 2022 12:38:41 -0400 Subject: latex output (try tidy); linebreaks more generally --- src/doc_reform/io_out/rgx.d | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/doc_reform/io_out/rgx.d') diff --git a/src/doc_reform/io_out/rgx.d b/src/doc_reform/io_out/rgx.d index 37ad39c..07133e7 100644 --- a/src/doc_reform/io_out/rgx.d +++ b/src/doc_reform/io_out/rgx.d @@ -61,6 +61,7 @@ static template spineRgxOut() { static spaces_keep = ctRegex!(`(?P^[ ]+|[ ]{2,})`, "mg"); // code, verse, block static spaces_line_start = ctRegex!(`^(?P[ ]+)`, "mg"); static nbsp_char = ctRegex!(`░`, "mg"); + static nbsp_chars = ctRegex!(`[░]+`, "mg"); static src_pth_sst_or_ssm = ctRegex!(`^(?P[/]?(?:[a-zA-Z0-9._-]+/)*)(?P[a-zA-Z0-9._-]+[.](?Pss[tm]))$`); static src_pth_pod_sst_or_ssm = ctRegex!(`^(?P[/]?(?:[a-zA-Z0-9._-]+/)*)media/text/[a-z]{2}/(?P[a-zA-Z0-9][a-zA-Z0-9._-]*?[.]ss[tm])$`); static src_pth_contents = ctRegex!(`^(?P[/]?(?:[a-zA-Z0-9._-]+/)*)(?P[a-zA-Z0-9][a-zA-Z0-9._-]*)/pod[.]manifest$`); @@ -76,9 +77,12 @@ static template spineRgxOut() { static src_formalised_file_path_parts = ctRegex!(`(?P(?:[/a-zA-Z0-9._-]+?)(?P[a-zA-Z0-9._-]+))(?:/media/text/[a-z]{2})$`); // formalizes dir structure /+ line breaks +/ static br_empty_line = ctRegex!(`\n[ ]*\n`, "mg"); - static br_newlines_linebreaks = ctRegex!(`[\n┘┙]`, "mg"); + static br_linebreaks_newlines = ctRegex!(`[\n┘┙]`, "mg"); + static br_linebreaks = ctRegex!(`[┘┙]`, "mg"); static br_line = ctRegex!(`┘`, "mg"); - static br_newline_inline = ctRegex!(`┙`, "mg"); + static br_line_inline = ctRegex!(`┙`, "mg"); + static br_line_spaced = ctRegex!(`┚`, "mg"); + static brln = ctRegex!(`(?:\\\\)+`, "mg"); /+ inline markup footnotes endnotes +/ static inline_notes_al = ctRegex!(`【(?:[*+]\s+|\s*)(.+?)】`, "mg"); static inline_notes_al_special = ctRegex!(`【(?:[*+]\s+)(.+?)】`, "mg"); // TODO remove match when special footnotes are implemented -- cgit v1.2.3