aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJay Belanger2011-03-20 15:59:29 -0500
committerJay Belanger2011-03-20 15:59:29 -0500
commit1fe275ee28e8a37fdbbd6d6cf75f1b15b9674b4b (patch)
tree34ad4db517d3e9eb6f73eae850f620303ab9e05c
parent45b6f6d5cba8274c2e75d3cc7cd7a14f54a7b659 (diff)
downloademacs-1fe275ee28e8a37fdbbd6d6cf75f1b15b9674b4b.tar.gz
emacs-1fe275ee28e8a37fdbbd6d6cf75f1b15b9674b4b.zip
* calc/calc-menu.el (calc-units-menu): Add entries for logarithmic
units and musical notes.
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/calc/calc-menu.el105
2 files changed, 110 insertions, 0 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index fe45788d888..b12445b466f 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12011-03-20 Jay Belanger <jay.p.belanger@gmail.com>
2
3 * calc/calc-menu.el (calc-units-menu): Add entries for logarithmic
4 units and musical notes.
5
12011-03-20 Leo <sdl.web@gmail.com> 62011-03-20 Leo <sdl.web@gmail.com>
2 7
3 * ido.el (ido-read-internal): Use completing-read-default. 8 * ido.el (ido-read-internal): Use completing-read-default.
diff --git a/lisp/calc/calc-menu.el b/lisp/calc/calc-menu.el
index aaddf3e486e..d8099b0aadc 100644
--- a/lisp/calc/calc-menu.el
+++ b/lisp/calc/calc-menu.el
@@ -960,6 +960,111 @@
960 (require 'calc-units) 960 (require 'calc-units)
961 (call-interactively 'calc-view-units-table)) 961 (call-interactively 'calc-view-units-table))
962 :keys "u V"] 962 :keys "u V"]
963 (list "Logarithmic Units"
964 ["Convert (1:) to dB (power)"
965 (progn
966 (require 'calc-units)
967 (call-interactively 'calc-db))
968 :keys "l d"
969 :active (>= (calc-stack-size) 1)]
970 ["Convert (2:) to dB (power) with reference level (1:)"
971 (progn
972 (require 'calc-units)
973 (let ((calc-option-flag t))
974 (call-interactively 'calc-db)))
975 :keys "O l d"
976 :active (>= (calc-stack-size) 2)]
977 ["Convert (1:) to Np (power)"
978 (progn
979 (require 'calc-units)
980 (call-interactively 'calc-np))
981 :keys "l n"
982 :active (>= (calc-stack-size) 1)]
983 ["Convert (2:) to Np (power) with reference level (1:)"
984 (progn
985 (require 'calc-units)
986 (let ((calc-option-flag t))
987 (call-interactively 'calc-np)))
988 :keys "O l n"
989 :active (>= (calc-stack-size) 2)]
990 ["Convert (1:) to power quantity"
991 (progn
992 (require 'calc-units)
993 (call-interactively 'calc-lu-quant))
994 :keys "l q"
995 :active (>= (calc-stack-size) 1)]
996 ["Convert (2:) to power quantity with reference level (1:)"
997 (progn
998 (require 'calc-units)
999 (let ((calc-option-flag t))
1000 (call-interactively 'calc-lu-quant)))
1001 :keys "O l q"
1002 :active (>= (calc-stack-size) 2)]
1003 "----"
1004 ["Convert (1:) to dB (field)"
1005 (progn
1006 (require 'calc-units)
1007 (let ((calc-hyperbolic-flag t))
1008 (call-interactively 'calc-db)))
1009 :keys "H l d"
1010 :active (>= (calc-stack-size) 1)]
1011 ["Convert (2:) to dB (field) with reference level (1:)"
1012 (progn
1013 (require 'calc-units)
1014 (let ((calc-option-flag t)
1015 (calc-hyperbolic-flag t))
1016 (call-interactively 'calc-db)))
1017 :keys "O H l d"
1018 :active (>= (calc-stack-size) 2)]
1019 ["Convert (1:) to Np (field)"
1020 (progn
1021 (require 'calc-units)
1022 (let ((calc-hyperbolic-flag t))
1023 (call-interactively 'calc-np)))
1024 :keys "H l n"
1025 :active (>= (calc-stack-size) 1)]
1026 ["Convert (2:) to Np (field) with reference level (1:)"
1027 (progn
1028 (require 'calc-units)
1029 (let ((calc-option-flag t)
1030 (calc-hyperbolic-flag t))
1031 (call-interactively 'calc-np)))
1032 :keys "O H l d"
1033 :active (>= (calc-stack-size) 2)]
1034 ["Convert (1:) to field quantity"
1035 (progn
1036 (require 'calc-units)
1037 (let ((calc-hyperbolic-flag t))
1038 (call-interactively 'calc-lu-quant)))
1039 :keys "H l q"
1040 :active (>= (calc-stack-size) 1)]
1041 ["Convert (2:) to field quantity with reference level (1:)"
1042 (progn
1043 (require 'calc-units)
1044 (let ((calc-option-flag t)
1045 (calc-hyperbolic-flag))
1046 (call-interactively 'calc-lu-quant)))
1047 :keys "O H l q"
1048 :active (>= (calc-stack-size) 2)])
1049 (list "Musical Notes"
1050 ["Convert (1:) to scientific pitch notation"
1051 (progn
1052 (require 'calc-units)
1053 (call-interactively 'calc-spn))
1054 :keys "l s"
1055 :active (>= (calc-stack-size) 1)]
1056 ["Convert (1:) to midi number"
1057 (progn
1058 (require 'calc-units)
1059 (call-interactively 'calc-midi))
1060 :keys "l m"
1061 :active (>= (calc-stack-size) 1)]
1062 ["Convert (1:) to frequency"
1063 (progn
1064 (require 'calc-units)
1065 (call-interactively 'calc-freq))
1066 :keys "l f"
1067 :active (>= (calc-stack-size) 1)])
963 "----" 1068 "----"
964 ["Help on Units" 1069 ["Help on Units"
965 (calc-info-goto-node "Units")]) 1070 (calc-info-goto-node "Units")])