diff options
author | ניב באר | 2018-09-03 22:29:19 +0300 |
---|---|---|
committer | Eugene Sandulenko | 2020-01-01 00:31:21 +0100 |
commit | 72471ec431c76f6aee63ef67cf4fd475f942ac47 (patch) | |
tree | 3b7a078b2f7da96bc9af7c797a06dccef0e79fcc /engines/scumm/smush/smush_font.cpp | |
parent | c05b911563a8016c4e978dabd4715403febe3648 (diff) | |
download | scummvm-rg350-72471ec431c76f6aee63ef67cf4fd475f942ac47.tar.gz scummvm-rg350-72471ec431c76f6aee63ef67cf4fd475f942ac47.tar.bz2 scummvm-rg350-72471ec431c76f6aee63ef67cf4fd475f942ac47.zip |
SCUMM: rtl support for scumm-7-8
Diffstat (limited to 'engines/scumm/smush/smush_font.cpp')
-rw-r--r-- | engines/scumm/smush/smush_font.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/engines/scumm/smush/smush_font.cpp b/engines/scumm/smush/smush_font.cpp index 01ac202d37..bad1b02d37 100644 --- a/engines/scumm/smush/smush_font.cpp +++ b/engines/scumm/smush/smush_font.cpp @@ -191,8 +191,11 @@ void SmushFont::drawSubstring(const char *str, byte *buffer, int dst_width, int // to have to check for it. if (x < 0) x = 0; + + //for (int i = 0; str[i] != 0; i++) { - for (int i = 0; str[i] != 0; i++) { + int len = strlen(str); + for (int i = len; i >= 0; i--) { if ((byte)str[i] >= 0x80 && _vm->_useCJKMode) { x += draw2byte(buffer, dst_width, x, y, (byte)str[i] + 256 * (byte)str[i+1]); i++; @@ -207,6 +210,12 @@ void SmushFont::drawSubstring(const char *str, byte *buffer, int dst_width, int void SmushFont::drawString(const char *str, byte *buffer, int dst_width, int dst_height, int x, int y, bool center) { debugC(DEBUG_SMUSH, "SmushFont::drawString(%s, %d, %d, %d)", str, x, y, center); + + //char rev[384] = {0}; + //int len = strlen(str); + //for (int l = 0; l < len; l++) { + // rev[l] = str[len - l - 1]; + //} while (str) { char line[256]; const char *pos = strchr(str, '\n'); |