diff options
author | Thomas White <taw@physics.org> | 2010-04-26 17:24:34 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2010-04-26 17:24:34 +0200 |
commit | 409fd287a1c29a661b138a90b8b4334d502a1847 (patch) | |
tree | 3db8ab9bda6a7d8fac40daf7575f628c1b66f927 /src | |
parent | f178cdfec0bbdaf3b6d9ed09daacff87984561ee (diff) |
hdfsee: Indicate when numbers are too big to represent
Diffstat (limited to 'src')
-rw-r--r-- | src/displaywindow.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/displaywindow.c b/src/displaywindow.c index 82acb58d..a5141dab 100644 --- a/src/displaywindow.c +++ b/src/displaywindow.c @@ -643,7 +643,11 @@ static void numbers_update(DisplayWindow *dw) } if ( (x>0) && (y>0) && valid ) { - snprintf(s, 31, "%.0f", val); + if ( log(val)/log(10) < 5 ) { + snprintf(s, 31, "%.0f", val); + } else { + snprintf(s, 31, "HUGE"); + } } else { strcpy(s, "--"); } |