Unicode in overlays is broken


Some characters work (like \u2581), but many are wrong (like \u2611 or \u2713). These characters work fine in print statements but not overlays. I would have just thought they weren’t supported but they do show actual characters, just the wrong character.

var black = { red: 0, green:0, blue:0};
var white = { red: 255, green:255, blue:255};
var elements = [];
var element = [];
var text = "\u2713";

element = Overlays.addOverlay("text", {
    bounds: { x: 100, y: 100, width: 100, height: 100},
    backgroundColor: black,
    backgroundAlpha: 1.0,
    font: {size: 16},
    color: white,
    text: text,//+" "+menuOptions[i],//text: "\u2610",
    alpha: 1.0

function cleanup()
	for(var i = 0; i < elements.length; i++)

Script.scriptEnding.connect(function() {cleanup()});


It might be a font issue across platforms – here’s a screenshot from my Linux machine (using your script adapted to loop on that unicode ballpark range of code points):

FWIW SVG images and WebWindow / WebEntities seem much better at rendering arbitrary Unicode characters. Assuming that you’re thinking about those checkbox characters for menu options – have you experimented yet with using Overlays.addOverlay(“web3d”, { isFacingAvatar: true, … }) as a popup?


Oh crap :confused:

Good idea, thanks.