- currenyPrecision
- currencySign
- currencyAtEnd
-This class also uses the default date format defined here: {@link Ext.date#defaultFormat}.
+This class also uses the default date format defined here: {@link Ext.Date#defaultFormat}.
__Using with renderers__
There are two helper functions that return a new function that can be used in conjunction with
* @param {String} format The way you would like to format this text.
* @return {String} The formatted number.
*/
- number:
- function(v, formatString) {
+ number: function(v, formatString) {
if (!formatString) {
return v;
}
fnum = psplit[0] + dec + psplit[1];
}
}
+
+ if (neg) {
+ /*
+ * Edge case. If we have a very small negative number it will get rounded to 0,
+ * however the initial check at the top will still report as negative. Replace
+ * everything but 1-9 and check if the string is empty to determine a 0 value.
+ */
+ neg = fnum.replace(/[^1-9]/g, '') !== '';
+ }
return (neg ? '-' : '') + formatString.replace(/[\d,?\.?]+/, fnum);
},
<span id='Ext-util-Format-method-htmlDecode'> /**
</span> * Convert certain characters (&, <, >, and ') from their HTML character equivalents.
- * See {@link Ext.string#htmlDecode}.
+ * See {@link Ext.String#htmlDecode}.
* @method
*/
htmlDecode: Ext.String.htmlDecode,