From 25fc8b5480f809216e964190b300af6480d813f3 Mon Sep 17 00:00:00 2001 From: s5260822 Date: Sat, 22 Mar 2025 22:01:47 +0100 Subject: [PATCH] fixed section in toc --- .../domainimpl/mdb/Speech_MongoDB_Impl.java | 24 ++++++++++--------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/src/main/java/org/texttechnologylab/project/gruppe_05_1/database/domainimpl/mdb/Speech_MongoDB_Impl.java b/src/main/java/org/texttechnologylab/project/gruppe_05_1/database/domainimpl/mdb/Speech_MongoDB_Impl.java index 544fd6f..f77d55c 100644 --- a/src/main/java/org/texttechnologylab/project/gruppe_05_1/database/domainimpl/mdb/Speech_MongoDB_Impl.java +++ b/src/main/java/org/texttechnologylab/project/gruppe_05_1/database/domainimpl/mdb/Speech_MongoDB_Impl.java @@ -84,17 +84,19 @@ public class Speech_MongoDB_Impl extends Speech_File_Impl implements Speech { public String toTeX() { StringBuilder tex = new StringBuilder(); - tex.append("\\section*{Rede ") - .append(this.getSpeechKey()) - .append("/") - .append(getAgendaTitle(this.getSessionId(), this.getAgendaItemId())) - .append(" von ") - .append(this.getSpeakerName()) - .append(" (") - .append(this.getFraction()) - .append(") vom ") - .append(getSessionDateTime(this.getSessionId())) - .append("}\n"); + String speechTitle = "Rede " + + this.getSpeechKey() + + "/" + + getAgendaTitle(this.getSessionId(), this.getAgendaItemId()) + + " von " + + this.getSpeakerName() + + " (" + + this.getFraction() + + ") vom " + + getSessionDateTime(this.getSessionId()); + + tex.append("\\section*{").append(speechTitle).append("}\n"); + tex.append("\\addcontentsline{toc}{section}{").append(speechTitle).append("}\n"); tex.append("$$SPEAKERINFO$$\n");