Updated examples

This commit is contained in:
hydrabolt
2015-10-28 12:28:38 +00:00
parent c3b6dba6be
commit 211a0de564
5 changed files with 73 additions and 55 deletions

View File

@@ -57,6 +57,12 @@ exports.toDec = function (data) {
exports.toHex = function (data) {
return "#" + data.toString(16);
var text = data.toString(16);
while(text.length < 6){
text = "0" + text;
}
return "#" + text;
}