/[emacs]/emacs/lisp/international/mule-cmds.el
ViewVC logotype

Diff of /emacs/lisp/international/mule-cmds.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.257 by handa, Sat Jun 12 02:21:21 2004 UTC revision 1.258 by rms, Thu Nov 4 10:10:35 2004 UTC
# Line 1368  If INPUT-METHOD is nil, deactivate any c Line 1368  If INPUT-METHOD is nil, deactivate any c
1368                current-input-method-title nil)                current-input-method-title nil)
1369          (force-mode-line-update)))))          (force-mode-line-update)))))
1370    
1371  (defun set-input-method (input-method)  (defun set-input-method (input-method &optional interactive)
1372    "Select and activate input method INPUT-METHOD for the current buffer.    "Select and activate input method INPUT-METHOD for the current buffer.
1373  This also sets the default input method to the one you specify.  This also sets the default input method to the one you specify.
1374  If INPUT-METHOD is nil, this function turns off the input method, and  If INPUT-METHOD is nil, this function turns off the input method, and
1375  also causes you to be prompted for a name of an input method the next  also causes you to be prompted for a name of an input method the next
1376  time you invoke \\[toggle-input-method].  time you invoke \\[toggle-input-method].
1377    When called interactively, the optional arg INTERACTIVE is non-nil,
1378    which marks the variable `default-input-method' as set for Custom buffers.
1379    
1380  To deactivate the input method interactively, use \\[toggle-input-method].  To deactivate the input method interactively, use \\[toggle-input-method].
1381  To deactivate it programmatically, use \\[inactivate-input-method]."  To deactivate it programmatically, use \\[inactivate-input-method]."
# Line 1381  To deactivate it programmatically, use \ Line 1383  To deactivate it programmatically, use \
1383     (let* ((default (or (car input-method-history) default-input-method)))     (let* ((default (or (car input-method-history) default-input-method)))
1384       (list (read-input-method-name       (list (read-input-method-name
1385              (if default "Select input method (default %s): " "Select input method: ")              (if default "Select input method (default %s): " "Select input method: ")
1386              default t))))              default t)
1387               t)))
1388    (activate-input-method input-method)    (activate-input-method input-method)
1389    (setq default-input-method input-method)    (setq default-input-method input-method)
1390    (when (interactive-p)    (when interactive
1391      (customize-mark-as-set 'default-input-method))      (customize-mark-as-set 'default-input-method))
1392    default-input-method)    default-input-method)
1393    
1394  (defun toggle-input-method (&optional arg)  (defun toggle-input-method (&optional arg interactive)
1395    "Enable or disable multilingual text input method for the current buffer.    "Enable or disable multilingual text input method for the current buffer.
1396  Only one input method can be enabled at any time in a given buffer.  Only one input method can be enabled at any time in a given buffer.
1397    
# Line 1401  minibuffer. Line 1404  minibuffer.
1404    
1405  With a prefix argument, read an input method name with the minibuffer  With a prefix argument, read an input method name with the minibuffer
1406  and enable that one.  The default is the most recent input method specified  and enable that one.  The default is the most recent input method specified
1407  \(not including the currently active input method, if any)."  \(not including the currently active input method, if any).
1408    
1409    (interactive "P")  When called interactively, the optional arg INTERACTIVE is non-nil,
1410    which marks the variable `default-input-method' as set for Custom buffers."
1411    
1412      (interactive "P\np")
1413    (if (and current-input-method (not arg))    (if (and current-input-method (not arg))
1414        (inactivate-input-method)        (inactivate-input-method)
1415      (let ((default (or (car input-method-history) default-input-method)))      (let ((default (or (car input-method-history) default-input-method)))
# Line 1420  and enable that one.  The default is the Line 1426  and enable that one.  The default is the
1426        (unless default-input-method        (unless default-input-method
1427          (prog1          (prog1
1428              (setq default-input-method current-input-method)              (setq default-input-method current-input-method)
1429            (when (interactive-p)            (when interactive
1430              (customize-mark-as-set 'default-input-method)))))))              (customize-mark-as-set 'default-input-method)))))))
1431    
1432  (defun describe-input-method (input-method)  (defun describe-input-method (input-method)

Legend:
Removed from v.1.257  
changed lines
  Added in v.1.258

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26