[Core] Fixed Text Measurement bug;
[Core] Fixed crash on dispose of Lua Scripts;
Fixes #38;