aboutsummaryrefslogtreecommitdiff
path: root/engines/supernova/supernova.h
diff options
context:
space:
mode:
authorThierry Crozat2017-09-30 23:27:56 +0100
committerThierry Crozat2018-01-23 02:15:33 +0000
commit6fc065922268c6dfb83fac6ded31dca076822754 (patch)
treec629fbcc015d8dbe7d836b6a2240813d782b5db6 /engines/supernova/supernova.h
parent184b3a166217ba5c0ea3eddd3e01798d8e752417 (diff)
downloadscummvm-rg350-6fc065922268c6dfb83fac6ded31dca076822754.tar.gz
scummvm-rg350-6fc065922268c6dfb83fac6ded31dca076822754.tar.bz2
scummvm-rg350-6fc065922268c6dfb83fac6ded31dca076822754.zip
SUPERNOVA: Start using strings from the engine data file
This means that now all that remains to be done to play in English is to move all the strings to the engine data file and to translate them.
Diffstat (limited to 'engines/supernova/supernova.h')
-rw-r--r--engines/supernova/supernova.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/engines/supernova/supernova.h b/engines/supernova/supernova.h
index 356cfe482c..cc6cfbb479 100644
--- a/engines/supernova/supernova.h
+++ b/engines/supernova/supernova.h
@@ -154,6 +154,26 @@ public:
return _nullString;
return _gameStrings[idx];
}
+ int textWidth(const Common::String &text) {
+ if (text.empty())
+ return 0;
+ return textWidth(text.c_str());
+ }
+ void renderMessage(StringID stringId, MessagePosition position = kMessageNormal) {
+ renderMessage(getGameString(stringId), position);
+ }
+ void renderMessage(const Common::String &text, MessagePosition position = kMessageNormal) {
+ if (!text.empty())
+ renderMessage(text.c_str(), position);
+ }
+ void renderText(const Common::String &text, int x, int y, byte color) {
+ if (!text.empty())
+ renderText(text.c_str(), x, y, color);
+ }
+ void renderText(const Common::String &text) {
+ if (!text.empty())
+ renderText(text.c_str());
+ }
Common::MemoryReadStream *convertToMod(const char *filename, int version = 1);