Martin Rudalics
8c7727c335
Fix bug#12731 in mouse-drag-line.
...
* mouse.el (mouse-drag-line): Move last form into preceding when
clause (Bug#12731).
* help.el (resize-temp-buffer-window): Fix doc-string.
2012-10-26 11:11:24 +02:00
Daniel Colascione
36a305a723
Merge from trunk
2012-10-07 14:31:58 -08:00
Chong Yidong
59f7af816e
Use declare forms, where possible, to mark obsolete functions.
...
* lisp/allout.el (allout-passphrase-hint-string): Likewise.
(allout-init): Use a declare form to mark obsolete.
* lisp/calendar/calendar.el (calendar-version):
* lisp/calendar/icalendar.el (icalendar-extract-ical-from-buffer)
(icalendar-convert-diary-to-ical):
* lisp/cus-edit.el (custom-mode):
* lisp/ansi-color.el (ansi-color-unfontify-region):
* lisp/international/latin1-disp.el (latin1-char-displayable-p):
* lisp/progmodes/cwarn.el (turn-on-cwarn-mode):
* lisp/progmodes/which-func.el (which-func-update-1): Use
define-obsolete-function-alias.
* lisp/bookmark.el (bookmark-jump-noselect): Use a declare form to mark
this function obsolete.
* lisp/calendar/cal-x.el (calendar-two-frame-setup)
(calendar-only-one-frame-setup, calendar-one-frame-setup):
* lisp/calendar/calendar.el (american-calendar, european-calendar)
(calendar-for-loop):
* lisp/comint.el (comint-dynamic-simple-complete)
(comint-dynamic-complete-as-filename, comint-unquote-filename):
* lisp/desktop.el (desktop-load-default):
* lisp/dired-x.el (dired-omit-here-always)
(dired-hack-local-variables, dired-default-directory):
* lisp/emacs-lisp/derived.el (derived-mode-class):
* lisp/emacs-lisp/timer.el (timer-set-time-with-usecs):
* lisp/emacs-lock.el (toggle-emacs-lock):
* lisp/epa.el (epa-display-verify-result):
* lisp/epg.el (epg-sign-keys, epg-start-sign-keys)
(epg-passphrase-callback-function):
* lisp/eshell/esh-util.el (eshell-for):
* lisp/eshell/eshell.el (eshell-remove-from-window-buffer-names)
(eshell-add-to-window-buffer-names):
* lisp/files.el (locate-file-completion):
* lisp/imenu.el (imenu-example--create-c-index)
(imenu-example--create-lisp-index)
(imenu-example--lisp-extract-index-name)
(imenu-example--name-and-position):
* lisp/international/mule-cmds.el (princ-list):
* lisp/international/mule-diag.el (decode-codepage-char):
* lisp/international/mule-util.el (detect-coding-with-priority):
* lisp/iswitchb.el (iswitchb-read-buffer):
* lisp/mail/mailalias.el (mail-complete):
* lisp/mail/sendmail.el (mail-sent-via):
* lisp/mouse.el (mouse-popup-menubar-stuff, mouse-popup-menubar)
(mouse-major-mode-menu):
* lisp/password-cache.el (password-read-and-add):
* lisp/pcomplete.el (pcomplete-parse-comint-arguments):
* lisp/progmodes/sh-script.el (sh-maybe-here-document):
* lisp/replace.el (query-replace-regexp-eval):
* lisp/savehist.el (savehist-load):
* lisp/simple.el (choose-completion-delete-max-match):
* lisp/term.el (term-dynamic-simple-complete):
* lisp/vc/ediff-init.el (ediff-check-version):
* lisp/vc/ediff-wind.el (ediff-choose-window-setup-function-automatically):
* lisp/vc/vc.el (vc-diff-switches-list):
* lisp/view.el (view-return-to-alist-update): Likewise.
* lisp/iswitchb.el (iswitchb-read-buffer): Move code of
iswitchb-define-mode-map here, and delete that obsolete function.
* lisp/subr.el (eval-next-after-load, makehash, insert-string)
(assoc-ignore-representation, assoc-ignore-case): Use declare to
mark obsolete.
(mode-line-inverse-video): Variable deleted.
* lisp/emacs-lisp/byte-run.el (make-obsolete): Doc fix; emphasize that
this applies to functions.
* lisp/erc/erc.el (erc-send-command): Use define-obsolete-function-alias.
* lisp/international/mule-util.el (string-to-sequence): Remove.
* lisp/net/newst-backend.el (newsticker-cache-filename):
* lisp/net/newst-treeview.el (newsticker-groups-filename): Fix
incorrect obsolescence declaration.
* lisp/net/snmp-mode.el (snmp-font-lock-keywords-3): Don't use obsolete
font-lock-reference-face.
* lisp/url/url-parse.el (url-recreate-url-attributes):
* lisp/url/url-util.el (url-generate-unique-filename): Use declare to mark
obsolete.
* src/xdisp.c (mode_line_inverse_video): Delete obsolete variable.
2012-09-25 12:13:02 +08:00
Daniel Colascione
0fda9b750e
Implement cygw32
...
Here, we use the generic window-system configuration system we just
implemented to support the w32 window-system in the mainline build
under Cygwin. (Previously, the w32 window system could only be
compiled as part of the NT-native Emacs build process.)
The changes in this patch need to be applied atomically in order to
avoid breaking Emacs. The changes include:
- Changes throughout the Lisp and C code to not assume that
NT Emacs and the w32 window system are synonymous.
- Wiring up the regular select(2) event loop to Windows messages
- Cleaning up the w32 drag-and-drop receiving code.
- Exposing Cygwin path conversion functions to elisp.
- Unicode file dialog support when compiling for Cygwin.
- Splitting the w32 term lisp initialization code into code
applicable to any w32 window-system and code specific to
system-type windows-nt.
- Integrating the old and new w32 code into the build system.
2012-09-17 03:55:02 -08:00
Chong Yidong
383dcbf977
Allow face-remapping using :font, and use it in mouse-appearance-menu.
...
* mouse.el (mouse-appearance-menu): If x-select-font returns a
font spec, set the font directly.
* xfaces.c (merge_face_vectors): If the target font specfies a
font spec, make the font's attributes take precedence over
directly-specified attributes.
(merge_face_ref): Recognize :font.
Fixes: debbugs:3228
2012-08-17 17:10:31 +08:00
Stefan Monnier
e18941095a
* lisp/term/x-win.el (x-menu-bar-open): Always pass last-nonmenu-event.
...
* lisp/subr.el (eventp): `nil' is not an event, and eventp is not hot.
(event-start, event-end): Use posn-at-point to return a more
informative posn.
(posnp): New function.
* lisp/mouse.el (popup-menu-normalize-position): Use it.
2012-08-10 10:47:12 -04:00
Masatake YAMATO
c69f56a207
* lisp/mouse.el (popup-menu-normalize-position): New function.
...
(popup-menu): Use `popup-menu-normalize-position' to normalize
the form for POSITION argument.
* lisp/term/x-win.el (x-menu-bar-open):
Use the value returend from (posn-at-point) as position
passed to `popup-menu'.
2012-08-10 08:44:06 -04:00
Martin Rudalics
c8e5a42c4a
In mouse-drag-line don't exit tracking prematurely (Bug#12006).
...
* mouse.el (popup-menu): Fix doc-string and re-indent code.
(mouse-drag-line): Don't exit tracking when a switch-frame or
switch-window event occurs (Bug#12006).
2012-07-26 10:32:25 +02:00
Stefan Monnier
670d85ea14
* lisp/mouse.el (popup-menu): Fix last change.
2012-07-25 21:29:24 -04:00
Masatake YAMATO
bbf0e7d978
* lisp/term/x-win.el (x-menu-bar-open): Use `frame-parameter'
...
to check whether menu-bar is shown or not. If not shown,
show the menu-bar as a popup menu instead of using tmm.
* lisp/mouse.el (popup-menu): Accept `point' as `position' argument.
2012-07-20 07:32:30 -04:00
Chong Yidong
01ac65bd7c
Fix interaction of line-dragging with mouse-1-click-follows-link.
...
* lisp/mouse.el (mouse-drag-line): Rewrite the track-mouse loop.
Implement the mouse-1-click-follows-link handling properly.
* lisp/info.el (Info-link-keymap): Use follow-link mechanism for
header-line links.
Fixes: debbugs:374
2012-07-08 16:26:21 +08:00
Chong Yidong
7af107c7a3
Fix last commit.
2012-06-23 20:54:59 +08:00
Chong Yidong
05e89feafd
* mouse.el (mouse-drag-track): Deactivate the mark before popping.
2012-06-23 20:48:24 +08:00
Chong Yidong
8cca97031d
Do not set mark on single mouse-1 clicks.
...
* mouse.el (mouse-drag-track): Do not set the mark if the user
releases the mouse without selecting anything.
Fixes: debbugs:11588
2012-06-13 23:28:10 +08:00
Stefan Monnier
71873e2b33
Add new error and function `user-error'.
...
* lisp/subr.el (user-error): New function.
* lisp/window.el (switch-to-buffer):
* lisp/vc/smerge-mode.el (smerge-resolve-function, smerge-resolve)
(smerge-match-conflict):
* lisp/simple.el (previous-matching-history-element)
(next-matching-history-element, goto-history-element, undo-more)
(undo-start):
* lisp/progmodes/etags.el (visit-tags-table-buffer, find-tag-tag)
(find-tag-noselect, find-tag-in-order, etags-goto-tag-location)
(next-file, tags-loop-scan, list-tags, complete-tag):
* lisp/progmodes/compile.el (compilation-loop):
* lisp/mouse.el (mouse-minibuffer-check):
* lisp/man.el (Man-bgproc-sentinel, Man-goto-page):
* lisp/info.el (Info-find-node-2, Info-extract-pointer, Info-history-back)
(Info-history-forward, Info-follow-reference, Info-menu)
(Info-extract-menu-item, Info-extract-menu-counting)
(Info-forward-node, Info-backward-node, Info-next-menu-item)
(Info-last-menu-item, Info-next-preorder, Info-last-preorder)
(Info-next-reference, Info-prev-reference, Info-index)
(Info-index-next, Info-follow-nearest-node)
(Info-copy-current-node-name):
* lisp/imenu.el (imenu--make-index-alist)
(imenu-default-create-index-function, imenu-add-to-menubar):
* lisp/files.el (basic-save-buffer, recover-file):
* lisp/emacs-lisp/easy-mmode.el (easy-mmode-define-navigation):
* lisp/emacs-lisp/checkdoc.el (checkdoc-continue, checkdoc-comments)
(checkdoc-message-text, checkdoc-defun):
* lisp/dabbrev.el (dabbrev-completion, dabbrev--abbrev-at-point):
* lisp/cus-edit.el (customize-changed-options, customize-rogue)
(customize-saved, custom-variable-set, custom-variable-mark-to-save)
(custom-variable-mark-to-reset-standard)
(custom-variable-reset-backup, custom-face-mark-to-reset-standard)
(custom-file):
* lisp/completion.el (check-completion-length):
* lisp/comint.el (comint-search-arg)
(comint-previous-matching-input-string-position)
(comint-previous-matching-input)
(comint-replace-by-expanded-history-before-point, comint-send-input)
(comint-copy-old-input, comint-backward-matching-input)
(comint-goto-process-mark, comint-set-process-mark):
* lisp/calendar/calendar.el (calendar-cursor-to-date): Use it.
* lisp/bindings.el (debug-ignored-errors): Remove regexps, add `user-error'.
* src/data.c (PUT_ERROR): New macro.
(syms_of_data): Use it. Add new error type `user-error'.
* src/undo.c (user_error): New function.
(Fprimitive_undo): Use it.
* src/print.c (print_error_message): Adjust print style for `user-error'.
* src/keyboard.c (user_error): New function.
(Fexit_recursive_edit, Fabort_recursive_edit): Use it.
2012-05-04 19:16:47 -04:00
Chong Yidong
a8e7d6d783
Merge changes from emacs-24 branch
2012-04-27 11:10:38 +08:00
Martin Rudalics
41cfe0cb4c
Fix resizing of minibuffer windows (Bug#11276).
...
* window.el (adjust-window-trailing-edge, enlarge-window)
(shrink-window, window-resize):
* mouse.el (mouse-drag-line): Fix resizing of minibuffer
windows (Bug#11276).
2012-04-20 10:49:24 +02:00
Juanma Barranquero
4d6769e1bb
lisp/*: Add declarations, remove unused bindings, mark unused args.
...
* lisp/avoid.el (mouse-avoidance-mode): Mark unused arg.
(mouse-avoidance-nudge-mouse): Remove unused binding.
* lisp/imenu.el (imenu-default-goto-function): Mark unused args.
(imenu-progress-message): Remove obsolete macro; all callers changed.
* lisp/mouse.el (mouse-menu-major-mode-map):
* lisp/emacs-lisp/authors.el (authors-scan-change-log)
(authors-add-to-author-list):
* lisp/emacs-lisp/avl-tree.el (avl-tree--enter-balance):
* lisp/emacs-lisp/smie.el (smie-auto-fill):
* lisp/mail/sendmail.el (mail-bury):
* lisp/mail/unrmail.el (unrmail):
* lisp/net/tls.el (open-tls-stream):
* lisp/textmodes/picture.el (picture-mouse-set-point):
Remove unused bindings.
* lisp/subr.el (keymap-canonicalize): Remove unused binding.
(read-passwd): Mark unused arg.
* lisp/tutorial.el (tutorial--display-changes): Remove unused binding.
(tutorial--save-tutorial-to): Remove unused variable.
* lisp/emacs-lisp/package.el (define-package, package-menu-mark-delete)
(package-menu-mark-install, package-menu-mark-unmark): Mark unused args.
(package-generate-autoloads, package-menu--generate)
(package-menu--find-upgrades): Remove unused bindings.
* lisp/emulation/cua-rect.el (cua-restrict-regexp-rectangle)
(cua-restrict-prefix-rectangle): Doc fixes. Remove unused bindings.
(cua--mouse-ignore, cua--delete-rectangle, cua--extract-rectangle)
(cua--indent-rectangle, cua-open-rectangle, cua-close-rectangle)
(cua-blank-rectangle, cua-string-rectangle, cua-replace-in-rectangle)
(cua-incr-rectangle, cua-sequence-rectangle, cua--convert-rectangle-as)
(cua--rectangle-aux-replace, cua--left-fill-rectangle)
(cua-scroll-rectangle-up, cua-scroll-rectangle-down)
(cua-delete-char-rectangle): Mark unused args.
(cua-align-rectangle): Remove unused binding.
* lisp/mail/rmail.el (compilation--message->loc)
(epa--find-coding-system-for-mime-charset): Declare.
* lisp/net/dbus.el (dbus-register-service): Declare.
(dbus-name-owner-changed-handler): Remove unused binding.
* lisp/nxml/nxml-mode.el (nxml-electric-slash, nxml-in-mixed-content-p)
(nxml-compute-indent-from-matching-start-tag): Remove unused variables.
(nxml-scan-backward-within): Mark unused arg.
(nxml-dynamic-markup-word): Remove unused binding.
2012-04-19 19:20:26 +02:00
Glenn Morris
41f03f4da7
Use auto-hscroll-mode rather than the alias automatic-hscrolling
...
* lisp/mouse.el (mouse-drag-track):
* lisp/speedbar.el (speedbar-frame-mode):
Use auto-hscroll-mode rather than the alias automatic-hscrolling.
2012-04-16 20:04:53 -04:00
Glenn Morris
acaf905b11
Add 2012 to FSF copyright years for Emacs files
2012-01-05 01:46:05 -08:00
Paul Eggert
22bcf20469
Spelling fixes.
2011-12-30 17:27:15 -08:00
Chong Yidong
e1eb5385bb
* lisp/mouse.el (mouse-yank-primary): Push the mark.
...
Fixes: debbugs:9894
2011-10-29 14:09:02 +08:00
Martin Rudalics
53ebff1ff0
In mouse-drag-line correctly use window-in-direction.
2011-10-22 19:06:13 +02:00
Martin Rudalics
42ee24ed38
Fix minibuffer resizing.
...
* mouse.el (mouse-drag-line): Fix minibuffer resizing broken by
last change.
2011-10-22 11:43:09 +02:00
Martin Rudalics
e07b9a6d33
Fix and improve mouse-dragging of horizontal/vertical lines.
...
* mouse.el (mouse-drag-window-above)
(mouse-drag-move-window-bottom, mouse-drag-move-window-top)
(mouse-drag-mode-line-1, mouse-drag-header-line)
(mouse-drag-vertical-line-rightward-window): Remove.
(mouse-drag-line): New function.
(mouse-drag-mode-line, mouse-drag-header-line)
(mouse-drag-vertical-line): Call mouse-drag-line.
* window.el (window-at-side-p, windows-at-side): New functions.
2011-10-21 11:15:32 +02:00
Stefan Monnier
984889776c
* lisp/mouse.el (mouse-drag-mode-line-1): Modify the end-event we pushed on
...
unread-command-events rather than pushing yet-another event.
2011-10-14 14:36:33 -04:00
Chong Yidong
371d6a6146
* mouse.el (mouse-drag-track): Set scroll-margin to 0 while tracking.
...
Fixes: debbugs:9541
2011-09-24 14:38:20 -04:00
Lars Magne Ingebrigtsen
43f5740b71
mouse-set-region doc fix
...
* mouse.el (mouse-set-region): Link to `mouse-drag-copy-region' in
the doc string (bug#7015).
2011-07-14 16:01:16 +02:00
Stefan Monnier
fe3f64d575
* lisp/mouse.el (mouse--strip-first-event): New function.
...
(function-key-map): Use it to map fringe clicks to normal clicks by default.
2011-07-01 13:58:14 -04:00
Stefan Monnier
fd6fa53f88
* lisp/minibuffer.el (minibuffer-inactive-mode-map): New var.
...
(minibuffer-inactive-mode): New major mode.
* src/minibuf.c (get_minibuffer, read_minibuf_unwind): Call it.
* lisp/mouse.el (mouse-drag-region): Remove the "mouse-1 pops up
the *Messages* buffer" hack.
(mouse-popup-menubar): Don't burp if the event is a normal key.
2011-06-01 12:34:41 -03:00
Glenn Morris
4ffd0d6b56
Merge from emacs-23; up to 2010-06-09T17:54:28Z!albinus@detlef.
2011-04-22 20:07:16 -07:00
Chong Yidong
3ad8bad038
Handle deferred `event-kind' property when using unread-command-events.
...
* src/mouse.el (mouse-drag-mode-line-1): Make sure that if we push
mouse-2 into unread-command-events, it is interpreted correctly.
2011-04-09 22:10:52 -04:00
Sam Steingold
7bc61bb7bf
* lisp/mouse.el (mouse-buffer-menu-mode-groups): Add a "GDB" group.
2011-02-04 09:54:13 -05:00
Sam Steingold
e8e4d5c88e
undo 2011-02-01T18:15:18Z!sds@gnu.org (purecopy-cons, purecopy-car) at Stefan Monnier's request
2011-02-01 16:37:12 -05:00
Sam Steingold
0b75349e7e
* lisp/subr.el (purecopy-cons, purecopy-car): Add shortcuts.
...
* lisp/faces.el (face-x-resources): Use `purecopy-cons'.
* lisp/files.el (auto-mode-alist, interpreter-mode-alist): Use
`purecopy-car'.
* lisp/international/fontset.el (font-encoding-alist): Ditto.
* lisp/international/mule-conf.el (file-coding-system-alist): Ditto.
* lisp/international/mule.el (auto-coding-alist)
(auto-coding-regexp-alist): Ditto.
* lisp/mouse.el (mouse-buffer-menu-mode-groups): Use `purecopy-cons'.
* lisp/term/x-win.el (x-gtk-stock-map): Ditto.
2011-02-01 13:15:18 -05:00
Chong Yidong
14beddf471
Merge changes from emacs-23 branch
2011-01-31 18:54:50 -05:00
Chong Yidong
d1f14baa30
* mouse.el (mouse-menu-non-singleton): Doc fix (Bug#7801).
2011-01-28 12:18:54 -05:00
Glenn Morris
73b0cd5003
Convert consecutive FSF copyright years to ranges.
2011-01-24 20:08:28 -08:00
Stefan Monnier
77ab81d054
Merge from emacs-23
2011-01-14 12:18:41 -05:00
Glenn Morris
5df4f04cd3
Add 2011 to FSF/AIST copyright years.
2011-01-02 15:50:46 -08:00
Eli Zaretskii
e77714da30
Fix bug #7699 with pasting selected text on MS-Windows.
...
mouse.el (mouse-yank-primary): On MS-Windows, try the (emulated)
PRIMARY first, then the clipboard.
2010-12-25 12:57:02 +02:00
Stefan Monnier
f49d1f52b2
Merge from emacs-23
2010-12-13 10:27:36 -05:00
Glenn Morris
d5e6e0b6df
mouse.el fix for bug#7586.
...
* lisp/mouse.el (mouse-menu-major-mode-map, mouse-menu-bar-map):
Run hooks to update menu contents.
2010-12-07 19:32:31 -08:00
Jan Djärv
e06918d22b
* mouse.el (mouse-yank-primary): Update comment (Bug#6802).
2010-11-05 13:11:12 +01:00
YAMAMOTO Mitsuharu
00d9e115db
Backport Bug#6765 fix from trunk.
...
* mouse.el (mouse-fixup-help-message): Match "mouse-2" only at the
beginning of the string. Use `string-match-p'. (Bug#6765)
2010-11-04 15:27:46 -04:00
Glenn Morris
3226d6cacf
Remove some functions, variables and aliases obsolete since at least 21.1.
...
* doc/misc/misc.texi (Shell Mode): Remove reference to old function name.
* src/character.c (Fchar_bytes): Remove obsolete function.
(syms_of_character): Remove Schar_bytes.
* lisp/subr.el (char-bytes): Remove obsolete function.
* lisp/emacs-lisp/checkdoc.el (checkdoc-minor-keymap): Remove obsolete alias.
* lisp/isearch.el (isearch-return-char): Remove obsolete function.
* lisp/mouse.el: No longer provide mldrag.
(mldrag-drag-mode-line, mldrag-drag-vertical-line):
Remove obsolete aliases.
* lisp/comint.el (comint-kill-output): Remove obsolete alias.
* lisp/shell.el: Comment fix.
* lisp/composite.el (decompose-composite-char): Remove obsolete function.
* lisp/ps-def.el (decompose-composite-char): Remove unused function.
* lisp/iswitchb.el (iswitchb-default-keybindings): Remove obsolete function.
* lisp/outline.el (outline-visible): Remove obsolete function.
* lisp/term/pc-win.el (x-frob-font-slant, x-frob-font-weight):
* lisp/faces.el (internal-find-face, internal-get-face)
(frame-update-faces, frame-update-face-colors)
(x-frob-font-weight, x-frob-font-slant)
(internal-frob-font-weight, internal-frob-font-slant)
(x-make-font-bold, x-make-font-demibold, x-make-font-unbold)
(x-make-font-italic, x-make-font-oblique, x-make-font-unitalic)
(x-make-font-bold-italic): Remove functions and aliases, obsolete
since Emacs 21.1.
* lisp/emulation/viper-util.el (viper-get-face):
* lisp/obsolete/lucid.el (find-face, get-face): Use facep.
* lisp/vc/ediff-init.el (ediff-valid-color-p, ediff-get-face):
Remove unused functions.
* lisp/vc/ediff-util.el (ediff-submit-report): Doc fix.
* etc/NEWS: Mention above changes.
2010-10-01 19:46:13 -07:00
David De La Harpe Golden
93d68d4f02
Respect mouse-drag-copy-region upon mouse-3 region adjustment.
...
* mouse.el (mouse-save-then-kill): Save region to kill-ring when
mouse-drag-copy-region is non-nil (Bug#6956).
2010-09-05 23:40:57 +01:00
Chong Yidong
bd78fa1d54
Add "Package:" file headers to denote built-in packages.
2010-08-29 12:17:13 -04:00
Chong Yidong
1c409d0b96
Avoid clobbering primary selection when switching frames (Bug#6872).
...
* lisp/mouse.el (mouse-yank-primary): Avoid setting primary when
deactivating the mark (Bug#6872).
* src/keyboard.c (command_loop_1): Don't set primary selection during
handle-switch-frame (Bug#6872).
2010-08-24 11:48:14 -04:00
Chong Yidong
d2625c3ded
Cleanups and fixes for mouse-save-then-kill and mouse-secondary-save-then-kill.
...
* mouse.el (mouse-save-then-kill): Don't save region to kill ring
when extending it. Before killing on the second click, check if
the buffer is the correct one. Doc fix.
(mouse-secondary-save-then-kill): Allow usage without first
calling mouse-start-secondary, by defaulting to point. Don't save
an empty secondary selection. Doc fix.
2010-08-21 00:46:23 -04:00