From f9748996922ec12cb0b40eaee6eaae0112f7e3c1 Mon Sep 17 00:00:00 2001 From: Jerome St-Louis Date: Tue, 27 Aug 2013 19:32:57 -0400 Subject: [PATCH] ecere/gui/EditBox: Fixed broken highlighting of hexadecimal numbers --- ecere/src/gui/controls/EditBox.ec | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ecere/src/gui/controls/EditBox.ec b/ecere/src/gui/controls/EditBox.ec index dc6546b..e10e6bb 100644 --- a/ecere/src/gui/controls/EditBox.ec +++ b/ecere/src/gui/controls/EditBox.ec @@ -1724,11 +1724,11 @@ private: { char * dot = strchr(word, '.'); char * s = null; - if(dot && dot == word + wordLen) - strtod(dot+1, &s); + if(dot) + strtod((dot == word + wordLen) ? (dot+1) : word, &s); else - strtod(word, &s); - if(s) + strtol(word, &s, 0); + if(s && s != word) { if((dot && *s == 'f' && !isalnum(s[1]) && s[1] != '_') || (!isalpha(*s) && *s != '_')) { -- 1.8.3.1