From f113f8fae8a258c5fa76f7d025bdb0c30d758fd8 Mon Sep 17 00:00:00 2001 From: Cerapter Date: Thu, 26 Jul 2018 14:46:02 +0200 Subject: Added a bunch of features. - The IC chatlog now goes from top to bottom. - The same chatlog can be set to a limit by putting 'log_maximum = 100', for example, into the config.ini file. - Reloading the theme checks for the log limit again. - If a message starts with '~~' (two tildes), it'll be centered (for testimony title usage). - Inline colour options: - Text between {curly braces} will appear orange. - Text between (parentheses) will appear blue. - Text between $dollar signs$ will appear green. - The symbols can still be got by putting a '\' in front of them. - I.e.: \{, \}, \(, \), \$, \\ --- courtroom.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'courtroom.h') diff --git a/courtroom.h b/courtroom.h index 85554a0e..a4e08df6 100644 --- a/courtroom.h +++ b/courtroom.h @@ -32,6 +32,8 @@ #include #include +#include + class AOApplication; class Courtroom : public QMainWindow @@ -147,6 +149,26 @@ private: int m_viewport_width = 256; int m_viewport_height = 192; + bool first_message_sent = false; + int maximumMessages = 0; + + // This is for inline message-colouring. + enum INLINE_COLOURS { + INLINE_BLUE, + INLINE_GREEN, + INLINE_ORANGE + }; + + // A stack of inline colours. + std::stack inline_colour_stack; + + bool centre_text = false; + + bool next_character_is_not_special = false; // If true, write the + // next character as it is. + + bool message_is_centered = false; + QVector char_list; QVector evidence_list; QVector music_list; -- cgit