Firefox Ubiquity – Character Count Command

Now that Ubiquity 0.5 is out, Erik’s Character Count Command no longer works. So I have updated it and if you have Ubiquity Firefox, the command bar should have appeared on top for you. Here is the code:

CmdUtils.CreateCommand({
names: ['char-count'],
arguments: [ {role: 'object', nountype: noun_arb_text, label: 'text to count chars in'}],
preview: function( pblock, args ) {
//pblock.innerHTML = argText.object.length;
pblock.innerHTML = "The number of characters is: "+ args.object.text.length;
}
});

Hope you found it useful!

Like this post? +1 it!  

Related Posts:

7 comments to Firefox Ubiquity – Character Count Command

Leave a Reply