aboutsummaryrefslogtreecommitdiffhomepage
path: root/org
diff options
context:
space:
mode:
Diffstat (limited to 'org')
-rw-r--r--org/default_regex.org1
-rw-r--r--org/meta_abstraction.org8
2 files changed, 3 insertions, 6 deletions
diff --git a/org/default_regex.org b/org/default_regex.org
index e02c3a3..80e3cde 100644
--- a/org/default_regex.org
+++ b/org/default_regex.org
@@ -422,6 +422,7 @@ static xhtml_line_break = ctRegex!(` [\\]{2}`); // <br
static newline = ctRegex!("\n", "mg");
static strip_br = ctRegex!("^<br>\n|<br>\n*$");
static space = ctRegex!(`[ ]`, "mg");
+static spaces_keep = ctRegex!(`(?P<keep_spaces>^[ ]+|[ ]{2,})`, "mg"); // code, verse, block
static spaces_line_start = ctRegex!(`^(?P<opening_spaces>[ ]+)`, "mg");
static spaces_multiple = ctRegex!(`(?P<multiple_spaces>[ ]{2,})`, "mg");
static two_spaces = ctRegex!(`[ ]{2}`, "mg");
diff --git a/org/meta_abstraction.org b/org/meta_abstraction.org
index 10153c8..f4a6f62 100644
--- a/org/meta_abstraction.org
+++ b/org/meta_abstraction.org
@@ -964,13 +964,9 @@ if there is a blurb section you need to:
/+ within block object: block +/
line = line._doc_header_and_make_substitutions_(conf_make_meta);
line = line._doc_header_and_make_substitutions_fontface_(conf_make_meta);
- if (auto m = line.match(rgx.spaces_line_start)) {
+ if (auto m = line.match(rgx.spaces_keep)) {
line = line
- .replaceAll(rgx.spaces_line_start, (m.captures[1]).translate([ ' ' : mkup.nbsp ]));
- }
- if (auto m = line.match(rgx.spaces_multiple)) {
- line = line
- .replaceAll(rgx.spaces_multiple, (m.captures[1]).translate([ ' ' : mkup.nbsp ]));
+ .replaceAll(rgx.spaces_keep, (m.captures[1]).translate([ ' ' : mkup.nbsp ]));
}
line._block_block_(an_object, obj_type_status);
continue;