diff --git a/libs/events.js b/libs/events.js index 33315916..4d786341 100644 --- a/libs/events.js +++ b/libs/events.js @@ -1138,7 +1138,7 @@ events.prototype._action_showTextImage = function (data, x, y, prefix) { var loc = this.__action_getLoc(data.loc, 0, 0, prefix); if (core.isReplaying()) data.time = 0; this.__action_doAsyncFunc(data.async || data.time == 0, core.showImage, - data.code, core.ui.textImage(data.text), loc[0], loc[1], 100, 100, data.opacity, data.time); + data.code, core.ui.textImage(data.text), null, loc, data.opacity, data.time); } events.prototype._action_hideImage = function (data, x, y, prefix) { diff --git a/libs/ui.js b/libs/ui.js index 46738a4f..cee68bb8 100644 --- a/libs/ui.js +++ b/libs/ui.js @@ -353,7 +353,7 @@ ui.prototype.calWidth = function (name, text, font) { ////// 字符串自动换行的分割 ////// ui.prototype.splitLines = function (name, text, maxWidth, font) { var ctx = this.getContextByName(name); - if (!ctx) return; + if (!ctx) return [text]; if (font) core.setFont(name, font); var contents = [];