Mercurial > hg > xemacs-beta
comparison lisp/wid-edit.el @ 776:79940b592197
[xemacs-hg @ 2002-03-15 07:43:14 by ben]
.cvsignore: ignore .tmp files that are getting auto-created by VC.
Makefile.in.in: Use -no-packages to avoid problems with package files shadowing
core files (e.g. unicode.el in mule-ucs).
alloc.c, emacs.c, lisp.h: add new -no-packages. make sure list of args for sorting is
actually correct. clean up arg parsing code.
xemacs.mak: Use -no-packages to avoid problems with package files shadowing
core files (e.g. unicode.el in mule-ucs).
Makefile: Use -no-packages to avoid problems with package files shadowing
core files (e.g. unicode.el in mule-ucs).
mule\chinese.el, mule\japan-util.el: fix warnings.
behavior-defs.el: fix errors with require.
bytecomp-runtime.el: add new funs {when,and}-{f}boundp, clean up docs.
cus-edit.el: pretty-print values.
dump-paths.el, find-paths.el, startup.el, setup-paths.el: fix problems/inconsistencies parsing options. support new
-no-packages option. merge code duplication in dump-paths and
startup.
lisp-mode.el: indent macrolet and labels correctly. update comments about
lisp-indent-function. flet already handled in cl.
apropos.el, auto-save.el, buff-menu.el, cl-extra.el, dragdrop.el, faces.el, files.el, fill.el, font-lock.el, font.el, gtk-faces.el, gui.el, help.el, hyper-apropos.el, info.el, isearch-mode.el, keymap.el, lisp-mnt.el, mouse.el, package-admin.el, package-get.el, printer.el, process.el, resize-minibuffer.el, simple.el, toolbar-items.el, wid-edit.el, win32-native.el: fix warnings.
very-early-lisp.el: update docs.
mule\chinese.el, mule\japan-util.el: fix warnings.
mule\chinese.el, mule\japan-util.el: fix warnings.
behavior-defs.el: fix errors with require.
bytecomp-runtime.el: add new funs {when,and}-{f}boundp, clean up docs.
cus-edit.el: pretty-print values.
dump-paths.el, find-paths.el, startup.el, setup-paths.el: fix problems/inconsistencies parsing options. support new
-no-packages option. merge code duplication in dump-paths and
startup.
lisp-mode.el: indent macrolet and labels correctly. update comments about
lisp-indent-function. flet already handled in cl.
apropos.el, auto-save.el, buff-menu.el, cl-extra.el, dragdrop.el, faces.el, files.el, fill.el, font-lock.el, font.el, gtk-faces.el, gui.el, help.el, hyper-apropos.el, info.el, isearch-mode.el, keymap.el, lisp-mnt.el, mouse.el, package-admin.el, package-get.el, printer.el, process.el, resize-minibuffer.el, simple.el, toolbar-items.el, wid-edit.el, win32-native.el: fix warnings.
very-early-lisp.el: update docs.
mule\chinese.el, mule\japan-util.el: fix warnings.
Makefile.in.in: Use -no-packages to avoid problems with package files shadowing
core files (e.g. unicode.el in mule-ucs).
Makefile.in.in: Use -no-packages to avoid problems with package files shadowing
core files (e.g. unicode.el in mule-ucs).
author | ben |
---|---|
date | Fri, 15 Mar 2002 07:43:43 +0000 |
parents | 76d5a3dd827a |
children | 315720febed1 |
comparison
equal
deleted
inserted
replaced
775:7d972c3de90a | 776:79940b592197 |
---|---|
1527 ;; #### Bletch! This loses because XEmacs get confused | 1527 ;; #### Bletch! This loses because XEmacs get confused |
1528 ;; if before-change-functions change the contents of | 1528 ;; if before-change-functions change the contents of |
1529 ;; buffer before from/to. | 1529 ;; buffer before from/to. |
1530 (condition-case nil | 1530 (condition-case nil |
1531 (widget-apply from-field :notify from-field) | 1531 (widget-apply from-field :notify from-field) |
1532 (error (debug "Before Change")))))))) | 1532 (error (declare-fboundp (debug "Before Change"))))))))) |
1533 | 1533 |
1534 (defun widget-add-change () | 1534 (defun widget-add-change () |
1535 (make-local-hook 'post-command-hook) | 1535 (make-local-hook 'post-command-hook) |
1536 (remove-hook 'post-command-hook 'widget-add-change t) | 1536 (remove-hook 'post-command-hook 'widget-add-change t) |
1537 (make-local-hook 'before-change-functions) | 1537 (make-local-hook 'before-change-functions) |
1547 (condition-case nil | 1547 (condition-case nil |
1548 (let ((field (widget-field-find from)) | 1548 (let ((field (widget-field-find from)) |
1549 (other (widget-field-find to))) | 1549 (other (widget-field-find to))) |
1550 (when field | 1550 (when field |
1551 (unless (eq field other) | 1551 (unless (eq field other) |
1552 (debug "Change in different fields")) | 1552 (declare-fboundp (debug "Change in different fields"))) |
1553 (let ((size (widget-get field :size))) | 1553 (let ((size (widget-get field :size))) |
1554 (when size | 1554 (when size |
1555 (let ((begin (widget-field-start field)) | 1555 (let ((begin (widget-field-start field)) |
1556 (end (widget-field-end field))) | 1556 (end (widget-field-end field))) |
1557 (cond ((< (- end begin) size) | 1557 (cond ((< (- end begin) size) |
1572 (while (and (eq (preceding-char) ?\ ) | 1572 (while (and (eq (preceding-char) ?\ ) |
1573 (> (point) begin)) | 1573 (> (point) begin)) |
1574 (delete-backward-char 1))))))) | 1574 (delete-backward-char 1))))))) |
1575 (widget-specify-secret field)) | 1575 (widget-specify-secret field)) |
1576 (widget-apply field :notify field))) | 1576 (widget-apply field :notify field))) |
1577 (error (debug "After Change")))) | 1577 (error (declare-fboundp (debug "After Change"))))) |
1578 | 1578 |
1579 | 1579 |
1580 ;;; Widget Functions | 1580 ;;; Widget Functions |
1581 ;; | 1581 ;; |
1582 ;; These functions are used in the definition of multiple widgets. | 1582 ;; These functions are used in the definition of multiple widgets. |
2032 (defun widget-url-link-help-echo (widget) | 2032 (defun widget-url-link-help-echo (widget) |
2033 (concat "Visit <URL:" (widget-value widget) ">")) | 2033 (concat "Visit <URL:" (widget-value widget) ">")) |
2034 | 2034 |
2035 (defun widget-url-link-action (widget &optional event) | 2035 (defun widget-url-link-action (widget &optional event) |
2036 "Open the url specified by WIDGET." | 2036 "Open the url specified by WIDGET." |
2037 (if (fboundp 'browse-url) | 2037 (if-fboundp 'browse-url |
2038 (browse-url (widget-value widget)) | 2038 (browse-url (widget-value widget)) |
2039 (error "Cannot follow URLs in this XEmacs"))) | 2039 (error 'unimplemented "No `browse-url' package; cannot follow URLs in this XEmacs"))) |
2040 | 2040 |
2041 ;;; The `function-link' Widget. | 2041 ;;; The `function-link' Widget. |
2042 | 2042 |
2043 (define-widget 'function-link 'link | 2043 (define-widget 'function-link 'link |
2044 "A link to an Emacs function." | 2044 "A link to an Emacs function." |