ブラウザがクラッシュする現象を再現 のUnicodeを確認したかった

by TmskSt forked from ブラウザがクラッシュする現象を再現 (diff: 43)
♥0 | Line 27 | Modified 2009-09-29 01:39:58 | MIT License
play

ActionScript3 source code

/**
 * Copyright TmskSt ( http://wonderfl.net/user/TmskSt )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/Tn4R
 */

// forked from break's ブラウザがクラッシュする現象を再現
package {
	import flash.display.Sprite;
	import flash.text.TextField;
	public class FlashTest extends Sprite {
		private var tf:TextField;
		public function FlashTest() {
			//Unicodeについては - http://ja.wikipedia.org/wiki/Unicode一覧_0000-0FFF
			//文字列 "!" は、Unicode:0x0021 なので charCodeAt の実行結果は 33 です
			// 0x0600 - 0x2000 あたりでクラッシュすると疑ってます(未検証)
			
			//0-160
			//11904-12245
			//12288-12543
			var tf:TextField = stage.addChild(new TextField()) as TextField;
			tf.appendText(String(new String("!").charCodeAt()));
			tf.appendText(String(", " + new String("ೋ").charCodeAt()));
			tf.appendText(String(", " + new String("☠").charCodeAt()));
			tf.appendText(String(", " + new String("ആ").charCodeAt()));
			tf.appendText(String(", " + new String("௵").charCodeAt()));
			tf.appendText(String(", " + new String("ஔ").charCodeAt()));
			tf.appendText(String(", " + new String("ܓ").charCodeAt()));
			tf.appendText(String(", " + new String("࿇").charCodeAt()));
			tf.appendText(String(", " + new String("༒").charCodeAt()));
			tf.width = 300;
			tf.x = stage.stageWidth * 0.5 - tf.width * 0.5;
			tf.y = stage.stageHeight * 0.5 - tf.height * 0.5;
			tf.background = true;
			tf.backgroundColor = 0xFFFFFF;
			tf.border = true;
			tf.wordWrap = true;
			tf.borderColor = 0xAAAAAA;
		}
	}
}

Forked