提交 55d724ea 编写于 作者: A Alex Dima

Better handling of characters outside the basic ASCII range

上级 da8e81f1
......@@ -161,10 +161,11 @@ export class MinimapCharRenderer {
}
private static _getChIndex(chCode: number): number {
if (chCode < Constants.START_CH_CODE || chCode > Constants.END_CH_CODE) {
chCode = CharCode.N;
chCode -= Constants.START_CH_CODE;
if (chCode < 0) {
chCode += Constants.CHAR_COUNT;
}
return chCode - Constants.START_CH_CODE;
return (chCode % Constants.CHAR_COUNT);
}
public x2RenderChar(target: ImageData, dx: number, dy: number, chCode: number, color: ParsedColor, backgroundColor: ParsedColor): void {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册