aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sdp/meta/conf_make_meta_structs.d
diff options
context:
space:
mode:
Diffstat (limited to 'src/sdp/meta/conf_make_meta_structs.d')
-rw-r--r--src/sdp/meta/conf_make_meta_structs.d65
1 files changed, 50 insertions, 15 deletions
diff --git a/src/sdp/meta/conf_make_meta_structs.d b/src/sdp/meta/conf_make_meta_structs.d
index 41af6ba..a5d2c15 100644
--- a/src/sdp/meta/conf_make_meta_structs.d
+++ b/src/sdp/meta/conf_make_meta_structs.d
@@ -9,20 +9,45 @@ import
std.typecons,
std.utf,
std.conv : to;
+import
+ sdp.meta.defaults,
+ sdp.meta.rgx;
+mixin SiSUrgxInit;
+static auto _rgx = Rgx();
+mixin InternalMarkup;
+auto _mkup = InlineMarkup();
+auto url_markup(string line) {
+ auto line_ = (line)
+ .replaceAll(
+ _rgx.inline_link_markup_regular,
+ ("$1"
+ ~ _mkup.lnk_o ~ "$2" ~ _mkup.lnk_c
+ ~ _mkup.url_o ~ "$3" ~ _mkup.url_c
+ ~ "$4") // ("$1{ $2 }$3$4")
+ )
+ .replaceAll(
+ _rgx.inline_link_naked_url,
+ ("$1"
+ ~ _mkup.lnk_o ~ "$2" ~ _mkup.lnk_c
+ ~ _mkup.url_o ~ "$2" ~ _mkup.url_c
+ ~ "$3") // ("$1{ $2 }$2$3")
+ );
+ return line_;
+}
struct ConfCompositeMakeStr {
string bold;
string breaks;
string cover_image;
string css;
string emphasis;
- string footer;
+ string[] footer;
string[] headings;
- string home_button_image;
- string home_button_text;
+ string[] home_button_image;
+ string[] home_button_text;
string italics;
string auto_num_top_at_level;
int auto_num_top_lv = 9;
- int num_depth = 2;
+ int auto_num_depth = 2;
string[][] substitute;
string texpdf_font;
}
@@ -50,17 +75,27 @@ struct confCompositeMakeBuild {
}
return _out;
}
- auto footer(string _mk) {
- return _mk;
+ auto footer(string[] _mk) {
+ string line_;
+ string[] _mk2;
+ foreach (line; _mk) {
+ _mk2 ~= url_markup(line);
+ }
+ return _mk2;
}
auto headings(string[] _mk) {
return _mk;
}
- auto home_button_image(string _mk) {
+ auto home_button_image(string[] _mk) {
return _mk;
}
- auto home_button_text(string _mk) {
- return _mk;
+ auto home_button_text(string[] _mk) {
+ string line_;
+ string[] _mk2;
+ foreach (line; _mk) {
+ _mk2 ~= url_markup(line);
+ }
+ return _mk2;
}
auto italics(string _mk) {
string[] _out;
@@ -75,7 +110,7 @@ struct confCompositeMakeBuild {
auto auto_num_top_lv(int _mk) {
return _mk;
}
- auto num_depth(int _mk) {
+ auto auto_num_depth(int _mk) {
return _mk;
}
auto substitute(string[][] _mk) {
@@ -91,14 +126,14 @@ struct ConfCompositeMakeInit {
string cover_image;
string css;
string[] emphasis;
- string footer;
+ string[] footer;
string[] headings;
- string home_button_image;
- string home_button_text;
+ string[] home_button_image;
+ string[] home_button_text;
string[] italics;
string auto_num_top_at_level;
int auto_num_top_lv = 9;
- int num_depth = 2;
+ int auto_num_depth = 2;
string[][] substitute;
string texpdf_font;
}
@@ -248,7 +283,7 @@ static auto ptr_head_sub_make
"home_button_image",
"home_button_text",
"footer", "headings",
- "auto_num_top_at_level", "auto_num_top_lv", "num_depth",
+ "auto_num_top_at_level", "auto_num_top_lv", "auto_num_depth",
"breaks",
"substitute",
"bold",