From 4f23949735c3e0ad7617605d039a466297398a76 Mon Sep 17 00:00:00 2001
From: Robert Alessi
Date: Sat, 18 Apr 2020 11:05:51 +0200
Subject: removed tei_p_open boolean
---
ekdosis.dtx | 19 -------------------
1 file changed, 19 deletions(-)
diff --git a/ekdosis.dtx b/ekdosis.dtx
index fa7c9d5..c244e32 100644
--- a/ekdosis.dtx
+++ b/ekdosis.dtx
@@ -1196,9 +1196,6 @@ local endpoem = lpeg.Cs(lnbrk * lpeg.S("*!") * bsqbrackets^-1)
-- Bind to local variables
local next = next
--- Booleans
-local tei_p_open = false
-
-- General
xmlids = {}
@@ -1629,8 +1626,6 @@ local function envtotei(str)
do
if envtotags[i].b ~= ""
then
- -- -- if tei_p_open and envtotags[i].b == "p" or envtotags[i].b == "lg"
- -- if tei_p_open and isfound(close_p, envtotags[i].b)
if isfound(close_p, envtotags[i].b)
then
str = gsub(str, lpeg.P("\\par") * spcenc^-1 * lpeg.P("\\begin") * spcenc^-1 * lpeg.P("{")
@@ -1766,13 +1761,6 @@ end
local function textotei(str)
str = xml_entities(str)
str = texpatttotei(str)
- -- if tei_p_open
- -- then
- -- str = string.gsub(str, "%s?\\par%s?", "
\n")
- -- else
- -- str = string.gsub(str, "%s?\\par%s?", "\n
")
- -- tei_p_open = true
- -- end
str = note_totei(str)
str = app_totei(str)
str = lem_rdg_totei(str)
@@ -1923,15 +1911,8 @@ end
function ekdosis.exporttei(str)
local f = io.open(teifilename.."_tmp.xml", "a+")
-- f:write("\n
")
- -- tei_p_open = true
str = textotei(str)
f:write(str)
- -- if tei_p_open
- -- then
- -- f:write("
")
- -- tei_p_open = false
- -- else
- -- end
f:close()
return true
end
--
cgit v1.2.3