summaryrefslogtreecommitdiff
path: root/support/latexindent/LatexIndent/GetYamlSettings.pm
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-08-01 03:00:39 +0000
committerNorbert Preining <norbert@preining.info>2021-08-01 03:00:39 +0000
commit956b25a304207d06fe012f8c8efcb13cc66e3eec (patch)
tree31afb75255717f047a6833a290bd6533678ff4d5 /support/latexindent/LatexIndent/GetYamlSettings.pm
parent6476d9b56070f64c62d6a81514c0c9b25aad1eda (diff)
CTAN sync 202108010300
Diffstat (limited to 'support/latexindent/LatexIndent/GetYamlSettings.pm')
-rw-r--r--support/latexindent/LatexIndent/GetYamlSettings.pm21
1 files changed, 21 insertions, 0 deletions
diff --git a/support/latexindent/LatexIndent/GetYamlSettings.pm b/support/latexindent/LatexIndent/GetYamlSettings.pm
index f28fdd6525..1529493d4f 100644
--- a/support/latexindent/LatexIndent/GetYamlSettings.pm
+++ b/support/latexindent/LatexIndent/GetYamlSettings.pm
@@ -570,6 +570,27 @@ sub yaml_read_settings{
$logger->info(Dumper(\%masterSettings));
}
+ if( $is_m_switch_active
+ and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks}
+ and !${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis} ){
+
+ # the following settings don't make sense, so we change
+ #
+ # modifyLineBreaks:
+ # textWrapOptions:
+ # perCodeBlockBasis: 0
+ # beforeFindingChildCodeBlocks: 1
+ # into
+ #
+ # modifyLineBreaks:
+ # textWrapOptions:
+ # perCodeBlockBasis: 0
+ # beforeFindingChildCodeBlocks: 0
+ $logger->warn("*textWrapOptions:beforeFindingChildCodeBlocks:1 with textWrapOptions:perCodeBlockBasis:0");
+ $logger->warn("turning off beforeFindingChildCodeBlocks by changing textWrapOptions:beforeFindingOtherCodeBlocks to be 0");
+ $logger->warn("you need to set *both* values to be 1 to use the beforeFindingChildCodeBlocks feature");
+ ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks} = 0;
+ }
return;
}