diff options
author | Matthew Stewart | 2018-07-23 22:06:24 -0400 |
---|---|---|
committer | Eugene Sandulenko | 2018-08-09 08:37:30 +0200 |
commit | 0e85e19ee7530b4d41668982e0b10f04d6f29741 (patch) | |
tree | 4ef9ad91daeffd899e3e4f4ecf27be32f53aaa67 /engines/startrek/text.cpp | |
parent | c2dd39a6c2f1f9356110dcfe0cb36607373b19e3 (diff) | |
download | scummvm-rg350-0e85e19ee7530b4d41668982e0b10f04d6f29741.tar.gz scummvm-rg350-0e85e19ee7530b4d41668982e0b10f04d6f29741.tar.bz2 scummvm-rg350-0e85e19ee7530b4d41668982e0b10f04d6f29741.zip |
STARTREK: Move function descriptions to headers
Diffstat (limited to 'engines/startrek/text.cpp')
-rw-r--r-- | engines/startrek/text.cpp | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/engines/startrek/text.cpp b/engines/startrek/text.cpp index 87ecdb2cd8..0d6d469e2d 100644 --- a/engines/startrek/text.cpp +++ b/engines/startrek/text.cpp @@ -30,10 +30,6 @@ namespace StarTrek { -/** - * Gets one line of text (does not include words that won't fit). - * Returns position of text to continue from, or nullptr if done. - */ const char *StarTrekEngine::getNextTextLine(const char *text, char *lineOutput, int lineWidth) { *lineOutput = '\0'; if (*text == '\0') @@ -106,11 +102,6 @@ void StarTrekEngine::getTextboxHeader(String *headerTextOutput, String speakerTe *headerTextOutput = centerTextboxHeader(header); } -/** - * Text getter for showText which reads from an rdf file. - * Not really used, since it would require hardcoding text locations in RDF files. - * "readTextFromArrayWithChoices" replaces this. - */ String StarTrekEngine::readTextFromRdf(int choiceIndex, uintptr data, String *headerTextOutput) { SharedPtr<Room> room = getRoom(); @@ -137,9 +128,6 @@ String StarTrekEngine::readTextFromRdf(int choiceIndex, uintptr data, String *he return (char*)&room->_rdfData[textOffset]; } -/** - * Shows text with the given header and main text. - */ void StarTrekEngine::showTextbox(String headerText, const String &mainText, int xoffset, int yoffset, byte textColor, int maxTextLines) { if (!headerText.empty()) headerText = centerTextboxHeader(headerText); @@ -180,10 +168,6 @@ String StarTrekEngine::skipTextAudioPrompt(const String &str) { return String(text+1); } -/** - * Plays an audio prompt, if it exists, and returns the string starting at the end of the - * prompt. - */ String StarTrekEngine::playTextAudio(const String &str) { const char *text = str.c_str(); char soundFile[0x100]; @@ -205,10 +189,6 @@ String StarTrekEngine::playTextAudio(const String &str) { return String(text+1); } -/** - * @param rclickCancelsChoice If true, right-clicks return "-1" as choice instead of - * whatever was selected. - */ int StarTrekEngine::showText(TextGetterFunc textGetter, uintptr var, int xoffset, int yoffset, int textColor, bool loopChoices, int maxTextLines, bool rclickCancelsChoice) { int16 tmpTextDisplayMode = _textDisplayMode; @@ -437,9 +417,6 @@ reloadText: return choiceIndex; } -/** - * Returns the number of lines this string will take up in a textbox. - */ int StarTrekEngine::getNumTextboxLines(const String &str) { const char *text = str.c_str(); char line[TEXTBOX_WIDTH]; @@ -475,9 +452,6 @@ String StarTrekEngine::putTextIntoLines(const String &_text) { return output; } -/** - * Creates a blank textbox in a TextBitmap, and initializes a sprite to use it. - */ SharedPtr<TextBitmap> StarTrekEngine::initTextSprite(int *xoffsetPtr, int *yoffsetPtr, byte textColor, int numTextLines, bool withHeader, Sprite *sprite) { int linesBeforeTextStart = 2; if (withHeader) @@ -552,10 +526,6 @@ SharedPtr<TextBitmap> StarTrekEngine::initTextSprite(int *xoffsetPtr, int *yoffs return bitmap; } -/** - * Draws the "main" text (everything but the header which includes the speaker) to - * a TextBitmap. - */ void StarTrekEngine::drawMainText(SharedPtr<TextBitmap> bitmap, int numTextLines, int numTextboxLines, const String &_text, bool withHeader) { byte *dest = bitmap->pixels + TEXTBOX_WIDTH + 1; // Start of 2nd row const char *text = _text.c_str(); @@ -631,10 +601,6 @@ String StarTrekEngine::readLineFormattedText(TextGetterFunc textGetter, uintptr */ } -/** - * Text getter for showText which reads choices from an array of pointers. - * Last element in the array must be an empty string. - */ String StarTrekEngine::readTextFromArray(int choiceIndex, uintptr data, String *headerTextOutput) { const char **textArray = (const char **)data; @@ -651,10 +617,6 @@ String StarTrekEngine::readTextFromArray(int choiceIndex, uintptr data, String * return String(mainText); } -/** - * Similar to above, but shows the choice index when multiple choices are present. - * Effectively replaces the "readTextFromRdf" function. - */ String StarTrekEngine::readTextFromArrayWithChoices(int choiceIndex, uintptr data, String *headerTextOutput) { const char **textArray = (const char **)data; |