more btex styling

This commit is contained in:
minjaesong
2024-04-28 15:32:28 +09:00
parent 8a1ff32fa7
commit 54663657bd
2 changed files with 13 additions and 4 deletions

View File

@@ -14,7 +14,7 @@
</p><p>“테이프가 끊어지면 피가 나오. 생채기도 머지않아 완치될 줄 믿소. 굿바이.” 감정은 어떤 ‘포즈’. (그 ‘포즈’의 원소만을 지적하는 것이 아닌지 나도 모르겠소.) 그 포우즈가 부동자세에까지 고도화할 때 감정은 딱 공급을 정지합네다.
</p><p>나는 내 비범한 발육을 회고하여 세상을 보는 안목을 규정하였소.
</p><p>여왕봉과 미망인—세상의 하고 많은 여인이 본질적으로 이미 미망인이 아닌 이가 있으리까? 아니, 여인의 전부가 그 일상에 있어서 개개 ‘미망인’이라는 내 논리가 뜻밖에도 여성에 대한 모독이 되오? 굿바이.
</p><p><br />
</p><p><anonbreak />
</p><p>그 33번지라는 것이 구조가 흡사 유곽이라는 느낌이 없지 않다.
</p><p>한 번지에 18가구가 죽 어깨를 맞대고 늘어서서 창호가 똑같고 아궁이 모양이 똑같다. 게다가 각 가구에 사는 사람들이 송이송이 꽃과 같이 젊다.
</p><p>해가 들지 않는다. 해가 드는 것을 그들이 모른 체하는 까닭이다. 턱살밑에다 철줄을 매고 얼룩 진 이부자리를 널어 말린다는 핑계로 미닫이에 해가 드는 것을 막아 버린다. 침침한 방안에서 낮잠들을 잔다. 그들은 밤에는 잠을 자지 않나? 알 수 없다. 나는 밤이나 낮이나 잠만 자느라고 그런 것을 알 길이 없다. 33번지 18가구의 낮은 참 조용하다.

View File

@@ -710,6 +710,15 @@ object BTeXParser {
handler.paragraphBuffer.clear()
}
@CloseTag
fun closeElemANONBREAK(handler: BTeXHandler, doc: BTeXDocument, uri: String, siblingIndex: Int) {
typesetParagraphs("――――――――――――", handler).also {it.first().let {
it.posX += (doc.textWidth - it.width) / 2
} }
doc.linesPrintedOnPage[doc.currentPage] = (doc.linesPrintedOnPage[doc.currentPage] - 1).coerceAtLeast(0)
handler.paragraphBuffer.clear()
}
@CloseTag
fun closeElemCOVER(handler: BTeXHandler, doc: BTeXDocument, uri: String, siblingIndex: Int) {
handler.spanColour = null
@@ -794,12 +803,12 @@ object BTeXParser {
@CloseTag // reflective access is impossible with 'private'
fun closeElemP(handler: BTeXHandler, doc: BTeXDocument, uri: String, siblingIndex: Int) {
// if this P is a very first P without chapters, leave two lines before typesetting
val addVirtualChapter = (tagHistory.size > 2 && tagHistory[tagHistory.lastIndex - 1] == "MANUSCRIPT")
val penultTag = tagHistory.getOrNull(tagHistory.lastIndex - 1)
val thePar = handler.paragraphBuffer.toString().trim()
val text =
if (siblingIndex > 1) "\u3000$thePar"
else if (addVirtualChapter) "\n\n$thePar"
if (siblingIndex > 1 && penultTag != "ANONBREAK" && penultTag != "BR") "\u3000$thePar"
else if (penultTag == "MANUSCRIPT") "\n\n$thePar"
else thePar
typesetParagraphs(text, handler)