diff options
author | Peter Kohaut | 2019-07-14 20:41:36 +0200 |
---|---|---|
committer | Peter Kohaut | 2019-07-16 21:32:34 +0200 |
commit | a767a6800d2f76b90b66d7c0dcb96c0514350721 (patch) | |
tree | f94e9432beb63c2c902c64d8ea18fe62db93dc00 /engines/bladerunner/subtitles.h | |
parent | ffbfe90afad5c1b6a24705e94235172d2d38b032 (diff) | |
download | scummvm-rg350-a767a6800d2f76b90b66d7c0dcb96c0514350721.tar.gz scummvm-rg350-a767a6800d2f76b90b66d7c0dcb96c0514350721.tar.bz2 scummvm-rg350-a767a6800d2f76b90b66d7c0dcb96c0514350721.zip |
BLADERUNNER: Added TTF & UTF8 support for subtitles
Diffstat (limited to 'engines/bladerunner/subtitles.h')
-rw-r--r-- | engines/bladerunner/subtitles.h | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/engines/bladerunner/subtitles.h b/engines/bladerunner/subtitles.h index 674dde44b1..eb45a35a3f 100644 --- a/engines/bladerunner/subtitles.h +++ b/engines/bladerunner/subtitles.h @@ -26,17 +26,15 @@ #include "bladerunner/bladerunner.h" #include "common/str.h" -#include "graphics/surface.h" - -#include "common/file.h" -#include "common/substream.h" +namespace Graphics { +class Font; +} namespace BladeRunner { class BladeRunnerEngine; class TextResource; -class Font; class Subtitles { friend class Debugger; @@ -54,16 +52,25 @@ class Subtitles { BladeRunnerEngine *_vm; + enum SubtitlesFontType { + kSubtitlesFontTypeInternal, + kSubtitlesFontTypeTTF + }; + struct SubtitlesInfo { - Common::String versionStr; - Common::String dateOfCompile; - Common::String languageMode; - Common::String credits; + Common::String versionStr; + Common::String dateOfCompile; + Common::String languageMode; + Common::String credits; + SubtitlesFontType fontType; + Common::String fontName; }; SubtitlesInfo _subtitlesInfo; - TextResource *_vqaSubsTextResourceEntries[kMaxTextResourceEntries]; - Font *_subsFont; + TextResource *_vqaSubsTextResourceEntries[kMaxTextResourceEntries]; + + Graphics::Font *_font; + bool _useUTF8; bool _isVisible; bool _forceShowWhenNoSpeech; @@ -76,7 +83,6 @@ class Subtitles { bool _subtitlesQuoteChanged; bool _gameSubsResourceEntriesFound[kMaxTextResourceEntries]; // false if a TRE file did not open successfully - bool _subsFontsLoaded; // false if external fonts did not load bool _subtitlesSystemActive; // true if the whole subtitles subsystem should be disabled (due to missing required resources) public: @@ -84,7 +90,6 @@ public: ~Subtitles(); bool isSystemActive() const { return _subtitlesSystemActive; } - bool isSubsFontsLoaded() const { return _subsFontsLoaded; } void init(); SubtitlesInfo getSubtitlesInfo() const; |