After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 168467 - Need to make "1E+10" same width as "1E-10"
Need to make "1E+10" same width as "1E-10"
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: GUI
git master
Other All
: Normal enhancement
: ---
Assigned To: Jody Goldberg
Jody Goldberg
Depends on:
Blocks:
 
 
Reported: 2005-02-25 00:39 UTC by Morten Welinder
Modified: 2005-02-28 15:24 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Morten Welinder 2005-02-25 00:39:28 UTC
Bitstream vera sans' digits do not have the same width.  That makes columns
not look at good as they should.
Comment 1 Morten Welinder 2005-02-25 00:46:33 UTC
We ought to be able to piggyback off DejaVu:

http://dejavu.sourceforge.net/wiki/index.php/Main_Page
Comment 2 Morten Welinder 2005-02-25 15:42:17 UTC
Ok, forget the font issue.  Somehow my font setup was screwed.

We're left with "1E+10" vs "1E-10" where the "+" is far wider than U002D.
"+" has the same with as U2212.
Comment 3 Andreas J. Guelzow 2005-02-26 07:15:08 UTC
U2212 is the math symbol "minus sign" while U002D is the punctuation
"hyphen-minus". Hyphens are typically short while minus signs ought to be the
same size as plus signs. I guess we `just' have to use U2212.
Comment 4 Morten Welinder 2005-02-26 17:05:06 UTC
a1=-42
a2=code(left(a1,1))

That should yield 45 in a2, so any trick we do is going to be for the
displayed string only.

We probably do not want to map "-" to U2212 for strings, e.g., "almost-crazy
example", but only for numbers.  That would make the string "1E-20" look
different from the number 1E-20.

Feature?
Comment 5 Andreas J. Guelzow 2005-02-27 01:39:54 UTC
That would make the string "1E-20" look different from the number 1E-20.

with string "1E-20" do you mean a string whose third character is U2212 or U002D
or U2010. THey will all look different. 

Anybody using TeX will be used to having minus, hyphen,  n- and m-dashes all
look different (as they should).

Since
a1=-42              
a2=code(mid(a1,3,1))
gives 50 whether or not a1 is formatted as number or scientific, we obviously
ignore formatting when we work with the number.
Comment 6 Morten Welinder 2005-02-27 01:47:53 UTC
a1: '1E-20             String with U002D
a2: = a1+0             Number, shown with U2212
a3: =left(a2,5)        String again, U002D again.

A man could get confused.  It will appear as-if numbers are shown with a
slightly different font.
Comment 7 Andreas J. Guelzow 2005-02-27 16:38:26 UTC
Perhaps I don't understand the problem since as a LaTeX user  -23   and $-23$
does end up looking quite different.

And personally I would find it good having a better visual distinction between
strings and numbers.
Comment 8 Morten Welinder 2005-02-28 15:24:40 UTC
Fixed in cvs.  Please pound on it and see if anything breaks over it.