comparison lisp/calc/calc-units.el @ 111633:4e76c4e4f20f

calc.texi (TeX and LaTeX Language Modes, Predefined Units): calc-units.el (math-build-units-table-buffer): README: Mention that the TeX specific units won't use the `tex' prefix in TeX mode. calc-lang.el (math-variable-table): Don't use the `tex' prefix for units in TeX mode.
author Jay Belanger <jay.p.belanger@gmail.com>
date Thu, 18 Nov 2010 19:14:36 -0600
parents d150a25a0eb9
children 417b1e4d63cd
comparison
equal deleted inserted replaced
111632:e06fc3baed8c 111633:4e76c4e4f20f
55 ( mi "5280 ft" "Mile" ) 55 ( mi "5280 ft" "Mile" )
56 ( au "149597870691. m" "Astronomical Unit" nil 56 ( au "149597870691. m" "Astronomical Unit" nil
57 "149597870691 m (*)") 57 "149597870691 m (*)")
58 ;; (approx) NASA JPL (http://neo.jpl.nasa.gov/glossary/au.html) 58 ;; (approx) NASA JPL (http://neo.jpl.nasa.gov/glossary/au.html)
59 ( lyr "c yr" "Light Year" ) 59 ( lyr "c yr" "Light Year" )
60 ( pc "3.0856775854*10^16 m" "Parsec" nil 60 ( pc "3.0856775854*10^16 m" "Parsec (**)" nil
61 "3.0856775854 10^16 m (*)") ;; (approx) ESUWM 61 "3.0856775854 10^16 m (*)") ;; (approx) ESUWM
62 ( nmi "1852 m" "Nautical Mile" ) 62 ( nmi "1852 m" "Nautical Mile" )
63 ( fath "6 ft" "Fathom" ) 63 ( fath "6 ft" "Fathom" )
64 ( fur "660 ft" "Furlong") 64 ( fur "660 ft" "Furlong")
65 ( mu "1 um" "Micron" ) 65 ( mu "1 um" "Micron" )
66 ( mil "(1/1000) in" "Mil" ) 66 ( mil "(1/1000) in" "Mil" )
67 ( point "(1/72) in" "Point (1/72 inch)" ) 67 ( point "(1/72) in" "Point (PostScript convention)" )
68 ( Ang "10^(-10) m" "Angstrom" ) 68 ( Ang "10^(-10) m" "Angstrom" )
69 ( mfi "mi+ft+in" "Miles + feet + inches" ) 69 ( mfi "mi+ft+in" "Miles + feet + inches" )
70 ;; TeX lengths 70 ;; TeX lengths
71 ( texpt "(100/7227) in" "Point (TeX conventions)" ) 71 ( texpt "(100/7227) in" "Point (TeX convention) (**)" )
72 ( texpc "12 texpt" "Pica" ) 72 ( texpc "12 texpt" "Pica (TeX convention) (**)" )
73 ( texbp "point" "Big point (TeX conventions)" ) 73 ( texbp "point" "Big point (TeX convention) (**)" )
74 ( texdd "(1238/1157) texpt" "Didot point" ) 74 ( texdd "(1238/1157) texpt" "Didot point (TeX convention) (**)" )
75 ( texcc "12 texdd" "Cicero" ) 75 ( texcc "12 texdd" "Cicero (TeX convention) (**)" )
76 ( texsp "(1/65536) texpt" "Scaled TeX point" ) 76 ( texsp "(1/65536) texpt" "Scaled TeX point (TeX convention) (**)" )
77 77
78 ;; Area 78 ;; Area
79 ( hect "10000 m^2" "*Hectare" ) 79 ( hect "10000 m^2" "*Hectare" )
80 ( a "100 m^2" "Are") 80 ( a "100 m^2" "Are")
81 ( acre "(1/640) mi^2" "Acre" ) 81 ( acre "(1/640) mi^2" "Acre" )
84 ;; Volume 84 ;; Volume
85 ( L "10^(-3) m^3" "*Liter" ) 85 ( L "10^(-3) m^3" "*Liter" )
86 ( l "L" "Liter" ) 86 ( l "L" "Liter" )
87 ( gal "4 qt" "US Gallon" ) 87 ( gal "4 qt" "US Gallon" )
88 ( qt "2 pt" "Quart" ) 88 ( qt "2 pt" "Quart" )
89 ( pt "2 cup" "Pint" ) 89 ( pt "2 cup" "Pint (**)" )
90 ( cup "8 ozfl" "Cup" ) 90 ( cup "8 ozfl" "Cup" )
91 ( ozfl "2 tbsp" "Fluid Ounce" ) 91 ( ozfl "2 tbsp" "Fluid Ounce" )
92 ( floz "2 tbsp" "Fluid Ounce" ) 92 ( floz "2 tbsp" "Fluid Ounce" )
93 ( tbsp "3 tsp" "Tablespoon" ) 93 ( tbsp "3 tsp" "Tablespoon" )
94 ;; ESUWM defines a US gallon as 231 in^3. 94 ;; ESUWM defines a US gallon as 231 in^3.
1529 (insert " ")) 1529 (insert " "))
1530 (insert "10^" (int-to-string (nth 2 (nth 1 u)))) 1530 (insert "10^" (int-to-string (nth 2 (nth 1 u))))
1531 (indent-to 15) 1531 (indent-to 15)
1532 (insert " " (nth 2 u) "\n") 1532 (insert " " (nth 2 u) "\n")
1533 (while (eq (car (car (setq uptr (cdr uptr)))) 0))) 1533 (while (eq (car (car (setq uptr (cdr uptr)))) 0)))
1534 (insert "\n")) 1534 (insert "\n\n")
1535 (insert "(**) When in TeX or LaTeX display mode, the TeX specific unit\n"
1536 "names will not use the `tex' prefix; the unit name for a\n"
1537 "TeX point will be `pt' instead of `texpt', for example.\n"
1538 "To avoid conflicts, the unit names for pint and parsec will\n"
1539 "be `pint' and `parsec' instead of `pt' and `pc'."))
1535 (view-mode) 1540 (view-mode)
1536 (message "Formatting units table...done")) 1541 (message "Formatting units table...done"))
1537 (setq math-units-table-buffer-valid t) 1542 (setq math-units-table-buffer-valid t)
1538 (let ((oldbuf (current-buffer))) 1543 (let ((oldbuf (current-buffer)))
1539 (set-buffer buf) 1544 (set-buffer buf)