Merged from miles@gnu.org--gnu-2005 (patch 60-65, 246-265)
Patches applied: * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-246 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-247 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-248 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-249 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-250 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-251 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-252 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-253 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-254 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-255 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-256 Merge from gnus--rel--5.10 * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-257 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-258 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-259 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-260 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-261 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-262 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-263 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-264 Update from CVS * miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-265 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-60 Merge from emacs--cvs-trunk--0 * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-61 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-62 Merge from emacs--cvs-trunk--0 * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-63 Update from CVS * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-64 (mm-string-to-multibyte): Use Gnus trunk definition. * miles@gnu.org--gnu-2005/gnus--rel--5.10--patch-65 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-328
This commit is contained in:
commit
6ab9dd8034
89 changed files with 2669 additions and 1824 deletions
11
ChangeLog
11
ChangeLog
|
|
@ -1,3 +1,14 @@
|
|||
2005-04-14 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* make-dist: Distribute all ChangeLog files in lisp/.
|
||||
Don't distribute ldefs-boot.el.
|
||||
lisp/makefile.nt no longer exists.
|
||||
|
||||
2005-04-13 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* make-dist: Don't use DONTCOMPILE from lisp/Makefile.in; check
|
||||
for "no-byte-compile: t" in the file instead.
|
||||
|
||||
2005-03-16 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* configure.in <Motif>: Don't let a special LessTif/Motif1.2 install
|
||||
|
|
|
|||
|
|
@ -1,3 +1,9 @@
|
|||
2005-04-14 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* nt/makedist.bat (elfiles): Update.
|
||||
|
||||
* admin.el (add-release-logs): Fix require call.
|
||||
|
||||
2005-03-30 Marcelo Toledo <marcelo@marcelotoledo.org>
|
||||
|
||||
* FOR-RELEASE (Documentation): Added check the Emacs Tutorial. The
|
||||
|
|
|
|||
|
|
@ -20,6 +20,8 @@ See msg from rms to emacs-devel on 21 Dec.
|
|||
|
||||
** Enhance scroll-bar to handle tall line (similar to line-move).
|
||||
|
||||
** Adapt mouse-sel-mode to mouse-1-click-follows-link.
|
||||
|
||||
|
||||
* FATAL ERRORS
|
||||
|
||||
|
|
@ -80,42 +82,6 @@ A fix would be to somehow disable handling of display properties if an error
|
|||
is encountered.
|
||||
|
||||
|
||||
** custom mode-line face makes Emacs freeze up
|
||||
|
||||
From: Stephen Berman <Stephen.Berman@gmx.net>
|
||||
Date: Sun, 24 Oct 2004 02:08:56 +0200
|
||||
|
||||
1. Start Emacs with -q -no-site-file.
|
||||
|
||||
2. Type `M-x customize-face' and at the prompt `mode-line'.
|
||||
|
||||
3. In the Custom buffer for mode-line face
|
||||
a. check width and give it the value `narrow';
|
||||
b. check height and give it the value 120 in 1/10 pt;
|
||||
c. check underline and give it the value `on' (or `colored');
|
||||
d. check overline and give it the value `on' (or `colored').
|
||||
|
||||
4. Set for current session.
|
||||
|
||||
5. Invoke Ediff on any two files.
|
||||
|
||||
6. Now Emacs is frozen and consumes 95-99% of CPU.
|
||||
|
||||
The customizations in step 3 appear to be the minimum necessary to
|
||||
induce this bug. Leave out any one of them and Ediff runs without a
|
||||
problem. Also if the 1/10 point value of height is 130 or greater
|
||||
there's no bug (with the default font family; with e.g. Helvetica the
|
||||
bug is induced only by a value of 100 or less).
|
||||
|
||||
I've noticed this freeze up only when invoking Ediff. The only thing
|
||||
I've been able to do is kill Emacs externally, via top or with kill
|
||||
when run in gdb, after interrupting. When the freeze up happens
|
||||
within a gdb session, there is no automatic debugging feedback. After
|
||||
interrupting I can get a backtrace, here's an example:
|
||||
|
||||
Update: Maybe only reveals itself when compiled with GTK+
|
||||
|
||||
|
||||
* DOCUMENTATION
|
||||
|
||||
** Document Custom Themes.
|
||||
|
|
@ -272,11 +238,11 @@ etc/TUTORIAL.nl Lute Kamstra
|
|||
etc/TUTORIAL.pl
|
||||
etc/TUTORIAL.pt_BR Marcelo Toledo
|
||||
etc/TUTORIAL.ro
|
||||
etc/TUTORIAL.ru
|
||||
etc/TUTORIAL.sk
|
||||
etc/TUTORIAL.ru Alex Ott <alexott@gmail.com>
|
||||
etc/TUTORIAL.sk Pavel Janík <Pavel@Janik.cz>
|
||||
etc/TUTORIAL.sl Primoz PETERLIN <primoz.peterlin@biofiz.mf.uni-lj.si>
|
||||
etc/TUTORIAL.sv Mats Lidell <matsl@contactor.se>
|
||||
etc/TUTORIAL.th
|
||||
etc/TUTORIAL.th Virach Sornlertlamvanich <virach@tcllab.org>
|
||||
etc/TUTORIAL.zh
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
;;; admin.el --- utilities for Emacs administration
|
||||
|
||||
;; Copyright (C) 2001 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 2001, 2005 Free Software Foundation, Inc.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
|
|
@ -21,8 +21,8 @@
|
|||
|
||||
;;; Commentary:
|
||||
|
||||
;; add-release-log add ``Version X released'' change log entries
|
||||
;; set-version change Emacs version number in source tree.
|
||||
;; add-release-logs Add ``Version X released'' change log entries.
|
||||
;; set-version Change Emacs version number in source tree.
|
||||
|
||||
;;; Code:
|
||||
|
||||
|
|
@ -43,7 +43,6 @@ Signal an error if the program returns with a non-zero exit status."
|
|||
(forward-line 1))
|
||||
(nreverse lines)))))
|
||||
|
||||
|
||||
(defun add-release-logs (root version)
|
||||
"Add \"Version VERSION released.\" change log entries in ROOT.
|
||||
Root must be the root of an Emacs source tree."
|
||||
|
|
@ -51,8 +50,8 @@ Root must be the root of an Emacs source tree."
|
|||
(setq root (expand-file-name root))
|
||||
(unless (file-exists-p (expand-file-name "src/emacs.c" root))
|
||||
(error "%s doesn't seem to be the root of an Emacs source tree" root))
|
||||
(require 'add-log)
|
||||
(let* ((logs (process-lines "find" root "-name" "ChangeLog"))
|
||||
(require 'add-log)
|
||||
(entry (format "%s %s <%s>\n\n\t* Version %s released.\n\n"
|
||||
(funcall add-log-time-format)
|
||||
(or add-log-full-name (user-full-name))
|
||||
|
|
@ -64,7 +63,6 @@ Root must be the root of an Emacs source tree."
|
|||
(goto-char (point-min))
|
||||
(insert entry)))))
|
||||
|
||||
|
||||
(defun set-version-in-file (root file version rx)
|
||||
(find-file (expand-file-name file root))
|
||||
(goto-char (point-min))
|
||||
|
|
@ -72,7 +70,6 @@ Root must be the root of an Emacs source tree."
|
|||
(error "Version not found in %s" file))
|
||||
(replace-match (format "%s" version) nil nil nil 1))
|
||||
|
||||
|
||||
(defun set-version (root version)
|
||||
"Set Emacs version to VERSION in relevant files under ROOT.
|
||||
Root must be the root of an Emacs source tree."
|
||||
|
|
|
|||
|
|
@ -26,9 +26,14 @@ if not (%4) == () goto end
|
|||
|
||||
set eld=emacs-%1/lisp
|
||||
|
||||
rem Keep this list in sync with the DONTCOMPILE list in lisp/makefile.w32-in
|
||||
rem List of Lisp files that are not compiled and that should be
|
||||
rem included in the bin distribution.
|
||||
|
||||
set elfiles=%eld%/cus-load.el %eld%/cus-start.el %eld%/emacs-lisp/cl-specs.el %eld%/eshell/esh-maint.el %eld%/eshell/esh-groups.el %eld%/finder-inf.el %eld%/forms-d2.el %eld%/forms-pass.el %eld%/generic-x.el %eld%/international/latin-1.el %eld%/international/latin-2.el %eld%/international/latin-3.el %eld%/international/latin-4.el %eld%/international/latin-5.el %eld%/international/latin-8.el %eld%/international/latin-9.el %eld%/international/mule-conf.el %eld%/loaddefs.el %eld%/loadup.el %eld%/mail/blessmail.el %eld%/patcomp.el %eld%/paths.el %eld%/play/bruce.el %eld%/subdirs.el %eld%/version.el
|
||||
rem It would be better to generate this list automatically. It is the
|
||||
rem list of all .el files for which there is no corresponding .elc
|
||||
rem file, minus ldefs-boot.el. --lute
|
||||
|
||||
set elfiles=%eld%/cus-load.el %eld%/emacs-lisp/cl-specs.el %eld%/eshell/esh-groups.el %eld%/eshell/esh-maint.el %eld%/finder-inf.el %eld%/forms-d2.el %eld%/forms-pass.el %eld%/international/latin-1.el %eld%/international/latin-2.el %eld%/international/latin-3.el %eld%/international/latin-4.el %eld%/international/latin-5.el %eld%/international/latin-8.el %eld%/international/latin-9.el %eld%/international/mule-conf.el %eld%/language/czech.el %eld%/language/devanagari.el %eld%/language/english.el %eld%/language/georgian.el %eld%/language/greek.el %eld%/language/hebrew.el %eld%/language/japanese.el %eld%/language/kannada.el %eld%/language/korean.el %eld%/language/lao.el %eld%/language/malayalam.el %eld%/language/misc-lang.el %eld%/language/romanian.el %eld%/language/slovak.el %eld%/language/tamil.el %eld%/language/thai.el %eld%/language/utf-8-lang.el %eld%/loaddefs.el %eld%/loadup.el %eld%/mail/blessmail.el %eld%/mh-e/mh-acros.el %eld%/mh-e/mh-gnus.el %eld%/mh-e/mh-loaddefs.el %eld%/obsolete/keyswap.el %eld%/patcomp.el %eld%/paths.el %eld%/play/bruce.el %eld%/subdirs.el %eld%/term/AT386.el %eld%/term/apollo.el %eld%/term/bobcat.el %eld%/term/internal.el %eld%/term/iris-ansi.el %eld%/term/linux.el %eld%/term/lk201.el %eld%/term/news.el %eld%/term/vt102.el %eld%/term/vt125.el %eld%/term/vt200.el %eld%/term/vt201.el %eld%/term/vt220.el %eld%/term/vt240.el %eld%/term/vt300.el %eld%/term/vt320.el %eld%/term/vt400.el %eld%/term/vt420.el %eld%/term/wyse50.el %eld%/version.el
|
||||
|
||||
set fns_el=
|
||||
for %%f in (emacs-%1/bin/fns*) do set fns_el=%fns_el% emacs-%1/bin/%%f
|
||||
|
|
@ -42,7 +47,6 @@ for %%f in (emacs-%1/bin/fns*) do echo emacs-%1/bin/%%f>>#elfiles#
|
|||
for %%f in (emacs-%1/bin emacs-%1/etc emacs-%1/info emacs-%1/lisp) do echo %%f>>#files#
|
||||
for %%f in (emacs-%1/lock emacs-%1/site-lisp) do echo %%f>>#files#
|
||||
for %%f in (%elfiles% emacs-%1/site-lisp/subdirs.el) do echo %%f>>#elfiles#
|
||||
for %%f in (%eld%/term/*.el) do echo %eld%/term/%%f>>#elfiles#
|
||||
|
||||
%TAR% --exclude temacs.exe --exclude emacs.mdp --exclude *.pdb --exclude *.opt --exclude "*.el" --exclude "*~" -T #files# -cvf %2-bin-i386.tar
|
||||
%TAR% -T #elfiles# -rvf %2-bin-i386.tar
|
||||
|
|
|
|||
|
|
@ -1,3 +1,15 @@
|
|||
2005-04-13 Pavel Jan,Am(Bk <Pavel@Janik.cz>
|
||||
|
||||
* TUTORIAL.sk: Updated header.
|
||||
|
||||
2005-04-12 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
|
||||
* NEWS: Mention cursorBlink resource.
|
||||
|
||||
2005-04-12 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* NEWS: Mention dynamic change of keyboard-coding-system on Mac.
|
||||
|
||||
2005-04-10 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
|
||||
* NEWS: Mention fontSet for Lucid menus.
|
||||
|
|
|
|||
10
etc/NEWS
10
etc/NEWS
|
|
@ -351,11 +351,13 @@ the next/previous matching line found by M-x occur.
|
|||
+++
|
||||
** Telnet now prompts you for a port number with C-u M-x telnet.
|
||||
|
||||
+++
|
||||
** New command line option -Q or --quick.
|
||||
|
||||
This is like using -q --no-site-file, but in addition it also disables
|
||||
the fancy startup screen.
|
||||
|
||||
+++
|
||||
** New command line option -D or --basic-display.
|
||||
|
||||
Disables the menu-bar, the tool-bar, the scroll-bars, tool tips, and
|
||||
|
|
@ -965,6 +967,9 @@ speed up Emacs with slow networking to the X server.
|
|||
If the configure option `--without-xim' was used to turn off use of
|
||||
XIM by default, the X resource useXIM can be used to turn it on.
|
||||
|
||||
+++
|
||||
** The X resource cursorBlink can be used to turn off cursor blinking.
|
||||
|
||||
+++
|
||||
** `undo-only' does an undo which does not redo any previous undo.
|
||||
|
||||
|
|
@ -2449,6 +2454,11 @@ temporary overlay showing in the course of an isearch operation.
|
|||
** New command `recode-region' decodes the region again by a specified
|
||||
coding system.
|
||||
|
||||
** On Mac OS, the value of the variable `keyboard-coding-system' is
|
||||
now dynamically changed according to the current keyboard script. The
|
||||
variable `mac-keyboard-text-encoding' and the constants
|
||||
`kTextEncodingMacRoman', `kTextEncodingISOLatin1', and
|
||||
`kTextEncodingISOLatin2' are obsolete.
|
||||
|
||||
* New modes and packages in Emacs 22.1
|
||||
|
||||
|
|
|
|||
13
etc/TODO
13
etc/TODO
|
|
@ -22,6 +22,11 @@ to the FSF.
|
|||
** The buttons at the top of a custom buffer should not omit
|
||||
variables whose values are currently hidden.
|
||||
|
||||
** Clean up the variables in browse-url. Perhaps use a shell command string to
|
||||
specify the browser instead of the mushrooming set of functions.
|
||||
See also ESR's proposal for a BROWSER environment variable
|
||||
<URL:http://www.catb.org/~esr/BROWSER/browse-url.patch>.
|
||||
|
||||
* Important features:
|
||||
|
||||
** Provide user-friendly ways to list all available font families,
|
||||
|
|
@ -54,10 +59,10 @@ to the FSF.
|
|||
|
||||
** Make movemail work with IMAP.
|
||||
|
||||
** Internationalize Emacs's messages. [Note that this is of limited
|
||||
use until the menus can display multilingual text. It also doesn't
|
||||
address important issues like using the names of symbols essentially
|
||||
as documentation, e.g. in command names and Custom. -- fx]
|
||||
** Internationalize Emacs's messages.
|
||||
|
||||
** Address internationalization of symbols names essentially
|
||||
as documentation, e.g. in command names and Custom.
|
||||
|
||||
** Make the Lucid menu widget display multilingual text. [This
|
||||
probably needs to be done from actual Emacs buffers, either directly
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
ユ゙ナツホノヒ Emacs.
|
||||
Учебник Emacs. Условия распространения смотрите в конце файла
|
||||
Copyright (c) 1985, 1996, 2004 Free Software Foundation, Inc.
|
||||
|
||||
Для управления Emacs обычно используется ключ (сочетание клавиш клавиатуры
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
tútorial k Emacsu.
|
||||
Copyright (c) 1985 Free Software Foundation, Inc; podmienky pozri na konci.
|
||||
Tútorial k Emacsu. Podmienky pozri na konci.
|
||||
Copyright (c) 1985, 1996, 1998, 2001, 2002, 2005 Free Software Foundation.
|
||||
Do češtiny preložil Milan Zamazal <pdm@zamazal.org>, do slovenčiny Miroslav
|
||||
Vaško <zemiak@zoznam.sk>.
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
0,T7h1R9!S0EQ1'0HV1!IR0$Yh10AW1M!RCc0*i10MU1aA!0Jl1(B.
|
||||
0,T$Yh10AW1M!RCc0*i10MU1aA!0Jl1(B. ,Tb;C40HV1!IR0Jh1G907i1RB"M'0$Yh10AW1MJSK0CQ1:`0'Wh1M9d"c9!RC7SJS`9R(B.
|
||||
,TJ'G90ET1"0JT1708Tl1(B ,T>(B.,TH(B. 2528 ,Tb4B:0CT10IQ17?0CU1+M?05l1aG0Cl1?RG09l1`40*Q19(B (Free Software
|
||||
Foundation, Inc); ,T!0CX13R0HV1!IR`0'Wh1M9d"5M907i1RB:7(B.
|
||||
0,T7h1R9!S0EQ1'0HV1!IR0$Yh10AW1M!RCc0*i10MU1aA!0Jl1(B (Emacs tutorial) ,TM0BYh1c9"3P09Ui1(B.
|
||||
|
|
|
|||
361
lisp/ChangeLog
361
lisp/ChangeLog
|
|
@ -1,3 +1,357 @@
|
|||
2005-04-17 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* startup.el (command-line): No longer enable Xterm Mouse mode by
|
||||
default in terminals compatible with xterm.
|
||||
|
||||
* xt-mouse.el (xterm-mouse-mode): Set init value back to nil.
|
||||
|
||||
2005-04-18 Nick Roberts <nickrob@snap.net.nz>
|
||||
|
||||
* tooltip.el (tooltip-gud-echo-area): Rename from
|
||||
tooltip-use-echo-area.
|
||||
(tooltip-show, tooltip-gud-process-output, gdb-tooltip-print)
|
||||
(tooltip-help-tips): Allow GUD tooltips to be displayed in echo
|
||||
area independently of where help tooltips are displayed.
|
||||
|
||||
2005-04-17 David Kastrup <dak@gnu.org>
|
||||
|
||||
* cus-theme.el (custom-theme-write-variables): Quote variables
|
||||
where necessary.
|
||||
|
||||
2005-04-17 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* simple.el (yank-excluded-properties): Add follow-link to value.
|
||||
|
||||
* jka-compr.el (jka-compr-compression-info-list): Fix custom type.
|
||||
|
||||
* startup.el (fancy-splash-max-time): Just 30 seconds.
|
||||
(fancy-splash-delay): Just 7.
|
||||
(fancy-splash-screens): No time limit other than fancy-splash-max-time.
|
||||
|
||||
* loadhist.el (unload-feature): Update for new format of load-history.
|
||||
Simplify the code.
|
||||
|
||||
* mail/rmail.el (rmail-ignored-headers): Ignore more headers
|
||||
(rmail-font-lock-keywords): Don't fontify the text of a citation.
|
||||
|
||||
* mail/sendmail.el (mail-font-lock-keywords):
|
||||
Don't fontify subject text.
|
||||
Don't fontify the text of a citation.
|
||||
|
||||
2005-04-17 Mark H. Weaver <mhw@netris.org> (tiny change)
|
||||
|
||||
* comint.el (comint-output-filter): Run comint-output-filter-functions
|
||||
with point where the user had it.
|
||||
|
||||
2005-04-16 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* international/ucs-tables.el (ucs-set-table-for-input):
|
||||
Disable when using unify-on-decoding.
|
||||
|
||||
2005-04-16 Dan Nicolaescu <dann@ics.uci.edu>
|
||||
|
||||
* emulation/cua-base.el (cua-global-mark-face): Add special case
|
||||
for displays supporting a high number of colors.
|
||||
|
||||
2005-04-16 Matt Hodges <MPHodges@member.fsf.org> (tiny change)
|
||||
|
||||
* repeat.el (repeat): Invoke pre-command-hook and post-command-hook.
|
||||
|
||||
2005-04-16 Chong Yidong <cyd@stupidchicken.com>
|
||||
|
||||
* filesets.el (filesets-add-buffer): If user supplies a name of a
|
||||
non-existing fileset, create a new fileset.
|
||||
|
||||
2005-04-16 Carsten Dominik <dominik@science.uva.nl>
|
||||
|
||||
* textmodes/org.el (org-up-heading-all): Fix bug with
|
||||
`outline-up-heading-all'.
|
||||
|
||||
2005-04-16 Andreas Schwab <schwab@suse.de>
|
||||
|
||||
* files.el (auto-mode-alist): Handle /etc/sysconfig/*,
|
||||
/etc/permissions.d/* and /etc/aliases.d/*.
|
||||
|
||||
2005-04-16 Kenichi Handa <handa@m17n.org>
|
||||
|
||||
* international/code-pages.el (cp-make-coding-system):
|
||||
Set `translation-table-for-input' property value to the symbol
|
||||
ucs-mule-to-mule-unicode, not to that value.
|
||||
(pt154): Escape guillemet by `\'.
|
||||
|
||||
2005-04-15 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* loadup.el: Load tooltip if x-show-tip is fboundp.
|
||||
|
||||
* startup.el (command-line): Add comment.
|
||||
|
||||
* tooltip.el (tooltip-mode): Specify correct standard value for
|
||||
Custom in init-value.
|
||||
|
||||
2005-04-15 Nick Roberts <nickrob@snap.net.nz>
|
||||
|
||||
* progmodes/gud.el (gud-goto-info): Use existing Info buffer, if
|
||||
possible.
|
||||
|
||||
2005-04-15 Carsten Dominik <dominik@science.uva.nl>
|
||||
|
||||
* textmodes/org.el: (org-agenda-date-prompt): Rename from
|
||||
`org-agenda-date-today'.
|
||||
(org-evaluate-time-range): Insert at point instead of directly
|
||||
after time range.
|
||||
(org-first-headline-recenter, org-subtree-end-visible-p)
|
||||
(org-optimize-window-after-visibility-change): New functions
|
||||
(org-agenda-post-command-hook): Don't allow point at end of line,
|
||||
to make sure it always hits the text properties.
|
||||
(org-agenda-next-date-line, org-agenda-previous-date-line):
|
||||
New commands.
|
||||
(org-set-regexps-and-options): Category may contain white space.
|
||||
(org-agenda-get-deadlines, org-agenda-get-scheduled):
|
||||
Improve marker positions.
|
||||
(org-agenda-new-marker): Argument POS made optional.
|
||||
(org-agenda-get-timestamps): Deadlines which are done are listed
|
||||
in org-done-face now.
|
||||
(org-agenda-get-todos, org-agenda-get-timestamps)
|
||||
(org-agenda-get-deadlines, org-agenda-get-scheduled):
|
||||
Set `undone-face' and `done-face' properties.
|
||||
(org-last-todo-state-is-todo): New variable.
|
||||
(org-todo): Set `org-last-todo-state-is-todo'.
|
||||
(org-agenda-todo): Change face according to
|
||||
`org-last-todo-state-is-todo'. And change other lines refering to
|
||||
the same entry.
|
||||
(org-calendar-goto-agenda): New command.
|
||||
(org-calendar-to-agenda-key): New option.
|
||||
(org-startup-folded): New allowed value `content'.
|
||||
(org-set-regexps-and-options): Accept new value `content' for
|
||||
`org-startup-folded'.
|
||||
(org-get-current-options): Handle new value `content' for
|
||||
`org-startup-folded'.
|
||||
(org-insert-todo-heading): New command.
|
||||
(org-mode): Insert first line "*-* mode: org-mode -*-" when called
|
||||
interactively in empty file and option
|
||||
`org-insert-mode-line-in-empty-file' has been set.
|
||||
(org-agenda-todo,org-agenda-priority): Modify to use
|
||||
`org-agenda-change-all-lines'.
|
||||
(org-warning-face): Change color on dark background
|
||||
|
||||
2005-04-14 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* international/mule-cmds.el (set-locale-environment): On Mac OS,
|
||||
use preferences AppleLocale and AppleLanguages, and variable
|
||||
mac-system-locale for default locale. On Mac OS Classic, use
|
||||
mac-system-coding-system for default coding systems.
|
||||
|
||||
* term/mac-win.el: Don't set file-name-coding-system.
|
||||
Decode variables system-name, emacs-build-system, user-login-name, and
|
||||
user-full-name by mac-system-coding-system on Mac OS Classic.
|
||||
(mac-system-coding-system): New variable.
|
||||
|
||||
2005-04-13 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* startup.el (command-line): Handle `xterm-mouse-mode' before
|
||||
reading init file.
|
||||
|
||||
* xt-mouse.el (xterm-mouse-mode): Adapt to above change.
|
||||
|
||||
2005-04-13 Glenn Morris <gmorris@ast.cam.ac.uk>
|
||||
|
||||
* progmodes/sh-script.el (sh-here-document-word): Make it a
|
||||
defcustom. Doc fix.
|
||||
(sh-add): Bash uses $(( )) for arithmetic.
|
||||
(sh-while-getopts) <sh>: Set OPTIND back to 1 at end.
|
||||
(sh-maybe-here-document): Remove quotes and leading whitespace
|
||||
from heredoc word when closing. Indent heredoc with tabs if word
|
||||
starts with "-".
|
||||
|
||||
2005-04-13 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* simple.el (undo): Fix previous change.
|
||||
|
||||
* custom.el (defface): Doc fix.
|
||||
|
||||
2005-04-13 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* Makefile.in (DONTCOMPILE): Remove list.
|
||||
(compile, compile-always): Don't use DONTCOMPILE.
|
||||
(update-authors): Load the library in which batch-update-authors
|
||||
is defined.
|
||||
* makefile.w32-in (DONTCOMPILE): Remove list.
|
||||
(compile, compile-always): Fix comments.
|
||||
(update-authors): Load the library in which batch-update-authors
|
||||
is defined.
|
||||
|
||||
* generic-x.el (generic-mode-ini-file-find-file-hook):
|
||||
Rename to ini-generic-mode-find-file-hook.
|
||||
Keep generic-mode-ini-file-find-file-hook as an alias.
|
||||
(ini-generic-mode-find-file-hook): Rename from
|
||||
generic-mode-ini-file-find-file-hook. Fix docstring.
|
||||
(ini-generic-mode): Docstring change.
|
||||
(bat-generic-mode-run-as-comint): Silence the byte compiler.
|
||||
|
||||
* help.el (describe-key-briefly): UNTRANSLATED can be nil when
|
||||
called from lisp.
|
||||
|
||||
* generic.el: Move to the emacs-lisp subdir.
|
||||
|
||||
2005-04-12 Dan Nicolaescu <dann@ics.uci.edu>
|
||||
|
||||
* term/xterm.el (function-key-map): Add mappings for A-, C-, S-
|
||||
and C-S- function and cursor motion keys.
|
||||
|
||||
2005-04-12 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* startup.el (command-line): Enable Xterm Mouse mode by default.
|
||||
* xt-mouse.el (xterm-mouse-mode): Provide correct standard value
|
||||
for Custom. No longer show "Mouse" in mode line when enabled.
|
||||
Doc fix.
|
||||
|
||||
2005-04-12 Kim F. Storm <storm@cua.dk>
|
||||
|
||||
* emulation/cua-base.el (cua-rectangle-face)
|
||||
(cua-rectangle-noselect-face): Define face attributes here.
|
||||
|
||||
* emulation/cua-rect.el (cua--init-rectangles): Remove face setup.
|
||||
|
||||
2005-04-12 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
|
||||
* startup.el (command-line): Turn off blinking cursor if
|
||||
cursorBlink in resources is off or false.
|
||||
|
||||
2005-04-12 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* term/mac-win.el (dnd): Require dnd.
|
||||
(mac-drag-n-drop): Call dnd-handle-one-url.
|
||||
(kTextEncodingMacRoman, kTextEncodingISOLatin1)
|
||||
(kTextEncodingISOLatin2): Remove constants.
|
||||
(mac-script-code-coding-systems): New constant.
|
||||
(mac-handle-language-change): New function.
|
||||
(special-event-map): Bind it to `language-change' event.
|
||||
(mac-centraleurroman, mac-cyrillic): New coding systems.
|
||||
(mac-font-encoder-list, ccl-encode-mac-centraleurroman-font)
|
||||
(ccl-encode-mac-cyrillic-font): Rename mac-centraleurroman-encoder
|
||||
and mac-cyrillic-encoder to encode-mac-centraleurroman and
|
||||
encode-mac-cyrillic, respectively.
|
||||
|
||||
2005-04-12 Nick Roberts <nickrob@snap.net.nz>
|
||||
|
||||
* progmodes/gud.el, progmodes/gdb-ui.el (gdb-assembler-mode):
|
||||
Don't set overlay-arrow-string to "=>" as this is done
|
||||
globally in C now.
|
||||
|
||||
2005-04-12 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* generic-x.el (rc-generic-mode, rul-generic-mode):
|
||||
Fix auto-mode-alist entries.
|
||||
(etc-fstab-generic-mode): Tweak fontification.
|
||||
|
||||
* generic.el (generic-make-keywords-list): Fix docstring.
|
||||
(generic-mode-internal): Simplify generic-font-lock-keywords.
|
||||
|
||||
2005-04-11 Rajesh Vaidheeswarran <rv@gnu.org>
|
||||
|
||||
* whitespace.el (whitespace-buffer-leading)
|
||||
(whitespace-buffer-trailing): Revert the incorrect test
|
||||
inversion. However, fix the highlight area for the leading and
|
||||
trailing whitespaces to show space.
|
||||
|
||||
2005-04-11 Rajesh Vaidheeswarran <rv@gnu.org>
|
||||
|
||||
* whitespace.el (whitespace-version): Bump to 3.5
|
||||
|
||||
(whitespace-buffer-leading, whitespace-buffer-trailing):
|
||||
Invert sense of the test to highlight the whitespace.
|
||||
|
||||
2005-04-12 Nick Roberts <nickrob@snap.net.nz>
|
||||
|
||||
* progmodes/gud.el (gud-display-line): GUD uses its own
|
||||
overlay arrow now so don't set overlay-arrow-string.
|
||||
(gud-pdb-command-name): Revert back to "pdb" (2004-04-26).
|
||||
|
||||
2005-04-11 Dan Nicolaescu <dann@ics.uci.edu>
|
||||
|
||||
* term.el (term-ansi-current-bold, term-ansi-current-underline)
|
||||
(term-ansi-current-reverse, term-ansi-current-invisible)
|
||||
(term-ansi-face-already-done): Change to boolean.
|
||||
(term-reset-terminal, term-handle-colors-array): Handle the above
|
||||
vars accordingly.
|
||||
(term-buffer-vertical-motion): Rename from buffer-vertical-motion.
|
||||
(term-emulate-terminal): Use the new name.
|
||||
|
||||
* faces.el (secondary-selection): Use yellow1, not yellow.
|
||||
(trailing-whitespace): Use red1, not red.
|
||||
|
||||
2005-04-11 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
|
||||
* dired.el (dired-mode): Use dnd-* instead of x-dnd-*
|
||||
(dired-dnd-handle-local-file): Call dnd-get-local-file-name.
|
||||
(dired-dnd-handle-file): Call dnd-get-local-file-uri
|
||||
|
||||
* cus-edit.el (dnd): New group.
|
||||
|
||||
* term/w32-win.el (dnd): Require dnd
|
||||
(w32-drag-n-drop): Call dnd-handle-one-url.
|
||||
|
||||
* x-dnd.el: Require dnd.
|
||||
(x-dnd-handle-uri-list, x-dnd-handle-file-name):
|
||||
Call dnd-handle-one-url.
|
||||
(x-dnd-types-alist, x-dnd-insert-utf8-text)
|
||||
(x-dnd-insert-utf16-text, x-dnd-insert-ctext): Change x-dnd-insert-text
|
||||
to dnd-insert-text.
|
||||
(x-dnd-protocol-alist, x-dnd-open-file-other-window)
|
||||
(x-dnd-handle-one-url, x-dnd-get-local-file-uri)
|
||||
(x-dnd-get-local-file-name, x-dnd-open-local-file)
|
||||
(x-dnd-open-file, x-dnd-insert-text): Move to dnd.el (without x-).
|
||||
|
||||
* dnd.el (dnd-protocol-alist): New file with generic DND functions.
|
||||
|
||||
2005-04-11 JUAN-LEON Lahoz Garcia <juanleon1@gmail.com>
|
||||
|
||||
* wdired.el: Doc fixes.
|
||||
(wdired-confirm-overwrite): Rename from wdired-is-ok-overwrite.
|
||||
(wdired-use-dired-vertical-movement): Rename from
|
||||
wdired-always-move-to-filename-beginning.
|
||||
(wdired-mode-map): Use `ignore' instead of `wdired-newline'.
|
||||
(wdired-change-to-wdired-mode): Change mode name.
|
||||
(wdired-newline): Delete.
|
||||
|
||||
2005-04-11 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* whitespace.el (whitespace-highlight-the-space):
|
||||
Don't call whitespace-unhighlight-the-space here.
|
||||
|
||||
* simple.el (undo): Record t in undo-equiv-table
|
||||
for the redo record made by an undo-in-region.
|
||||
|
||||
2005-04-12 Nick Roberts <nickrob@snap.net.nz>
|
||||
|
||||
* progmodes/gdb-ui.el (gdb-display-inferior-io-buffer)
|
||||
(gdb-frame-inferior-io-buffer): New Functions to control
|
||||
display of separate IO buffer.
|
||||
(menu): Add them to menu-bar.
|
||||
(gdb-display-buffer): Check for buffer another frame.
|
||||
Protect GUD buffer.
|
||||
(gdb-setup-windows): Create IO buffer if not already there.
|
||||
(gdb-memory-mode): Remove purecopy noops.
|
||||
|
||||
2005-04-11 Glenn Morris <gmorris@ast.cam.ac.uk>
|
||||
|
||||
* progmodes/f90.el (f90-electric-insert): Add optional prefix arg,
|
||||
and pass to self-insert-command.
|
||||
|
||||
2005-04-11 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* generic.el: Commentary section cleanup.
|
||||
(generic): Delete.
|
||||
(generic-use-find-file-hook, generic-lines-to-scan)
|
||||
(generic-find-file-regexp, generic-ignore-files-regexp)
|
||||
(default-generic-mode, generic-mode-find-file-hook)
|
||||
(generic-mode-ini-file-find-file-hook): Move to generic-x.el.
|
||||
* generic-x.el (generic-x): Docstring fix. Put it in the data group.
|
||||
(generic-use-find-file-hook, generic-lines-to-scan)
|
||||
(generic-find-file-regexp, generic-ignore-files-regexp)
|
||||
(default-generic-mode, generic-mode-find-file-hook)
|
||||
(generic-mode-ini-file-find-file-hook): Move from generic.el.
|
||||
|
||||
2005-04-10 Karl Fogel <kfogel@red-bean.com>
|
||||
|
||||
* bookmark.el (bookmark-write-file): Catch errors writing file.
|
||||
|
|
@ -74,8 +428,8 @@
|
|||
|
||||
2005-04-09 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* help.el (describe-key-briefly, describe-key): Replace
|
||||
strings as event types with "(any string)".
|
||||
* help.el (describe-key-briefly, describe-key):
|
||||
Replace strings as event types with "(any string)".
|
||||
|
||||
2005-04-09 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
|
|
@ -188,8 +542,7 @@
|
|||
|
||||
2005-04-08 Kim F. Storm <storm@cua.dk>
|
||||
|
||||
* buff-menu.el (Buffer-menu-mode-map): Map follow-link to
|
||||
mouse-face.
|
||||
* buff-menu.el (Buffer-menu-mode-map): Map follow-link to mouse-face.
|
||||
|
||||
* mouse.el (mouse-on-link-p): Doc fix.
|
||||
|
||||
|
|
|
|||
115
lisp/Makefile.in
115
lisp/Makefile.in
|
|
@ -1,5 +1,5 @@
|
|||
# Maintenance productions for the Lisp directory
|
||||
# Copyright (C) 2000, 01, 03, 2004 Free Software Foundation, Inc.
|
||||
# Copyright (C) 2000, 2001, 2003, 2004, 2005 Free Software Foundation, Inc.
|
||||
|
||||
# This file is part of GNU Emacs.
|
||||
|
||||
|
|
@ -39,77 +39,6 @@ lisptagsfiles1 = $(lisp)/[a-zA-Z]*.el
|
|||
lisptagsfiles2 = $(lisp)/[a-zA-Z]*/[a-zA-Z]*.el
|
||||
ETAGS = ../lib-src/etags
|
||||
|
||||
# Files which should not be compiled. If you change the name `DONTCOMPILE'
|
||||
# to something different, you'll have to change make-dist as well, and
|
||||
# modify the lists in $lisp and $shortlisp on src/Makefile.in.
|
||||
#
|
||||
# - emacs-lisp/cl-specs.el: only contains `def-edebug-spec's so there's
|
||||
# no point compiling it, although it doesn't hurt.
|
||||
|
||||
DONTCOMPILE = \
|
||||
$(lisp)/cus-load.el \
|
||||
$(lisp)/emacs-lisp/cl-specs.el \
|
||||
$(lisp)/eshell/esh-maint.el \
|
||||
$(lisp)/eshell/esh-groups.el \
|
||||
$(lisp)/finder-inf.el \
|
||||
$(lisp)/forms-d2.el \
|
||||
$(lisp)/forms-pass.el \
|
||||
$(lisp)/generic-x.el \
|
||||
$(lisp)/international/latin-1.el \
|
||||
$(lisp)/international/latin-2.el \
|
||||
$(lisp)/international/latin-3.el \
|
||||
$(lisp)/international/latin-4.el \
|
||||
$(lisp)/international/latin-5.el \
|
||||
$(lisp)/international/latin-8.el \
|
||||
$(lisp)/international/latin-9.el \
|
||||
$(lisp)/international/mule-conf.el \
|
||||
$(lisp)/language/czech.el \
|
||||
$(lisp)/language/devanagari.el \
|
||||
$(lisp)/language/malayalam.el \
|
||||
$(lisp)/language/tamil.el \
|
||||
$(lisp)/language/kannada.el \
|
||||
$(lisp)/language/english.el \
|
||||
$(lisp)/language/greek.el \
|
||||
$(lisp)/language/hebrew.el \
|
||||
$(lisp)/language/japanese.el \
|
||||
$(lisp)/language/korean.el \
|
||||
$(lisp)/language/lao.el \
|
||||
$(lisp)/language/misc-lang.el \
|
||||
$(lisp)/language/romanian.el \
|
||||
$(lisp)/language/slovak.el \
|
||||
$(lisp)/language/thai.el \
|
||||
$(lisp)/language/utf-8-lang.el \
|
||||
$(lisp)/language/georgian.el \
|
||||
$(lisp)/loaddefs.el \
|
||||
$(lisp)/ldefs-boot.el \
|
||||
$(lisp)/loadup.el \
|
||||
$(lisp)/mail/blessmail.el \
|
||||
$(lisp)/patcomp.el \
|
||||
$(lisp)/paths.el \
|
||||
$(lisp)/play/bruce.el \
|
||||
$(lisp)/subdirs.el \
|
||||
$(lisp)/term/internal.el \
|
||||
$(lisp)/term/AT386.el \
|
||||
$(lisp)/term/apollo.el \
|
||||
$(lisp)/term/bobcat.el \
|
||||
$(lisp)/term/iris-ansi.el \
|
||||
$(lisp)/term/keyswap.el \
|
||||
$(lisp)/term/linux.el \
|
||||
$(lisp)/term/lk201.el \
|
||||
$(lisp)/term/news.el \
|
||||
$(lisp)/term/vt102.el \
|
||||
$(lisp)/term/vt125.el \
|
||||
$(lisp)/term/vt200.el \
|
||||
$(lisp)/term/vt201.el \
|
||||
$(lisp)/term/vt220.el \
|
||||
$(lisp)/term/vt240.el \
|
||||
$(lisp)/term/vt300.el \
|
||||
$(lisp)/term/vt320.el \
|
||||
$(lisp)/term/vt400.el \
|
||||
$(lisp)/term/vt420.el \
|
||||
$(lisp)/term/wyse50.el \
|
||||
$(lisp)/version.el
|
||||
|
||||
# Elisp files auto-generated.
|
||||
AUTOGENEL = loaddefs.el \
|
||||
cus-load.el \
|
||||
|
|
@ -192,7 +121,7 @@ updates: update-subdirs autoloads finder-data custom-deps
|
|||
# Update the AUTHORS file.
|
||||
|
||||
update-authors:
|
||||
$(emacs) -f batch-update-authors $(srcdir)/AUTHORS $(srcdir)
|
||||
$(emacs) -l authors -f batch-update-authors $(srcdir)/AUTHORS $(srcdir)
|
||||
|
||||
TAGS: $(lisptagsfiles1) $(lisptagsfiles2)
|
||||
els=`echo $(lisptagsfiles1) $(lisptagsfiles2) | sed -e "s,$(lisp)/loaddefs[^ ]*,," -e "s,$(lisp)/ldefs-boot[^ ]*,,"`; \
|
||||
|
|
@ -207,31 +136,23 @@ TAGS-LISP: $(lisptagsfiles1) $(lisptagsfiles2)
|
|||
.el.elc: $(lisp)/subdirs.el
|
||||
-$(emacs) -f batch-byte-compile $<
|
||||
|
||||
$(DONTCOMPILE:.el=.elc):
|
||||
-rm -f $@
|
||||
# Compile all Lisp files, but don't recompile those that are up to
|
||||
# date. Some files don't actually get compiled because they set the
|
||||
# local variable no-byte-compile.
|
||||
|
||||
# Compile all Lisp files, except those from DONTCOMPILE,
|
||||
# but don't recompile those that are up to date.
|
||||
|
||||
# All .elc files are made writable
|
||||
# before compilation in case we checked out read-only (CVS option -r).
|
||||
# Files MUST be compiled one by one. If we compile several files in a
|
||||
# row we can't make sure that the compilation environment is clean.
|
||||
# We also set the load-path of the Emacs used for compilation to the
|
||||
# current directory and its subdirectories, to make sure require's and
|
||||
# load's in the files being compiled find the right files.
|
||||
|
||||
# NOTE about DONTCOMPILE: in the `echo <foo> | sort | uniq -u' we pass
|
||||
# $(DONTCOMPILE) twice. This is in case one of the files in DONTCOMPILE
|
||||
# is absent. -stef
|
||||
# All .elc files are made writable before compilation in case we
|
||||
# checked out read-only (CVS option -r). Files MUST be compiled one by
|
||||
# one. If we compile several files in a row we can't make sure that
|
||||
# the compilation environment is clean. We also set the load-path of
|
||||
# the Emacs used for compilation to the current directory and its
|
||||
# subdirectories, to make sure require's and load's in the files being
|
||||
# compiled find the right files.
|
||||
|
||||
compile: $(lisp)/subdirs.el doit
|
||||
find $(lisp) -name "*.elc" -print | xargs chmod +w >/dev/null 2>&1; \
|
||||
wd=$(lisp); $(setwins); \
|
||||
elpat=`echo $$wins | tr ' ' '\012\012' | \
|
||||
els=`echo $$wins | tr ' \011' '\012\012' | \
|
||||
sed -e 's|\(.\)$$|\1/|' -e 's|^\./||' -e 's|$$|*.el|'`; \
|
||||
els=`echo $$elpat $(DONTCOMPILE) $(DONTCOMPILE) $(COMPILE_FIRST) | \
|
||||
tr ' ' '\012\012' | sort | uniq -u`; \
|
||||
for el in $(COMPILE_FIRST) $$els; do \
|
||||
if test -f $$el; \
|
||||
then \
|
||||
|
|
@ -240,17 +161,17 @@ compile: $(lisp)/subdirs.el doit
|
|||
fi \
|
||||
done
|
||||
|
||||
# Compile all Lisp files, except those from DONTCOMPILE. This
|
||||
# is like `compile' but compiles files unconditionally.
|
||||
# Compile all Lisp files. This is like `compile' but compiles files
|
||||
# unconditionally. Some files don't actually get compiled because they
|
||||
# set the local variable no-byte-compile.
|
||||
|
||||
compile-always: $(lisp)/subdirs.el doit
|
||||
# `|| true' prevents old Bash versions from getting confused
|
||||
# by an error.
|
||||
find $(lisp) -name "*.elc" -print | xargs chmod +w >/dev/null 2>&1 || true; \
|
||||
wd=$(lisp); $(setwins); \
|
||||
elpat=`echo $$wins | tr ' ' '\012\012' | \
|
||||
els=`echo $$wins | tr ' \011' '\012\012' | \
|
||||
sed -e 's|\(.\)$$|\1/|' -e 's|^\./||' -e 's|$$|*.el|'`; \
|
||||
els=`echo $$elpat $(DONTCOMPILE) $(DONTCOMPILE) $(COMPILE_FIRST) | \
|
||||
tr ' ' '\012\012' | sort | uniq -u`; \
|
||||
for el in $(COMPILE_FIRST) $$els; do \
|
||||
if test -f $$el; \
|
||||
then \
|
||||
|
|
|
|||
|
|
@ -1701,7 +1701,10 @@ Make backspaces delete the previous character."
|
|||
;; Interpret any carriage motion characters (newline, backspace)
|
||||
(comint-carriage-motion comint-last-output-start (point)))
|
||||
|
||||
;; Run these hooks with point where the user had it.
|
||||
(goto-char saved-point)
|
||||
(run-hook-with-args 'comint-output-filter-functions string)
|
||||
(set-marker saved-point (point))
|
||||
|
||||
(goto-char (process-mark process)) ; in case a filter moved it
|
||||
|
||||
|
|
|
|||
|
|
@ -433,6 +433,10 @@
|
|||
"Input from the menus."
|
||||
:group 'environment)
|
||||
|
||||
(defgroup dnd nil
|
||||
"Handling data from drag and drop."
|
||||
:group 'environment)
|
||||
|
||||
(defgroup auto-save nil
|
||||
"Preventing accidential loss of data."
|
||||
:group 'files)
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ It includes all variables in list VARS."
|
|||
(princ " '(")
|
||||
(prin1 symbol)
|
||||
(princ " ")
|
||||
(prin1 (symbol-value symbol))
|
||||
(prin1 (custom-quote (symbol-value symbol)))
|
||||
(princ ")")))
|
||||
vars)
|
||||
(if (bolp)
|
||||
|
|
|
|||
|
|
@ -287,9 +287,18 @@ The following KEYWORDs are defined:
|
|||
|
||||
SPEC should be an alist of the form ((DISPLAY ATTS)...).
|
||||
|
||||
The first element of SPEC where the DISPLAY matches the frame
|
||||
is the one that takes effect in that frame. The ATTRs in this
|
||||
element take effect; the other elements are ignored, on that frame.
|
||||
In the first element, DISPLAY can be :default. The ATTS in that
|
||||
element then act as defaults for all the following elements.
|
||||
|
||||
Aside from that, DISPLAY specifies conditions to match some or
|
||||
all frames. For each frame, the first element of SPEC where the
|
||||
DISPLAY conditions are satisfied is the one that applies to that
|
||||
frame. The ATTRs in this element take effect, and the following
|
||||
elements are ignored, on that frame.
|
||||
|
||||
In the last element, DISPLAY can be t. That element applies to a
|
||||
frame if none of the previous elements (except the :default if
|
||||
any) did.
|
||||
|
||||
ATTS is a list of face attributes followed by their values:
|
||||
(ATTR VALUE ATTR VALUE...)
|
||||
|
|
@ -298,11 +307,12 @@ The possible attributes are `:family', `:width', `:height', `:weight',
|
|||
`:slant', `:underline', `:overline', `:strike-through', `:box',
|
||||
`:foreground', `:background', `:stipple', `:inverse-video', and `:inherit'.
|
||||
|
||||
DISPLAY can either be the symbol t, which will match all frames, or an
|
||||
alist of elements of the form \(REQ ITEM...). For the DISPLAY to match a
|
||||
FRAME, each of these elements must be satisfied, meaning that the
|
||||
REQ property of the frame must match one of the corresponding ITEMs.
|
||||
These are the defined REQ values:
|
||||
DISPLAY can be `:default' (only in the first element), the symbol
|
||||
t (only in the last element) to match all frames, or an alist of
|
||||
conditions of the form \(REQ ITEM...). For such an alist to
|
||||
match a frame, each of the conditions must be satisfied, meaning
|
||||
that the REQ property of the frame must match one of the
|
||||
corresponding ITEMs. These are the defined REQ values:
|
||||
|
||||
`type' (the value of `window-system')
|
||||
Under X, in addition to the values `window-system' can take,
|
||||
|
|
|
|||
|
|
@ -1523,15 +1523,13 @@ Keybindings:
|
|||
(setq dired-switches-alist nil)
|
||||
(dired-sort-other dired-actual-switches t)
|
||||
(run-mode-hooks 'dired-mode-hook)
|
||||
(when (featurep 'x-dnd)
|
||||
(make-variable-buffer-local 'x-dnd-test-function)
|
||||
(make-variable-buffer-local 'x-dnd-protocol-alist)
|
||||
(setq x-dnd-test-function 'dired-dnd-test-function)
|
||||
(setq x-dnd-protocol-alist
|
||||
(when (featurep 'dnd)
|
||||
(make-variable-buffer-local 'dnd-protocol-alist)
|
||||
(setq dnd-protocol-alist
|
||||
(append '(("^file:///" . dired-dnd-handle-local-file)
|
||||
("^file://" . dired-dnd-handle-file)
|
||||
("^file:" . dired-dnd-handle-local-file))
|
||||
x-dnd-protocol-alist))))
|
||||
dnd-protocol-alist))))
|
||||
|
||||
;; Idiosyncratic dired commands that don't deal with marks.
|
||||
|
||||
|
|
@ -3136,18 +3134,6 @@ Anything else means ask for each directory."
|
|||
(const :tag "Copy directories without asking" always))
|
||||
:group 'dired)
|
||||
|
||||
(defun dired-dnd-test-function (window action types)
|
||||
"The test function for drag and drop into dired buffers.
|
||||
WINDOW is where the mouse is when this function is called. It may be a frame
|
||||
if the mouse is over the menu bar, scroll bar or tool bar.
|
||||
ACTION is the suggested action from the source, and TYPES are the
|
||||
types the drop data can have. This function only accepts drops with
|
||||
types in `x-dnd-known-types'. It returns the action suggested by the source."
|
||||
(let ((type (x-dnd-choose-type types)))
|
||||
(if type
|
||||
(cons action type)
|
||||
nil)))
|
||||
|
||||
(defun dired-dnd-popup-notice ()
|
||||
(x-popup-dialog
|
||||
t
|
||||
|
|
@ -3176,7 +3162,7 @@ types in `x-dnd-known-types'. It returns the action suggested by the source."
|
|||
URI is the file to handle, ACTION is one of copy, move, link or ask.
|
||||
Ask means pop up a menu for the user to select one of copy, move or link."
|
||||
(require 'dired-aux)
|
||||
(let* ((from (x-dnd-get-local-file-name uri t))
|
||||
(let* ((from (dnd-get-local-file-name uri t))
|
||||
(to (if from (concat (dired-current-directory)
|
||||
(file-name-nondirectory from))
|
||||
nil)))
|
||||
|
|
@ -3214,7 +3200,7 @@ Ask means pop up a menu for the user to select one of copy, move or link."
|
|||
URI is the file to handle. If the hostname in the URI isn't local, do nothing.
|
||||
ACTION is one of copy, move, link or ask.
|
||||
Ask means pop up a menu for the user to select one of copy, move or link."
|
||||
(let ((local-file (x-dnd-get-local-file-uri uri)))
|
||||
(let ((local-file (dnd-get-local-file-uri uri)))
|
||||
(if local-file (dired-dnd-handle-local-file local-file action)
|
||||
nil)))
|
||||
|
||||
|
|
|
|||
192
lisp/dnd.el
Normal file
192
lisp/dnd.el
Normal file
|
|
@ -0,0 +1,192 @@
|
|||
;;; dnd.el --- drag and drop support.
|
||||
|
||||
;; Copyright (C) 2005
|
||||
;; Free Software Foundation, Inc.
|
||||
|
||||
;; Author: Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
;; Maintainer: FSF
|
||||
;; Keywords: window, drag, drop
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software; you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation; either version 2, or (at your option)
|
||||
;; any later version.
|
||||
|
||||
;; GNU Emacs is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with GNU Emacs; see the file COPYING. If not, write to the
|
||||
;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
;; Boston, MA 02111-1307, USA.
|
||||
|
||||
;;; Commentary:
|
||||
|
||||
;; This file provides the generic handling of the drop part only.
|
||||
;; Different DND backends (X11, W32, etc.) that handle the platform
|
||||
;; specific DND parts call the functions here to do final delivery of
|
||||
;; a drop.
|
||||
|
||||
;;; Code:
|
||||
|
||||
;;; Customizable variables
|
||||
|
||||
|
||||
(defcustom dnd-protocol-alist
|
||||
'(
|
||||
("^file:///" . dnd-open-local-file) ; XDND format.
|
||||
("^file://" . dnd-open-file) ; URL with host
|
||||
("^file:" . dnd-open-local-file) ; Old KDE, Motif, Sun
|
||||
)
|
||||
|
||||
"The functions to call for different protocols when a drop is made.
|
||||
This variable is used by `dnd-handle-one-url' and `dnd-handle-file-name'.
|
||||
The list contains of (REGEXP . FUNCTION) pairs.
|
||||
The functions shall take two arguments, URL, which is the URL dropped and
|
||||
ACTION which is the action to be performed for the drop (move, copy, link,
|
||||
private or ask).
|
||||
If no match is found here, and the value of `browse-url-browser-function'
|
||||
is a pair of (REGEXP . FUNCTION), those regexps are tried for a match.
|
||||
If no match is found, the URL is inserted as text by calling `dnd-insert-text'.
|
||||
The function shall return the action done (move, copy, link or private)
|
||||
if some action was made, or nil if the URL is ignored."
|
||||
:version "22.1"
|
||||
:type 'alist
|
||||
:group 'dnd)
|
||||
|
||||
|
||||
|
||||
(defcustom dnd-open-file-other-window nil
|
||||
"If non-nil, always use find-file-other-window to open dropped files."
|
||||
:version "22.1"
|
||||
:type 'boolean
|
||||
:group 'dnd)
|
||||
|
||||
|
||||
;; Functions
|
||||
|
||||
(defun dnd-handle-one-url (window action arg)
|
||||
"Handle one dropped url by calling the appropriate handler.
|
||||
The handler is first located by looking at `dnd-protocol-alist'.
|
||||
If no match is found here, and the value of `browse-url-browser-function'
|
||||
is a pair of (REGEXP . FUNCTION), those regexps are tried for a match.
|
||||
If no match is found, just call `dnd-insert-text'.
|
||||
WINDOW is where the drop happend, ACTION is the action for the drop,
|
||||
ARG is the URL that has been dropped.
|
||||
Returns ACTION."
|
||||
(require 'browse-url)
|
||||
(let* ((uri (replace-regexp-in-string
|
||||
"%[A-Z0-9][A-Z0-9]"
|
||||
(lambda (arg)
|
||||
(format "%c" (string-to-number (substring arg 1) 16)))
|
||||
arg))
|
||||
ret)
|
||||
(or
|
||||
(catch 'done
|
||||
(dolist (bf dnd-protocol-alist)
|
||||
(when (string-match (car bf) uri)
|
||||
(setq ret (funcall (cdr bf) uri action))
|
||||
(throw 'done t)))
|
||||
nil)
|
||||
(when (not (functionp browse-url-browser-function))
|
||||
(catch 'done
|
||||
(dolist (bf browse-url-browser-function)
|
||||
(when (string-match (car bf) uri)
|
||||
(setq ret 'private)
|
||||
(funcall (cdr bf) uri action)
|
||||
(throw 'done t)))
|
||||
nil))
|
||||
(progn
|
||||
(dnd-insert-text window action uri)
|
||||
(setq ret 'private)))
|
||||
ret))
|
||||
|
||||
|
||||
(defun dnd-get-local-file-uri (uri)
|
||||
"Return an uri converted to file:/// syntax if uri is a local file.
|
||||
Return nil if URI is not a local file."
|
||||
|
||||
;; The hostname may be our hostname, in that case, convert to a local
|
||||
;; file. Otherwise return nil. TODO: How about an IP-address as hostname?
|
||||
(let ((hostname (when (string-match "^file://\\([^/]*\\)" uri)
|
||||
(downcase (match-string 1 uri))))
|
||||
(system-name-no-dot
|
||||
(downcase (if (string-match "^[^\\.]+" system-name)
|
||||
(match-string 0 system-name)
|
||||
system-name))))
|
||||
(when (and hostname
|
||||
(or (string-equal "localhost" hostname)
|
||||
(string-equal (downcase system-name) hostname)
|
||||
(string-equal system-name-no-dot hostname)))
|
||||
(concat "file://" (substring uri (+ 7 (length hostname)))))))
|
||||
|
||||
(defun dnd-get-local-file-name (uri &optional must-exist)
|
||||
"Return file name converted from file:/// or file: syntax.
|
||||
URI is the uri for the file. If MUST-EXIST is given and non-nil,
|
||||
only return non-nil if the file exists.
|
||||
Return nil if URI is not a local file."
|
||||
(let ((f (cond ((string-match "^file:///" uri) ; XDND format.
|
||||
(substring uri (1- (match-end 0))))
|
||||
((string-match "^file:" uri) ; Old KDE, Motif, Sun
|
||||
(substring uri (match-end 0))))))
|
||||
(when (and f must-exist)
|
||||
(let* ((decoded-f (decode-coding-string
|
||||
f
|
||||
(or file-name-coding-system
|
||||
default-file-name-coding-system)))
|
||||
(try-f (if (file-readable-p decoded-f) decoded-f f)))
|
||||
(when (file-readable-p try-f) try-f)))))
|
||||
|
||||
|
||||
(defun dnd-open-local-file (uri action)
|
||||
"Open a local file.
|
||||
The file is opened in the current window, or a new window if
|
||||
`dnd-open-file-other-window' is set. URI is the url for the file,
|
||||
and must have the format file:file-name or file:///file-name.
|
||||
The last / in file:/// is part of the file name. ACTION is ignored."
|
||||
|
||||
(let* ((f (dnd-get-local-file-name uri t)))
|
||||
(if (and f (file-readable-p f))
|
||||
(progn
|
||||
(if dnd-open-file-other-window
|
||||
(find-file-other-window f)
|
||||
(find-file f))
|
||||
'private)
|
||||
(error "Can not read %s" uri))))
|
||||
|
||||
(defun dnd-open-file (uri action)
|
||||
"Open a local or remote file.
|
||||
The file is opened in the current window, or a new window if
|
||||
`dnd-open-file-other-window' is set. URI is the url for the file,
|
||||
and must have the format file://hostname/file-name. ACTION is ignored.
|
||||
The last / in file://hostname/ is part of the file name."
|
||||
|
||||
;; The hostname may be our hostname, in that case, convert to a local
|
||||
;; file. Otherwise return nil.
|
||||
(let ((local-file (dnd-get-local-file-uri uri)))
|
||||
(if local-file (dnd-open-local-file local-file action)
|
||||
(error "Remote files not supported"))))
|
||||
|
||||
|
||||
(defun dnd-insert-text (window action text)
|
||||
"Insert text at point or push to the kill ring if buffer is read only.
|
||||
TEXT is the text as a string, WINDOW is the window where the drop happened."
|
||||
(if (or buffer-read-only
|
||||
(not (windowp window)))
|
||||
(progn
|
||||
(kill-new text)
|
||||
(message
|
||||
(substitute-command-keys
|
||||
"The dropped text can be accessed with \\[yank]")))
|
||||
(insert text))
|
||||
action)
|
||||
|
||||
|
||||
(provide 'dnd)
|
||||
|
||||
;; arch-tag: 0472f6a5-2e8f-4304-9e44-1a0877c771b7
|
||||
;;; dnd.el ends here
|
||||
|
|
@ -23,16 +23,11 @@
|
|||
;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
;; Boston, MA 02111-1307, USA.
|
||||
|
||||
;; Purpose:
|
||||
|
||||
;; Meta-mode to create simple major modes
|
||||
;; with basic comment and font-lock support
|
||||
|
||||
;;; Commentary:
|
||||
|
||||
;; INTRODUCTION:
|
||||
|
||||
;; Generic-mode is a meta-mode which can be used to define small modes
|
||||
;;
|
||||
;; The macro `define-generic-mode' can be used to define small modes
|
||||
;; which provide basic comment and font-lock support. These modes are
|
||||
;; intended for the many configuration files and such which are too
|
||||
;; small for a "real" mode, but still have a regular syntax, comment
|
||||
|
|
@ -68,20 +63,9 @@
|
|||
;; more than this, or you find yourself writing extensive customizations,
|
||||
;; perhaps you should be writing a major mode instead!
|
||||
;;
|
||||
;; LOCAL VARIABLES:
|
||||
;; EXAMPLE:
|
||||
;;
|
||||
;; To put a file into generic mode using local variables, use a line
|
||||
;; like this in a Local Variables block:
|
||||
;;
|
||||
;; mode: default-generic
|
||||
;;
|
||||
;; Do NOT use "mode: generic"!
|
||||
;; See also "AUTOMATICALLY ENTERING GENERIC MODE" below.
|
||||
;;
|
||||
;; DEFINING NEW GENERIC MODES:
|
||||
;;
|
||||
;; Use the `define-generic-mode' function to define new modes.
|
||||
;; For example:
|
||||
;; You can use `define-generic-mode' like this:
|
||||
;;
|
||||
;; (define-generic-mode 'foo-generic-mode
|
||||
;; (list ?%)
|
||||
|
|
@ -90,35 +74,24 @@
|
|||
;; (list "\\.FOO\\'")
|
||||
;; (list 'foo-setup-function))
|
||||
;;
|
||||
;; defines a new generic-mode `foo-generic-mode', which has '%' as a
|
||||
;; to define a new generic-mode `foo-generic-mode', which has '%' as a
|
||||
;; comment character, and "keyword" as a keyword. When files which
|
||||
;; end in '.FOO' are loaded, Emacs will go into foo-generic-mode and
|
||||
;; call foo-setup-function. You can also use the function
|
||||
;; `foo-generic-mode' (which is interactive) to put a buffer into
|
||||
;; foo-generic-mode.
|
||||
;;
|
||||
;; AUTOMATICALLY ENTERING GENERIC MODE:
|
||||
;;
|
||||
;; Generic-mode provides a hook which automatically puts a file into
|
||||
;; default-generic-mode if the first few lines of a file in
|
||||
;; fundamental mode start with a hash comment character. To disable
|
||||
;; this functionality, set the variable `generic-use-find-file-hook'
|
||||
;; to nil BEFORE loading generic-mode. See the variables
|
||||
;; `generic-lines-to-scan' and `generic-find-file-regexp' for
|
||||
;; customization options.
|
||||
;;
|
||||
;; GOTCHAS:
|
||||
;;
|
||||
;; Be careful that your font-lock definitions are correct. Getting
|
||||
;; them wrong can cause Emacs to continually attempt to fontify! This
|
||||
;; problem is not specific to generic-mode.
|
||||
;;
|
||||
|
||||
;; Credit for suggestions, brainstorming, help with debugging:
|
||||
;; ACorreir@pervasive-sw.com (Alfred Correira)
|
||||
;; Extensive cleanup by:
|
||||
;; Stefan Monnier (monnier+gnu/emacs@flint.cs.yale.edu)
|
||||
;;
|
||||
|
||||
;;; Code:
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
|
@ -137,47 +110,6 @@
|
|||
Do not add entries to this list directly; use `define-generic-mode'
|
||||
instead (which see).")
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Customization Variables
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(defgroup generic nil
|
||||
"Define simple major modes with comment and font-lock support."
|
||||
:prefix "generic-"
|
||||
:group 'extensions)
|
||||
|
||||
(defcustom generic-use-find-file-hook t
|
||||
"*If non-nil, add a hook to enter `default-generic-mode' automatically.
|
||||
This is done if the first few lines of a file in fundamental mode
|
||||
start with a hash comment character."
|
||||
:group 'generic
|
||||
:type 'boolean)
|
||||
|
||||
(defcustom generic-lines-to-scan 3
|
||||
"*Number of lines that `generic-mode-find-file-hook' looks at.
|
||||
Relevant when deciding whether to enter Default-Generic mode automatically.
|
||||
This variable should be set to a small positive number."
|
||||
:group 'generic
|
||||
:type 'integer)
|
||||
|
||||
(defcustom generic-find-file-regexp "^#"
|
||||
"*Regular expression used by `generic-mode-find-file-hook'.
|
||||
Files in fundamental mode whose first few lines contain a match
|
||||
for this regexp, should be put into Default-Generic mode instead.
|
||||
The number of lines tested for the matches is specified by the
|
||||
value of the variable `generic-lines-to-scan', which see."
|
||||
:group 'generic
|
||||
:type 'regexp)
|
||||
|
||||
(defcustom generic-ignore-files-regexp "[Tt][Aa][Gg][Ss]\\'"
|
||||
"*Regular expression used by `generic-mode-find-file-hook'.
|
||||
Files whose names match this regular expression should not be put
|
||||
into Default-Generic mode, even if they have lines which match
|
||||
the regexp in `generic-find-file-regexp'. If the value is nil,
|
||||
`generic-mode-find-file-hook' does not check the file names."
|
||||
:group 'generic
|
||||
:type '(choice (const :tag "Don't check file names" nil) regexp))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Functions
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
|
@ -290,12 +222,10 @@ See the file generic-x.el for some examples of `define-generic-mode'."
|
|||
;; Font-lock functionality.
|
||||
;; Font-lock-defaults is always set even if there are no keywords
|
||||
;; or font-lock expressions, so comments can be highlighted.
|
||||
(setq generic-font-lock-keywords
|
||||
(append
|
||||
(when keyword-list
|
||||
(list (generic-make-keywords-list keyword-list
|
||||
font-lock-keyword-face)))
|
||||
font-lock-list))
|
||||
(setq generic-font-lock-keywords font-lock-list)
|
||||
(when keyword-list
|
||||
(push (concat "\\_<" (regexp-opt keyword-list t) "\\_>")
|
||||
generic-font-lock-keywords))
|
||||
(setq font-lock-defaults '(generic-font-lock-keywords nil))
|
||||
|
||||
;; Call a list of functions
|
||||
|
|
@ -391,60 +321,20 @@ Some generic modes are defined in `generic-x.el'."
|
|||
'((nil "^\\[\\(.*\\)\\]" 1))
|
||||
imenu-case-fold-search t))
|
||||
|
||||
;; This generic mode is always defined
|
||||
(define-generic-mode default-generic-mode (list ?#) nil nil nil nil :group 'generic)
|
||||
|
||||
;; A more general solution would allow us to enter generic-mode for
|
||||
;; *any* comment character, but would require us to synthesize a new
|
||||
;; generic-mode on the fly. I think this gives us most of what we
|
||||
;; want.
|
||||
(defun generic-mode-find-file-hook ()
|
||||
"Hook function to enter Default-Generic mode automatically.
|
||||
|
||||
Done if the first few lines of a file in Fundamental mode start
|
||||
with a match for the regexp in `generic-find-file-regexp', unless
|
||||
the file's name matches the regexp which is the value of the
|
||||
variable `generic-ignore-files-regexp'.
|
||||
|
||||
This hook will be installed if the variable
|
||||
`generic-use-find-file-hook' is non-nil. The variable
|
||||
`generic-lines-to-scan' determines the number of lines to look at."
|
||||
(when (and (eq major-mode 'fundamental-mode)
|
||||
(or (null generic-ignore-files-regexp)
|
||||
(not (string-match
|
||||
generic-ignore-files-regexp
|
||||
(file-name-sans-versions buffer-file-name)))))
|
||||
(save-excursion
|
||||
(goto-char (point-min))
|
||||
(when (re-search-forward generic-find-file-regexp
|
||||
(save-excursion
|
||||
(forward-line generic-lines-to-scan)
|
||||
(point)) t)
|
||||
(goto-char (point-min))
|
||||
(default-generic-mode)))))
|
||||
|
||||
(defun generic-mode-ini-file-find-file-hook ()
|
||||
"Hook function to enter Default-Generic mode automatically for INI files.
|
||||
Done if the first few lines of a file in Fundamental mode look like an
|
||||
INI file. This hook is NOT installed by default."
|
||||
(and (eq major-mode 'fundamental-mode)
|
||||
(save-excursion
|
||||
(goto-char (point-min))
|
||||
(and (looking-at "^\\s-*\\[.*\\]")
|
||||
(ini-generic-mode)))))
|
||||
|
||||
(and generic-use-find-file-hook
|
||||
(add-hook 'find-file-hook 'generic-mode-find-file-hook))
|
||||
|
||||
;;;###autoload
|
||||
(defun generic-make-keywords-list (keywords-list face &optional prefix suffix)
|
||||
"Return a regular expression matching the specified KEYWORDS-LIST.
|
||||
The regexp is highlighted with FACE."
|
||||
(unless (listp keywords-list)
|
||||
(defun generic-make-keywords-list (keyword-list face &optional prefix suffix)
|
||||
"Return a `font-lock-keywords' construct that highlights KEYWORD-LIST.
|
||||
KEYWORD-LIST is a list of keyword strings that should be
|
||||
highlighted with face FACE. This function calculates a regular
|
||||
expression that matches these keywords and concatenates it with
|
||||
PREFIX and SUFFIX. Then it returns a construct based on this
|
||||
regular expression that can be used as an element of
|
||||
`font-lock-keywords'."
|
||||
(unless (listp keyword-list)
|
||||
(error "Keywords argument must be a list of strings"))
|
||||
(list (concat prefix "\\_<"
|
||||
;; Use an optimized regexp.
|
||||
(regexp-opt keywords-list t)
|
||||
(regexp-opt keyword-list t)
|
||||
"\\_>" suffix)
|
||||
1
|
||||
face))
|
||||
|
|
@ -384,11 +384,15 @@ and after the region marked by the rectangle to search."
|
|||
:type 'boolean
|
||||
:group 'cua)
|
||||
|
||||
(defface cua-rectangle-face 'nil
|
||||
(defface cua-rectangle-face
|
||||
'((default :inherit region)
|
||||
(((class color)) :foreground "white" :background "maroon"))
|
||||
"*Font used by CUA for highlighting the rectangle."
|
||||
:group 'cua)
|
||||
|
||||
(defface cua-rectangle-noselect-face 'nil
|
||||
(defface cua-rectangle-noselect-face
|
||||
'((default :inherit region)
|
||||
(((class color)) :foreground "white" :background "dimgray"))
|
||||
"*Font used by CUA for highlighting the non-selected rectangle lines."
|
||||
:group 'cua)
|
||||
|
||||
|
|
@ -400,10 +404,10 @@ and after the region marked by the rectangle to search."
|
|||
:type 'boolean
|
||||
:group 'cua)
|
||||
|
||||
(defface cua-global-mark-face '((((class color))
|
||||
:foreground "black"
|
||||
:background "yellow")
|
||||
(t :bold t))
|
||||
(defface cua-global-mark-face
|
||||
'((((min-colors 88)(class color)) :foreground "black" :background "yellow1")
|
||||
(((class color)) :foreground "black" :background "yellow")
|
||||
(t :bold t))
|
||||
"*Font used by CUA for highlighting the global mark."
|
||||
:group 'cua)
|
||||
|
||||
|
|
|
|||
|
|
@ -1402,16 +1402,6 @@ With prefix arg, indent to that column."
|
|||
(cua--M/H-key cua--rectangle-keymap key cmd))
|
||||
|
||||
(defun cua--init-rectangles ()
|
||||
(unless (face-background 'cua-rectangle-face)
|
||||
(copy-face 'region 'cua-rectangle-face)
|
||||
(set-face-background 'cua-rectangle-face "maroon")
|
||||
(set-face-foreground 'cua-rectangle-face "white"))
|
||||
|
||||
(unless (face-background 'cua-rectangle-noselect-face)
|
||||
(copy-face 'region 'cua-rectangle-noselect-face)
|
||||
(set-face-background 'cua-rectangle-noselect-face "dimgray")
|
||||
(set-face-foreground 'cua-rectangle-noselect-face "white"))
|
||||
|
||||
(unless (eq cua-use-hyper-key 'only)
|
||||
(define-key cua--rectangle-keymap [(shift return)] 'cua-clear-rectangle-mark)
|
||||
(define-key cua--region-keymap [(shift return)] 'cua-toggle-rectangle-mark))
|
||||
|
|
|
|||
|
|
@ -2045,7 +2045,7 @@ Note: Other faces cannot inherit from the cursor face."
|
|||
|
||||
(defface secondary-selection
|
||||
'((((class color) (min-colors 88) (background light))
|
||||
:background "yellow")
|
||||
:background "yellow1")
|
||||
(((class color) (min-colors 88) (background dark))
|
||||
:background "SkyBlue4")
|
||||
(((class color) (min-colors 16) (background light))
|
||||
|
|
@ -2071,9 +2071,9 @@ Note: Other faces cannot inherit from the cursor face."
|
|||
|
||||
(defface trailing-whitespace
|
||||
'((((class color) (background light))
|
||||
:background "red")
|
||||
:background "red1")
|
||||
(((class color) (background dark))
|
||||
:background "red")
|
||||
:background "red1")
|
||||
(t :inverse-video t))
|
||||
"Basic face for highlighting trailing whitespace."
|
||||
:version "21.1"
|
||||
|
|
|
|||
|
|
@ -1844,8 +1844,8 @@ in that case, this function acts as if `enable-local-variables' were t."
|
|||
("\\.properties\\(?:\\.[a-zA-Z0-9._-]+\\)?\\'" . conf-javaprop-mode)
|
||||
;; *.cf, *.cfg, *.conf, *.config[.local|.de_DE.UTF8|...], */config
|
||||
("[/.]c\\(?:on\\)?f\\(?:i?g\\)?\\(?:\\.[a-zA-Z0-9._-]+\\)?\\'" . conf-mode)
|
||||
("\\`/etc/\\(?:DIR_COLORS\\|ethers\\|.?fstab\\|.*hosts\\|lesskey\\|login\\.?de\\(?:fs\\|vperm\\)\\|magic\\|mtab\\|pam\\.d/.*\\|permissions\\|protocols\\|rpc\\|services\\)\\'" . conf-space-mode)
|
||||
("\\`/etc/\\(?:acpid?/.+\\|aliases\\|default/.+\\|group-?\\|hosts\\..+\\|inittab\\|ksysguarddrc\\|opera6rc\\|passwd-?\\|shadow-?\\)\\'" . conf-mode)
|
||||
("\\`/etc/\\(?:DIR_COLORS\\|ethers\\|.?fstab\\|.*hosts\\|lesskey\\|login\\.?de\\(?:fs\\|vperm\\)\\|magic\\|mtab\\|pam\\.d/.*\\|permissions\\(?:\\.d/.+\\)?\\|protocols\\|rpc\\|services\\)\\'" . conf-space-mode)
|
||||
("\\`/etc/\\(?:acpid?/.+\\|aliases\\(?:\\.d/.+\\)?\\|default/.+\\|group-?\\|hosts\\..+\\|inittab\\|ksysguarddrc\\|opera6rc\\|passwd-?\\|shadow-?\\|sysconfig/.+\\)\\'" . conf-mode)
|
||||
;; either user's dot-files or under /etc or some such
|
||||
("/\\.?\\(?:gnokiirc\\|kde.*rc\\|mime\\.types\\|wgetrc\\)\\'" . conf-mode)
|
||||
;; alas not all ~/.*rc files are like this
|
||||
|
|
|
|||
|
|
@ -1794,8 +1794,17 @@ User will be queried, if no fileset name is provided."
|
|||
(name (or name
|
||||
(completing-read
|
||||
(format "Add '%s' to fileset: " buffer)
|
||||
filesets-data nil t)))
|
||||
(entry (assoc name filesets-data)))
|
||||
filesets-data nil)))
|
||||
(entry (or (assoc name filesets-data)
|
||||
(when (y-or-n-p
|
||||
(format "Fileset %s does not exist. Create it?"
|
||||
name))
|
||||
(progn
|
||||
(add-to-list 'filesets-data (list name '(:files)))
|
||||
(message
|
||||
"Fileset %s created. Call `M-x filesets-save-config' to save."
|
||||
name)
|
||||
(car filesets-data))))))
|
||||
(if entry
|
||||
(let* ((files (filesets-entry-get-files entry))
|
||||
(this (buffer-file-name buffer))
|
||||
|
|
|
|||
|
|
@ -41,6 +41,16 @@
|
|||
;; You can also send in new modes; if the file types a reasonably common,
|
||||
;; we would like to install them.
|
||||
;;
|
||||
;; DEFAULT GENERIC MODE:
|
||||
;;
|
||||
;; This file provides a hook which automatically puts a file into
|
||||
;; `default-generic-mode' if the first few lines of a file in
|
||||
;; fundamental mode start with a hash comment character. To disable
|
||||
;; this functionality, set the variable `generic-use-find-file-hook'
|
||||
;; to nil BEFORE loading generic-x. See the variables
|
||||
;; `generic-lines-to-scan' and `generic-find-file-regexp' for
|
||||
;; customization options.
|
||||
;;
|
||||
;; PROBLEMS WHEN USED WITH FOLDING MODE:
|
||||
;;
|
||||
;; [The following relates to the obsolete selective-display technique.
|
||||
|
|
@ -95,11 +105,86 @@
|
|||
(require 'font-lock)
|
||||
|
||||
(defgroup generic-x nil
|
||||
"Extra modes for generic mode."
|
||||
"A collection of generic modes."
|
||||
:prefix "generic-"
|
||||
:group 'generic
|
||||
:group 'data
|
||||
:version "20.3")
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Default-Generic mode
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(defcustom generic-use-find-file-hook t
|
||||
"*If non-nil, add a hook to enter `default-generic-mode' automatically.
|
||||
This is done if the first few lines of a file in fundamental mode
|
||||
start with a hash comment character."
|
||||
:group 'generic-x
|
||||
:type 'boolean)
|
||||
|
||||
(defcustom generic-lines-to-scan 3
|
||||
"*Number of lines that `generic-mode-find-file-hook' looks at.
|
||||
Relevant when deciding whether to enter Default-Generic mode automatically.
|
||||
This variable should be set to a small positive number."
|
||||
:group 'generic-x
|
||||
:type 'integer)
|
||||
|
||||
(defcustom generic-find-file-regexp "^#"
|
||||
"*Regular expression used by `generic-mode-find-file-hook'.
|
||||
Files in fundamental mode whose first few lines contain a match
|
||||
for this regexp, should be put into Default-Generic mode instead.
|
||||
The number of lines tested for the matches is specified by the
|
||||
value of the variable `generic-lines-to-scan', which see."
|
||||
:group 'generic-x
|
||||
:type 'regexp)
|
||||
|
||||
(defcustom generic-ignore-files-regexp "[Tt][Aa][Gg][Ss]\\'"
|
||||
"*Regular expression used by `generic-mode-find-file-hook'.
|
||||
Files whose names match this regular expression should not be put
|
||||
into Default-Generic mode, even if they have lines which match
|
||||
the regexp in `generic-find-file-regexp'. If the value is nil,
|
||||
`generic-mode-find-file-hook' does not check the file names."
|
||||
:group 'generic-x
|
||||
:type '(choice (const :tag "Don't check file names" nil) regexp))
|
||||
|
||||
;; This generic mode is always defined
|
||||
(define-generic-mode default-generic-mode (list ?#) nil nil nil nil :group 'generic)
|
||||
|
||||
;; A more general solution would allow us to enter generic-mode for
|
||||
;; *any* comment character, but would require us to synthesize a new
|
||||
;; generic-mode on the fly. I think this gives us most of what we
|
||||
;; want.
|
||||
(defun generic-mode-find-file-hook ()
|
||||
"Hook function to enter Default-Generic mode automatically.
|
||||
|
||||
Done if the first few lines of a file in Fundamental mode start
|
||||
with a match for the regexp in `generic-find-file-regexp', unless
|
||||
the file's name matches the regexp which is the value of the
|
||||
variable `generic-ignore-files-regexp'.
|
||||
|
||||
This hook will be installed if the variable
|
||||
`generic-use-find-file-hook' is non-nil. The variable
|
||||
`generic-lines-to-scan' determines the number of lines to look at."
|
||||
(when (and (eq major-mode 'fundamental-mode)
|
||||
(or (null generic-ignore-files-regexp)
|
||||
(not (string-match
|
||||
generic-ignore-files-regexp
|
||||
(file-name-sans-versions buffer-file-name)))))
|
||||
(save-excursion
|
||||
(goto-char (point-min))
|
||||
(when (re-search-forward generic-find-file-regexp
|
||||
(save-excursion
|
||||
(forward-line generic-lines-to-scan)
|
||||
(point)) t)
|
||||
(goto-char (point-min))
|
||||
(default-generic-mode)))))
|
||||
|
||||
(and generic-use-find-file-hook
|
||||
(add-hook 'find-file-hook 'generic-mode-find-file-hook))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Other Generic modes
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(defcustom generic-extras-enable-list nil
|
||||
"*List of generic modes to enable by default.
|
||||
Each entry in the list should be a symbol. The variables
|
||||
|
|
@ -150,10 +235,6 @@ generic-x to enable the specified modes."
|
|||
etc-fstab-generic-mode)
|
||||
generic-extras-enable-list)))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Generic-modes
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
;;; Apache
|
||||
(when (memq 'apache-conf-generic-mode generic-extras-enable-list)
|
||||
|
||||
|
|
@ -284,8 +365,21 @@ generic-x to enable the specified modes."
|
|||
(setq imenu-generic-expression
|
||||
'((nil "^\\[\\(.*\\)\\]" 1)
|
||||
("*Variables*" "^\\s-*\\([^=]+\\)\\s-*=" 1))))))
|
||||
"Generic mode for MS-Windows INI files."
|
||||
:group 'generic-x))
|
||||
"Generic mode for MS-Windows INI files.
|
||||
You can use `ini-generic-mode-find-file-hook' to enter this mode
|
||||
automatically for INI files whose names do not end in \".ini\"."
|
||||
:group 'generic-x)
|
||||
|
||||
(defun ini-generic-mode-find-file-hook ()
|
||||
"Hook function to enter Ini-Generic mode automatically for INI files.
|
||||
Done if the first few lines of a file in Fundamental mode look
|
||||
like an INI file. You can add this hook to `find-file-hook'."
|
||||
(and (eq major-mode 'fundamental-mode)
|
||||
(save-excursion
|
||||
(goto-char (point-min))
|
||||
(and (looking-at "^\\s-*\\[.*\\]")
|
||||
(ini-generic-mode)))))
|
||||
(defalias 'generic-mode-ini-file-find-file-hook 'ini-generic-mode-find-file-hook))
|
||||
|
||||
;;; Windows REG files
|
||||
;;; Unfortunately, Windows 95 and Windows NT have different REG file syntax!
|
||||
|
|
@ -396,6 +490,7 @@ generic-x to enable the specified modes."
|
|||
(compile
|
||||
(concat (w32-shell-name) " -c " (buffer-file-name)))))
|
||||
|
||||
(eval-when-compile (require 'comint))
|
||||
(defun bat-generic-mode-run-as-comint ()
|
||||
"Run the current BAT file in a comint buffer."
|
||||
(interactive)
|
||||
|
|
@ -785,7 +880,7 @@ generic-x to enable the specified modes."
|
|||
'("^#[ \t]*\\(\\sw+\\)\\>[ \t]*\\(\\sw+\\)?"
|
||||
(1 font-lock-constant-face)
|
||||
(2 font-lock-variable-name-face nil t))))
|
||||
'("\\.[rR][cC]$")
|
||||
'("\\.[rR][cC]\\'")
|
||||
nil
|
||||
"Generic mode for MS-Windows Resource files."
|
||||
:group 'generic-x))
|
||||
|
|
@ -1406,7 +1501,7 @@ generic-x to enable the specified modes."
|
|||
(generic-make-keywords-list
|
||||
installshield-funarg-constants-list
|
||||
font-lock-variable-name-face "[^_]" "[^_]"))) ; is this face the best choice?
|
||||
'("\\.[rR][uU][lL]$")
|
||||
'("\\.[rR][uU][lL]\\'")
|
||||
'(generic-rul-mode-setup-function)
|
||||
"Generic mode for InstallShield RUL files."
|
||||
:group 'generic-x)
|
||||
|
|
@ -1584,8 +1679,8 @@ generic-x to enable the specified modes."
|
|||
"auto"
|
||||
"ignore")
|
||||
'(("^\\([/-A-Za-z0-9_]+\\)\\s-+\\([/-A-Za-z0-9_]+\\)"
|
||||
(1 font-lock-type-face)
|
||||
(2 font-lock-variable-name-face)))
|
||||
(1 font-lock-type-face t)
|
||||
(2 font-lock-variable-name-face t)))
|
||||
'("/etc/[v]*fstab\\'")
|
||||
(list
|
||||
(function
|
||||
|
|
@ -1667,7 +1762,7 @@ generic-x to enable the specified modes."
|
|||
;; List of additional font-lock-expressions
|
||||
'(("\\([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+\\)" 1 font-lock-constant-face)
|
||||
("^\\([.A-Za-z0-9]+\\)" 1 font-lock-variable-name-face))
|
||||
;; List of additional automode-alist expressions
|
||||
;; List of additional auto-mode-alist expressions
|
||||
nil
|
||||
;; List of set up functions to call
|
||||
nil
|
||||
|
|
@ -1688,7 +1783,7 @@ generic-x to enable the specified modes."
|
|||
'("nameserver" "domain" "search" "sortlist" "options")
|
||||
;; List of additional font-lock-expressions
|
||||
nil
|
||||
;; List of additional automode-alist expressions
|
||||
;; List of additional auto-mode-alist expressions
|
||||
'("/etc/resolv[e]?.conf\\'")
|
||||
;; List of set up functions to call
|
||||
nil
|
||||
|
|
|
|||
|
|
@ -1,8 +1,32 @@
|
|||
2005-04-13 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* gnus-art.el (gnus-mime-inline-part): Use mm-string-to-multibyte.
|
||||
* qp.el (quoted-printable-encode-region): Use mm-string-to-multibyte.
|
||||
|
||||
2005-04-13 Miles Bader <miles@gnu.org>
|
||||
|
||||
* mm-util.el (mm-string-to-multibyte): Use Gnus trunk definition.
|
||||
|
||||
2005-04-12 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* nnrss.el (nnrss-node-text): Replace CRLFs (which might be
|
||||
contained in text because xml.el decodes entities) with LFs.
|
||||
|
||||
2005-04-11 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* message.el (message-make-date): Handle byte-compiler warnings
|
||||
differently.
|
||||
* nnimap.el (nnimap-date-days-ago): Ditto.
|
||||
|
||||
2005-04-10 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* mm-util.el (mm-string-to-multibyte): New function.
|
||||
(mm-detect-coding-region): Typo.
|
||||
|
||||
2005-04-11 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* gnus-art.el (gnus-article-read-summary-keys): Fix misplaced parens.
|
||||
|
||||
2005-04-06 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* mm-util.el (mm-coding-system-p): Don't return binary for the nil
|
||||
|
|
@ -526,9 +550,6 @@
|
|||
|
||||
2004-11-26 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* lpath.el: Remove bbdb-create-internal, bbdb-records,
|
||||
spam-BBDB-register-routine and spam-enter-ham-BBDB.
|
||||
|
||||
* nnrss.el (nnrss-string-as-multibyte): Redefine it as a macro in
|
||||
order to silence the byte compiler.
|
||||
|
||||
|
|
|
|||
|
|
@ -4358,21 +4358,16 @@ are decompressed."
|
|||
(mm-read-coding-system "Charset: "))))
|
||||
(t
|
||||
(if (mm-handle-undisplayer handle)
|
||||
(mm-remove-part handle))
|
||||
(setq contents
|
||||
(if (fboundp 'string-to-multibyte)
|
||||
(string-to-multibyte contents)
|
||||
(mapconcat
|
||||
(lambda (ch) (mm-string-as-multibyte (char-to-string ch)))
|
||||
contents "")))))
|
||||
(mm-remove-part handle))))
|
||||
(forward-line 2)
|
||||
(mm-insert-inline handle
|
||||
(if (and charset
|
||||
(setq charset (mm-charset-to-coding-system
|
||||
charset))
|
||||
(not (eq charset 'ascii)))
|
||||
(mm-decode-coding-string contents charset)
|
||||
contents))
|
||||
(mm-insert-inline
|
||||
handle
|
||||
(if (and charset
|
||||
(setq charset (mm-charset-to-coding-system
|
||||
charset))
|
||||
(not (eq charset 'ascii)))
|
||||
(mm-decode-coding-string contents charset)
|
||||
(mm-string-to-multibyte contents)))
|
||||
(goto-char b)))))
|
||||
|
||||
(defun gnus-mime-view-part-as-charset (&optional handle arg)
|
||||
|
|
@ -5309,7 +5304,7 @@ not have a face in `gnus-article-boring-faces'."
|
|||
(when (eq win (selected-window))
|
||||
(setq new-sum-point (point)
|
||||
new-sum-start (window-start win)
|
||||
new-sum-hscroll (window-hscroll win))
|
||||
new-sum-hscroll (window-hscroll win)))
|
||||
(when (eq in-buffer (current-buffer))
|
||||
(setq selected (gnus-summary-select-article))
|
||||
(set-buffer obuf)
|
||||
|
|
@ -5325,7 +5320,7 @@ not have a face in `gnus-article-boring-faces'."
|
|||
new-sum-point)
|
||||
(set-window-point win new-sum-point)
|
||||
(set-window-start win new-sum-start)
|
||||
(set-window-hscroll win new-sum-hscroll)))))
|
||||
(set-window-hscroll win new-sum-hscroll))))
|
||||
(set-window-configuration owin)
|
||||
(ding))))))
|
||||
|
||||
|
|
|
|||
|
|
@ -4564,12 +4564,11 @@ Otherwise, generate and save a value for `canlock-password' first."
|
|||
(when (re-search-forward ",+$" nil t)
|
||||
(replace-match "" t t))))))
|
||||
|
||||
(eval-when-compile (require 'parse-time))
|
||||
(defun message-make-date (&optional now)
|
||||
"Make a valid data header.
|
||||
If NOW, use that time instead."
|
||||
(require 'parse-time)
|
||||
(defvar parse-time-weekdays)
|
||||
(defvar parse-time-months)
|
||||
(let* ((now (or now (current-time)))
|
||||
(zone (nth 8 (decode-time now)))
|
||||
(sign "+"))
|
||||
|
|
|
|||
|
|
@ -91,7 +91,12 @@
|
|||
;; (string-to-multibyte s) ~= (decode-coding-string s 'binary)
|
||||
;; (string-make-multibyte s) ~= (decode-coding-string s locale-coding-system)
|
||||
(string-as-multibyte . identity)
|
||||
(string-to-multibyte . mm-string-as-multibyte)
|
||||
(string-to-multibyte
|
||||
. (lambda (string)
|
||||
"Return a multibyte string with the same individual chars as string."
|
||||
(mapconcat
|
||||
(lambda (ch) (mm-string-as-multibyte (char-to-string ch)))
|
||||
string "")))
|
||||
(multibyte-string-p . ignore)
|
||||
;; It is not a MIME function, but some MIME functions use it.
|
||||
(make-temp-file . (lambda (prefix &optional dir-flag)
|
||||
|
|
|
|||
|
|
@ -1386,10 +1386,10 @@ function is generally only called when Gnus is shutting down."
|
|||
(list (- ms 1) (+ (expt 2 16) ls))
|
||||
(list ms ls))))
|
||||
|
||||
(eval-when-compile (require 'parse-time))
|
||||
(defun nnimap-date-days-ago (daysago)
|
||||
"Return date, in format \"3-Aug-1998\", for DAYSAGO days ago."
|
||||
(require 'parse-time)
|
||||
(defvar parse-time-months)
|
||||
(let* ((time (nnimap-time-substract (current-time) (days-to-time daysago)))
|
||||
(date (format-time-string
|
||||
(format "%%d-%s-%%Y"
|
||||
|
|
|
|||
|
|
@ -679,8 +679,11 @@ It is useful when `(setq nnrss-use-local t)'."
|
|||
(text (if (and node (listp node))
|
||||
(nnrss-node-just-text node)
|
||||
node))
|
||||
(cleaned-text (if text (gnus-replace-in-string
|
||||
text "^[\000-\037\177]+\\|^ +\\| +$" ""))))
|
||||
(cleaned-text (if text
|
||||
(gnus-replace-in-string
|
||||
(gnus-replace-in-string
|
||||
text "^[\000-\037\177]+\\|^ +\\| +$" "")
|
||||
"\r\n" "\n"))))
|
||||
(if (string-equal "" cleaned-text)
|
||||
nil
|
||||
cleaned-text)))
|
||||
|
|
|
|||
|
|
@ -100,15 +100,10 @@ You should probably avoid non-ASCII characters in this arg.
|
|||
If `mm-use-ultra-safe-encoding' is set, fold lines unconditionally and
|
||||
encode lines starting with \"From\"."
|
||||
(interactive "r")
|
||||
(save-excursion
|
||||
(goto-char from)
|
||||
(if (fboundp 'string-to-multibyte) ; Emacs 22
|
||||
(if (re-search-forward (string-to-multibyte "[^\x0-\x7f\x80-\xff]")
|
||||
to t)
|
||||
;; Fixme: This is somewhat misleading.
|
||||
(error "Multibyte character in QP encoding region"))
|
||||
(if (re-search-forward (mm-string-as-multibyte "[^\0-\377]") to t)
|
||||
(error "Multibyte character in QP encoding region"))))
|
||||
(goto-char from)
|
||||
(if (re-search-forward (mm-string-to-multibyte "[^\x0-\x7f\x80-\xff]")
|
||||
to t)
|
||||
(error "Multibyte character in QP encoding region"))
|
||||
(unless class
|
||||
;; Avoid using 8bit characters. = is \075.
|
||||
;; Equivalent to "^\000-\007\013\015-\037\200-\377="
|
||||
|
|
|
|||
|
|
@ -590,7 +590,8 @@ the last key hit are used."
|
|||
;; Don't bother user with strings from (e.g.) the select-paste menu.
|
||||
(if (stringp (aref key (1- (length key))))
|
||||
(aset key (1- (length key)) "(any string)"))
|
||||
(if (stringp (aref untranslated (1- (length untranslated))))
|
||||
(if (and (> (length untranslated) 0)
|
||||
(stringp (aref untranslated (1- (length untranslated)))))
|
||||
(aset untranslated (1- (length untranslated))
|
||||
"(any string)"))
|
||||
;; Now describe the key, perhaps as changed.
|
||||
|
|
@ -603,7 +604,6 @@ the last key hit are used."
|
|||
key-desc
|
||||
(if (symbolp defn) defn (prin1-to-string defn)))))))))
|
||||
|
||||
|
||||
(defun describe-key (key &optional untranslated up-event)
|
||||
"Display documentation of the function invoked by KEY.
|
||||
KEY should be a key sequence--when calling from a program,
|
||||
|
|
|
|||
|
|
@ -189,7 +189,7 @@ Return an updated `non-iso-charset-alist'."
|
|||
;; For Quail translation. Fixme: this should really be
|
||||
;; a separate table that only translates the coding
|
||||
;; system's safe-chars.
|
||||
(cons 'translation-table-for-input ,ucs-mule-to-mule-unicode)))
|
||||
(cons 'translation-table-for-input 'ucs-mule-to-mule-unicode)))
|
||||
(push (list ',name
|
||||
nil ; charset list
|
||||
',decoder
|
||||
|
|
@ -4475,7 +4475,7 @@ Return an updated `non-iso-charset-alist'."
|
|||
pt154
|
||||
[?Җ ?Ғ ?Ӯ ?ғ ?„ ?… ?Ҷ ?Ү ?Ҳ ?ү ?Ҡ ?Ӣ ?Ң ?Қ ?Һ ?Ҹ ?җ ?‘ ?’ ?“ ?” ?• ?–
|
||||
?— ?ҳ ?ҷ ?ҡ ?ӣ ?ң ?қ ?һ ?ҹ ? ?Ў ?ў ?Ј ?Ө ?Ҙ ?Ұ ?§ ?Ё ?© ?Ә ?\« ?¬ ?ӯ
|
||||
?® ?Ҝ ?° ?ұ ?І ?і ?ҙ ?ө ?¶ ?· ?ё ?№ ?ә ?» ?ј ?Ҫ ?ҫ ?ҝ ?А ?Б ?В ?Г ?Д
|
||||
?® ?Ҝ ?° ?ұ ?І ?і ?ҙ ?ө ?¶ ?· ?ё ?№ ?ә ?\» ?ј ?Ҫ ?ҫ ?ҝ ?А ?Б ?В ?Г ?Д
|
||||
?Е ?Ж ?З ?И ?Й ?К ?Л ?М ?Н ?О ?П ?Р ?С ?Т ?У ?Ф ?Х ?Ц ?Ч ?Ш ?Щ ?Ъ ?Ы
|
||||
?Ь ?Э ?Ю ?Я ?а ?б ?в ?г ?д ?е ?ж ?з ?и ?й ?к ?л ?м ?н ?о ?п ?р ?с ?т
|
||||
?у ?ф ?х ?ц ?ч ?ш ?щ ?ъ ?ы ?ь ?э ?ю ?я])
|
||||
|
|
|
|||
|
|
@ -2395,6 +2395,15 @@ See also `locale-charset-language-names', `locale-language-names',
|
|||
(= 0 (length locale))) ; nil or empty string
|
||||
(setq locale (getenv (pop vars))))))
|
||||
|
||||
(unless (or locale (not (fboundp 'mac-get-preference)))
|
||||
(setq locale (mac-get-preference "AppleLocale"))
|
||||
(unless locale
|
||||
(let ((languages (mac-get-preference "AppleLanguages")))
|
||||
(unless (= (length languages) 0) ; nil or empty vector
|
||||
(setq locale (aref languages 0))))))
|
||||
(unless (or locale (not (boundp 'mac-system-locale)))
|
||||
(setq locale mac-system-locale))
|
||||
|
||||
(when locale
|
||||
|
||||
;; Translate "swedish" into "sv_SE.ISO8859-1", and so on,
|
||||
|
|
@ -2425,7 +2434,8 @@ See also `locale-charset-language-names', `locale-language-names',
|
|||
(when locale
|
||||
(if (string-match "\\.\\([^@]+\\)" locale)
|
||||
(locale-charset-to-coding-system
|
||||
(match-string 1 locale)))))))
|
||||
(match-string 1 locale))))
|
||||
(and (eq system-type 'macos) mac-system-coding-system))))
|
||||
|
||||
(if (consp language-name)
|
||||
;; locale-language-names specify both lang-env and coding.
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
;;; ucs-tables.el --- translation to, from and via Unicode -*- coding: iso-2022-7bit -*-
|
||||
|
||||
;; Copyright (C) 2001, 2002 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 2001, 2002, 2005 Free Software Foundation, Inc.
|
||||
|
||||
;; Author: Dave Love <fx@gnu.org>
|
||||
;; Keywords: i18n
|
||||
|
|
@ -2496,8 +2496,10 @@ See also command `unify-8859-on-encoding-mode' and the user option
|
|||
;; normal-mode and minibuffer-setup-hook.
|
||||
(defun ucs-set-table-for-input (&optional buffer)
|
||||
"Set up an appropriate `translation-table-for-input' for BUFFER.
|
||||
BUFFER defaults to the current buffer."
|
||||
BUFFER defaults to the current buffer.
|
||||
This function is automatically called directly at the end of `get-buffer-create'."
|
||||
(when (and unify-8859-on-encoding-mode
|
||||
(not unify-8859-on-decoding-mode)
|
||||
(char-table-p translation-table-for-input))
|
||||
(let ((cs (and buffer-file-coding-system
|
||||
(coding-system-base buffer-file-coding-system)))
|
||||
|
|
@ -2535,5 +2537,5 @@ Intended to be added to `minibuffer-setup-hook'."
|
|||
|
||||
(provide 'ucs-tables)
|
||||
|
||||
;;; arch-tag: b497e22b-7fe1-486a-9352-e2d7f7d76a76
|
||||
;; arch-tag: b497e22b-7fe1-486a-9352-e2d7f7d76a76
|
||||
;;; ucs-tables.el ends here
|
||||
|
|
|
|||
|
|
@ -198,12 +198,16 @@ invoked."
|
|||
(choice :tag "Compress Message"
|
||||
(string :format "%v")
|
||||
(const :tag "No Message" nil))
|
||||
(string :tag "Compress Program")
|
||||
(choice :tag "Compress Program"
|
||||
(string)
|
||||
(const :tag "None" nil))
|
||||
(repeat :tag "Compress Arguments" string)
|
||||
(choice :tag "Uncompress Message"
|
||||
(string :format "%v")
|
||||
(const :tag "No Message" nil))
|
||||
(string :tag "Uncompress Program")
|
||||
(choice :tag "Uncompress Program"
|
||||
(string)
|
||||
(const :tag "None" nil))
|
||||
(repeat :tag "Uncompress Arguments" string)
|
||||
(boolean :tag "Append")
|
||||
(boolean :tag "Strip Extension")
|
||||
|
|
|
|||
|
|
@ -194,29 +194,27 @@ such as redefining an Emacs function."
|
|||
(dolist (elt (cdr unload-hook-features-list))
|
||||
(if (symbolp elt)
|
||||
(elp-restore-function elt))))
|
||||
(mapc
|
||||
(lambda (x)
|
||||
(cond ((stringp x) nil)
|
||||
((consp x)
|
||||
;; Remove any feature names that this file provided.
|
||||
(if (eq (car x) 'provide)
|
||||
(setq features (delq (cdr x) features)))
|
||||
(when (eq (car x) 'defvar)
|
||||
;; Kill local values as much as possible.
|
||||
(dolist (buf (buffer-list))
|
||||
(with-current-buffer buf
|
||||
(kill-local-variable (cdr x))))
|
||||
;; Get rid of the default binding if we can.
|
||||
(unless (local-variable-if-set-p (cdr x))
|
||||
(makunbound (cdr x)))))
|
||||
(t
|
||||
(when (fboundp x)
|
||||
(if (fboundp 'ad-unadvise)
|
||||
(ad-unadvise x))
|
||||
(fmakunbound x)
|
||||
(let ((aload (get x 'autoload)))
|
||||
(if aload (fset x (cons 'autoload aload))))))))
|
||||
(cdr unload-hook-features-list))
|
||||
(dolist (x (cdr unload-hook-features-list))
|
||||
(when (consp x)
|
||||
;; Remove any feature names that this file provided.
|
||||
(if (eq (car x) 'provide)
|
||||
(setq features (delq (cdr x) features)))
|
||||
(when (eq (car x) 'defvar)
|
||||
;; Kill local values as much as possible.
|
||||
(dolist (buf (buffer-list))
|
||||
(with-current-buffer buf
|
||||
(kill-local-variable (cdr x))))
|
||||
;; Get rid of the default binding if we can.
|
||||
(unless (local-variable-if-set-p (cdr x))
|
||||
(makunbound (cdr x))))
|
||||
(when (eq (car x) 'defun)
|
||||
(let ((fun (cdr x)))
|
||||
(when (fboundp fun)
|
||||
(if (fboundp 'ad-unadvise)
|
||||
(ad-unadvise fun))
|
||||
(fmakunbound fun)
|
||||
(let ((aload (get fun 'autoload)))
|
||||
(if aload (fset fun (cons 'autoload aload)))))))))
|
||||
;; Delete the load-history element for this file.
|
||||
(let ((elt (assoc file load-history)))
|
||||
(setq load-history (delq elt load-history)))))
|
||||
|
|
|
|||
|
|
@ -203,6 +203,7 @@
|
|||
|
||||
(load "vc-hooks")
|
||||
(load "ediff-hook")
|
||||
(if (fboundp 'x-show-tip) (load "tooltip"))
|
||||
(message "%s" (garbage-collect))
|
||||
|
||||
;If you want additional libraries to be preloaded and their
|
||||
|
|
|
|||
|
|
@ -246,7 +246,7 @@ It is useful to set this variable in the site customization file.")
|
|||
|
||||
;;;###autoload
|
||||
(defcustom rmail-ignored-headers
|
||||
(concat "^via:\\|^mail-from:\\|^origin:\\|^references:"
|
||||
(concat "^via:\\|^mail-from:\\|^origin:\\|^references:\\|^sender:"
|
||||
"\\|^status:\\|^received:\\|^x400-originator:\\|^x400-recipients:"
|
||||
"\\|^x400-received:\\|^x400-mts-identifier:\\|^x400-content-type:"
|
||||
"\\|^\\(resent-\\|\\)message-id:\\|^summary-line:\\|^resent-date:"
|
||||
|
|
@ -254,14 +254,17 @@ It is useful to set this variable in the site customization file.")
|
|||
"\\|^x-mailer:\\|^delivered-to:\\|^lines:\\|^mime-version:"
|
||||
"\\|^content-transfer-encoding:\\|^x-coding-system:"
|
||||
"\\|^return-path:\\|^errors-to:\\|^return-receipt-to:"
|
||||
"\\|^x-sign:\\|^x-beenthere:\\|^x-mailman-version:"
|
||||
"\\|^x-sign:\\|^x-beenthere:\\|^x-mailman-version:\\|^x-mailman-copy:"
|
||||
"\\|^precedence:\\|^list-help:\\|^list-post:\\|^list-subscribe:"
|
||||
"\\|^list-id:\\|^list-unsubscribe:\\|^list-archive:"
|
||||
"\\|^content-type:\\|^content-length:"
|
||||
"\\|^x-attribution:\\|^x-disclaimer:\\|^x-trace:"
|
||||
"\\|^x-complaints-to:\\|^nntp-posting-date:\\|^user-agent"
|
||||
"\\|^importance:\\|^envelope-to:\\|^delivery-date"
|
||||
"\\|^x.*-priority:\\|^x-mimeole:")
|
||||
"\\|^x.*-priority:\\|^x-mimeole:\\|^x-archive:"
|
||||
"\\|^resent-face:\\|^resent-x.*:\\|^resent-organization\\|^resent-openpgp"
|
||||
"\\|^openpgp:\\|^x-request-pgp:\\|^x-original.*:"
|
||||
"\\|^x-virus-scanned:\\|^x-spam-[^s].*:")
|
||||
"*Regexp to match header fields that Rmail should normally hide.
|
||||
This variable is used for reformatting the message header,
|
||||
which normally happens once for each message,
|
||||
|
|
@ -653,6 +656,7 @@ The first parenthesized expression should match the MIME-charset name.")
|
|||
. font-lock-function-name-face)
|
||||
'("^Reply-To:.*$" . font-lock-function-name-face)
|
||||
'("^Subject:" . font-lock-comment-face)
|
||||
'("^X-Spam-Status:" . font-lock-keyword-face)
|
||||
'("^\\(To\\|Apparently-To\\|Cc\\|Newsgroups\\):"
|
||||
. font-lock-keyword-face)
|
||||
;; Use MATCH-ANCHORED to effectively anchor the regexp left side.
|
||||
|
|
@ -662,8 +666,7 @@ The first parenthesized expression should match the MIME-charset name.")
|
|||
"\\(" cite-chars "[ \t]*\\)\\)+"
|
||||
"\\(.*\\)")
|
||||
(beginning-of-line) (end-of-line)
|
||||
(2 font-lock-constant-face nil t)
|
||||
(4 font-lock-comment-face nil t)))
|
||||
(3 font-lock-comment-face nil t)))
|
||||
'("^\\(X-[a-z0-9-]+\\|In-reply-to\\|Date\\):.*\\(\n[ \t]+.*\\)*$"
|
||||
. font-lock-string-face))))
|
||||
"Additional expressions to highlight in Rmail mode.")
|
||||
|
|
|
|||
|
|
@ -366,7 +366,9 @@ actually occur.")
|
|||
(list '("^\\(To\\|Newsgroups\\):" . font-lock-function-name-face)
|
||||
'("^\\(B?CC\\|Reply-to\\|Mail-\\(reply\\|followup\\)-to\\):" . font-lock-keyword-face)
|
||||
'("^\\(Subject:\\)[ \t]*\\(.+\\)?"
|
||||
(1 font-lock-comment-face) (2 font-lock-type-face nil t))
|
||||
(1 font-lock-comment-face)
|
||||
;; (2 font-lock-type-face nil t)
|
||||
)
|
||||
;; Use EVAL to delay in case `mail-header-separator' gets changed.
|
||||
'(eval .
|
||||
(let ((separator (if (zerop (length mail-header-separator))
|
||||
|
|
@ -380,8 +382,7 @@ actually occur.")
|
|||
"\\(" cite-chars "[ \t]*\\)\\)+"
|
||||
"\\(.*\\)")
|
||||
(beginning-of-line) (end-of-line)
|
||||
(2 font-lock-constant-face nil t)
|
||||
(4 font-lock-comment-face nil t)))
|
||||
(3 font-lock-comment-face nil t)))
|
||||
'("^\\(X-[A-Za-z0-9-]+\\|In-reply-to\\):.*\\(\n[ \t]+.*\\)*$"
|
||||
. font-lock-string-face))))
|
||||
"Additional expressions to highlight in Mail mode.")
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
# -*- Makefile -*- for GNU Emacs on the Microsoft W32 API.
|
||||
# Copyright (c) 2000,2001,2004 Free Software Foundation, Inc.
|
||||
# Copyright (c) 2000, 2001, 2004, 2005 Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is part of GNU Emacs.
|
||||
#
|
||||
|
|
@ -46,77 +46,6 @@ lisptagsfiles1 = $(lisp)/*.el
|
|||
lisptagsfiles2 = $(lisp)/*/*.el
|
||||
ETAGS = "../lib-src/$(BLD)/etags"
|
||||
|
||||
# Files which should not be compiled. If you change the name `DONTCOMPILE'
|
||||
# to something different, you'll have to change make-dist as well, and
|
||||
# modify the lists in $lisp and $shortlisp on src/Makefile.in.
|
||||
#
|
||||
# - emacs-lisp/cl-specs.el: only contains `def-edebug-spec's so there's
|
||||
# no point compiling it, although it doesn't hurt.
|
||||
|
||||
DONTCOMPILE = \
|
||||
$(lisp)/cus-load.el \
|
||||
$(lisp)/emacs-lisp/cl-specs.el \
|
||||
$(lisp)/eshell/esh-maint.el \
|
||||
$(lisp)/eshell/esh-groups.el \
|
||||
$(lisp)/finder-inf.el \
|
||||
$(lisp)/forms-d2.el \
|
||||
$(lisp)/forms-pass.el \
|
||||
$(lisp)/generic-x.el \
|
||||
$(lisp)/international/latin-1.el \
|
||||
$(lisp)/international/latin-2.el \
|
||||
$(lisp)/international/latin-3.el \
|
||||
$(lisp)/international/latin-4.el \
|
||||
$(lisp)/international/latin-5.el \
|
||||
$(lisp)/international/latin-8.el \
|
||||
$(lisp)/international/latin-9.el \
|
||||
$(lisp)/international/mule-conf.el \
|
||||
$(lisp)/language/czech.el \
|
||||
$(lisp)/language/devanagari.el \
|
||||
$(lisp)/language/kannada.el \
|
||||
$(lisp)/language/malayalam.el \
|
||||
$(lisp)/language/tamil.el \
|
||||
$(lisp)/language/english.el \
|
||||
$(lisp)/language/greek.el \
|
||||
$(lisp)/language/hebrew.el \
|
||||
$(lisp)/language/japanese.el \
|
||||
$(lisp)/language/korean.el \
|
||||
$(lisp)/language/lao.el \
|
||||
$(lisp)/language/misc-lang.el \
|
||||
$(lisp)/language/romanian.el \
|
||||
$(lisp)/language/slovak.el \
|
||||
$(lisp)/language/thai.el \
|
||||
$(lisp)/language/utf-8-lang.el \
|
||||
$(lisp)/language/georgian.el \
|
||||
$(lisp)/loaddefs.el \
|
||||
$(lisp)/ldefs-boot.el \
|
||||
$(lisp)/loadup.el \
|
||||
$(lisp)/mail/blessmail.el \
|
||||
$(lisp)/patcomp.el \
|
||||
$(lisp)/paths.el \
|
||||
$(lisp)/play/bruce.el \
|
||||
$(lisp)/subdirs.el \
|
||||
$(lisp)/term/internal.el \
|
||||
$(lisp)/term/AT386.el \
|
||||
$(lisp)/term/apollo.el \
|
||||
$(lisp)/term/bobcat.el \
|
||||
$(lisp)/term/iris-ansi.el \
|
||||
$(lisp)/term/keyswap.el \
|
||||
$(lisp)/term/linux.el \
|
||||
$(lisp)/term/lk201.el \
|
||||
$(lisp)/term/news.el \
|
||||
$(lisp)/term/vt102.el \
|
||||
$(lisp)/term/vt125.el \
|
||||
$(lisp)/term/vt200.el \
|
||||
$(lisp)/term/vt201.el \
|
||||
$(lisp)/term/vt220.el \
|
||||
$(lisp)/term/vt240.el \
|
||||
$(lisp)/term/vt300.el \
|
||||
$(lisp)/term/vt320.el \
|
||||
$(lisp)/term/vt400.el \
|
||||
$(lisp)/term/vt420.el \
|
||||
$(lisp)/term/wyse50.el \
|
||||
$(lisp)/version.el
|
||||
|
||||
# Files to compile before others during a bootstrap. This is done to
|
||||
# speed up the bootstrap process. The CC files are compiled first
|
||||
# because CC mode tweaks the compilation process, and requiring
|
||||
|
|
@ -251,7 +180,7 @@ updates: update-subdirs autoloads finder-data custom-deps
|
|||
# Update the AUTHORS file.
|
||||
|
||||
update-authors:
|
||||
$(emacs) -f batch-update-authors $(srcdir)/AUTHORS $(srcdir)
|
||||
$(emacs) -l authors -f batch-update-authors $(srcdir)/AUTHORS $(srcdir)
|
||||
|
||||
TAGS: $(lisptagsfiles1) $(lisptagsfiles2)
|
||||
$(ETAGS) $(lisptagsfiles1) $(lisptagsfiles2)
|
||||
|
|
@ -264,19 +193,17 @@ TAGS-LISP: $(lisptagsfiles1) $(lisptagsfiles2)
|
|||
.el.elc:
|
||||
-$(emacs) -f batch-byte-compile $<
|
||||
|
||||
$(DONTCOMPILE:.el=.elc):
|
||||
-$(DEL) $@
|
||||
# Compile all Lisp files, but don't recompile those that are up to
|
||||
# date. Some files don't actually get compiled because they set the
|
||||
# local variable no-byte-compile.
|
||||
|
||||
# Compile all Lisp files, except those from DONTCOMPILE,
|
||||
# but don't recompile those that are up to date.
|
||||
|
||||
# All .elc files are made writable
|
||||
# before compilation in case we checked out read-only (CVS option -r).
|
||||
# Files MUST be compiled one by one. If we compile several files in a
|
||||
# row we can't make sure that the compilation environment is clean.
|
||||
# We also set the load-path of the Emacs used for compilation to the
|
||||
# current directory and its subdirectories, to make sure require's and
|
||||
# load's in the files being compiled find the right files.
|
||||
# All .elc files are made writable before compilation in case we
|
||||
# checked out read-only (CVS option -r). Files MUST be compiled one by
|
||||
# one. If we compile several files in a row we can't make sure that
|
||||
# the compilation environment is clean. We also set the load-path of
|
||||
# the Emacs used for compilation to the current directory and its
|
||||
# subdirectories, to make sure require's and load's in the files being
|
||||
# compiled find the right files.
|
||||
|
||||
# Need separate version for sh and native cmd.exe
|
||||
compile: subdirs.el compile-$(SHELLTYPE) doit
|
||||
|
|
@ -304,8 +231,10 @@ compile-SH:
|
|||
done; \
|
||||
done
|
||||
|
||||
# Compile all Lisp files, except those from DONTCOMPILE. This
|
||||
# is like `compile' but compiles files unconditionally.
|
||||
# Compile all Lisp files. This is like `compile' but compiles files
|
||||
# unconditionally. Some files don't actually get compiled because they
|
||||
# set the local variable no-byte-compile.
|
||||
|
||||
compile-always: subdirs.el compile-always-$(SHELLTYPE) doit
|
||||
|
||||
compile-always-CMD:
|
||||
|
|
|
|||
|
|
@ -1055,10 +1055,10 @@ block[ \t]*data\\)\\>")
|
|||
(f90-change-keywords f90-auto-keyword-case
|
||||
(line-beginning-position) (line-end-position))))
|
||||
|
||||
(defun f90-electric-insert ()
|
||||
(defun f90-electric-insert (&optional arg)
|
||||
"Change keyword case and auto-fill line as operators are inserted."
|
||||
(interactive)
|
||||
(self-insert-command 1)
|
||||
(interactive "*p")
|
||||
(self-insert-command arg)
|
||||
(if auto-fill-function (f90-do-auto-fill) ; also updates line
|
||||
(f90-update-line)))
|
||||
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@
|
|||
(defvar gdb-overlay-arrow-position nil)
|
||||
(defvar gdb-server-prefix nil)
|
||||
(defvar gdb-flush-pending-output nil)
|
||||
(defvar gdb-location-list nil "List of directories for source files.")
|
||||
(defvar gdb-location-list nil "Alist of breakpoint numbers and full filenames.")
|
||||
(defvar gdb-find-file-unhook nil)
|
||||
|
||||
(defvar gdb-buffer-type nil
|
||||
|
|
@ -258,6 +258,7 @@ detailed description of this mode.
|
|||
'gdb-mouse-set-clear-breakpoint)
|
||||
(define-key gud-minor-mode-map [left-margin mouse-3]
|
||||
'gdb-mouse-toggle-breakpoint)
|
||||
; Currently only works in margin.
|
||||
; (define-key gud-minor-mode-map [left-fringe mouse-3]
|
||||
; 'gdb-mouse-toggle-breakpoint)
|
||||
|
||||
|
|
@ -606,6 +607,21 @@ The key should be one of the cars in `gdb-buffer-rules-assoc'."
|
|||
(gdb-get-target-string)
|
||||
"*"))
|
||||
|
||||
(defun gdb-display-inferior-io-buffer ()
|
||||
"Display IO of inferior in a separate window."
|
||||
(interactive)
|
||||
(if gdb-use-inferior-io-buffer
|
||||
(gdb-display-buffer
|
||||
(gdb-get-create-buffer 'gdb-inferior-io))))
|
||||
|
||||
(defun gdb-frame-inferior-io-buffer ()
|
||||
"Display IO of inferior in a new frame."
|
||||
(interactive)
|
||||
(if gdb-use-inferior-io-buffer
|
||||
(let ((special-display-regexps (append special-display-regexps '(".*")))
|
||||
(special-display-frame-alist gdb-frame-parameters))
|
||||
(display-buffer (gdb-get-create-buffer 'gdb-inferior-io)))))
|
||||
|
||||
(defvar gdb-inferior-io-mode-map
|
||||
(let ((map (make-sparse-keymap)))
|
||||
(define-key map "\C-c\C-c" 'gdb-inferior-io-interrupt)
|
||||
|
|
@ -1372,9 +1388,9 @@ static char *magick[] = {
|
|||
(file (match-string 2))
|
||||
(line (match-string 3)))
|
||||
(save-selected-window
|
||||
(let* ((buf (find-file-noselect (if (file-exists-p file)
|
||||
file
|
||||
(cdr (assoc bptno gdb-location-list)))))
|
||||
(let* ((buf (find-file-noselect
|
||||
(if (file-exists-p file) file
|
||||
(cdr (assoc bptno gdb-location-list)))))
|
||||
(window (display-buffer buf)))
|
||||
(with-current-buffer buf
|
||||
(goto-line (string-to-number line))
|
||||
|
|
@ -1810,26 +1826,26 @@ corresponding to the mode line clicked."
|
|||
"Read address: "
|
||||
(propertize gdb-memory-address
|
||||
'face font-lock-warning-face
|
||||
'help-echo (purecopy "mouse-1: Set memory address")
|
||||
'local-map (purecopy (gdb-make-header-line-mouse-map
|
||||
'mouse-1
|
||||
#'gdb-memory-set-address)))
|
||||
'help-echo "mouse-1: Set memory address"
|
||||
'local-map (gdb-make-header-line-mouse-map
|
||||
'mouse-1
|
||||
#'gdb-memory-set-address))
|
||||
" Repeat Count: "
|
||||
(propertize (number-to-string gdb-memory-repeat-count)
|
||||
'face font-lock-warning-face
|
||||
'help-echo (purecopy "mouse-1: Set repeat count")
|
||||
'local-map (purecopy (gdb-make-header-line-mouse-map
|
||||
'mouse-1
|
||||
#'gdb-memory-set-repeat-count)))
|
||||
'help-echo "mouse-1: Set repeat count"
|
||||
'local-map (gdb-make-header-line-mouse-map
|
||||
'mouse-1
|
||||
#'gdb-memory-set-repeat-count))
|
||||
" Display Format: "
|
||||
(propertize gdb-memory-format
|
||||
'face font-lock-warning-face
|
||||
'help-echo (purecopy "mouse-3: Select display format")
|
||||
'help-echo "mouse-3: Select display format"
|
||||
'local-map gdb-memory-format-keymap)
|
||||
" Unit Size: "
|
||||
(propertize gdb-memory-unit
|
||||
'face font-lock-warning-face
|
||||
'help-echo (purecopy "mouse-3: Select unit size")
|
||||
'help-echo "mouse-3: Select unit size"
|
||||
'local-map gdb-memory-unit-keymap))))
|
||||
(run-mode-hooks 'gdb-memory-mode-hook)
|
||||
'gdb-invalidate-memory)
|
||||
|
|
@ -1936,11 +1952,12 @@ corresponding to the mode line clicked."
|
|||
(let ((answer (get-buffer-window buf 0))
|
||||
(must-split nil))
|
||||
(if answer
|
||||
(display-buffer buf) ;Raise the frame if necessary.
|
||||
(display-buffer buf nil 0) ;Raise the frame if necessary.
|
||||
;; The buffer is not yet displayed.
|
||||
(pop-to-buffer gud-comint-buffer) ;Select the right frame.
|
||||
(let ((window (get-lru-window)))
|
||||
(if window
|
||||
(if (and window
|
||||
(not (eq window (get-buffer-window gud-comint-buffer))))
|
||||
(progn
|
||||
(set-window-buffer window buf)
|
||||
(setq answer window))
|
||||
|
|
@ -1965,6 +1982,9 @@ corresponding to the mode line clicked."
|
|||
(define-key menu [memory] '("Memory" . gdb-display-memory-buffer))
|
||||
(define-key menu [assembler] '("Machine" . gdb-display-assembler-buffer))
|
||||
(define-key menu [registers] '("Registers" . gdb-display-registers-buffer))
|
||||
(define-key menu [inferior]
|
||||
'(menu-item "Inferior IO" gdb-display-inferior-io-buffer
|
||||
:enable gdb-use-inferior-io-buffer))
|
||||
(define-key menu [locals] '("Locals" . gdb-display-locals-buffer))
|
||||
(define-key menu [frames] '("Stack" . gdb-display-stack-buffer))
|
||||
(define-key menu [breakpoints] '("Breakpoints" . gdb-display-breakpoints-buffer)))
|
||||
|
|
@ -1977,6 +1997,9 @@ corresponding to the mode line clicked."
|
|||
(define-key menu [memory] '("Memory" . gdb-frame-memory-buffer))
|
||||
(define-key menu [assembler] '("Machine" . gdb-frame-assembler-buffer))
|
||||
(define-key menu [registers] '("Registers" . gdb-frame-registers-buffer))
|
||||
(define-key menu [inferior]
|
||||
'(menu-item "Inferior IO" gdb-frame-inferior-io-buffer
|
||||
:enable gdb-use-inferior-io-buffer))
|
||||
(define-key menu [locals] '("Locals" . gdb-frame-locals-buffer))
|
||||
(define-key menu [frames] '("Stack" . gdb-frame-stack-buffer))
|
||||
(define-key menu [breakpoints] '("Breakpoints" . gdb-frame-breakpoints-buffer)))
|
||||
|
|
@ -1985,11 +2008,21 @@ corresponding to the mode line clicked."
|
|||
(define-key gud-menu-map [ui]
|
||||
`(menu-item "GDB-UI" ,menu :visible (eq gud-minor-mode 'gdba)))
|
||||
(define-key menu [gdb-restore-windows]
|
||||
'("Restore Window Layout" . gdb-restore-windows))
|
||||
'(menu-item "Restore Window Layout" gdb-restore-windows
|
||||
:help "Restore standard layout for debug session."))
|
||||
(define-key menu [gdb-many-windows]
|
||||
(menu-bar-make-toggle gdb-many-windows gdb-many-windows
|
||||
"Display Other Windows" "Many windows %s"
|
||||
"Toggle display of locals, stack and breakpoint information")))
|
||||
'(menu-item "Display Other Windows" gdb-many-windows
|
||||
:help "Toggle display of locals, stack and breakpoint information"
|
||||
:button (:toggle . gdb-many-windows)))
|
||||
(define-key menu [gdb-use-inferior-io]
|
||||
(menu-bar-make-toggle toggle-gdb-use-inferior-io-buffer
|
||||
gdb-use-inferior-io-buffer
|
||||
"Separate inferior IO" "Use separate IO %s"
|
||||
"Toggle separate IO for inferior.")))
|
||||
|
||||
(defadvice toggle-gdb-use-inferior-io-buffer (after gdb-kill-io-buffer activate)
|
||||
(unless gdb-use-inferior-io-buffer
|
||||
(kill-buffer (gdb-inferior-io-name))))
|
||||
|
||||
(defun gdb-frame-gdb-buffer ()
|
||||
"Display GUD buffer in a new frame."
|
||||
|
|
@ -2038,7 +2071,8 @@ corresponding to the mode line clicked."
|
|||
(when gdb-use-inferior-io-buffer
|
||||
(split-window-horizontally)
|
||||
(other-window 1)
|
||||
(gdb-set-window-buffer (gdb-inferior-io-name)))
|
||||
(gdb-set-window-buffer
|
||||
(gdb-get-create-buffer 'gdb-inferior-io)))
|
||||
(other-window 1)
|
||||
(gdb-set-window-buffer (gdb-stack-buffer-name))
|
||||
(split-window-horizontally)
|
||||
|
|
@ -2337,7 +2371,6 @@ BUFFER nil or omitted means use the current buffer."
|
|||
(setq mode-name "Machine")
|
||||
(setq gdb-overlay-arrow-position nil)
|
||||
(add-to-list 'overlay-arrow-variable-list 'gdb-overlay-arrow-position)
|
||||
(put 'gdb-overlay-arrow-position 'overlay-arrow-string "=>")
|
||||
(setq fringes-outside-margins t)
|
||||
(setq buffer-read-only t)
|
||||
(use-local-map gdb-assembler-mode-map)
|
||||
|
|
|
|||
|
|
@ -89,16 +89,27 @@ If SOFT is non-nil, returns nil if the symbol doesn't already exist."
|
|||
|
||||
(defvar gud-running nil
|
||||
"Non-nil if debuggee is running.
|
||||
Used to grey out relevant toolbar icons.")
|
||||
Used to grey out relevant togolbar icons.")
|
||||
|
||||
;; Use existing Info buffer, if possible.
|
||||
(defun gud-goto-info ()
|
||||
"Go to relevant Emacs info node."
|
||||
(interactive)
|
||||
(select-frame (make-frame))
|
||||
(require 'info)
|
||||
(if (memq gud-minor-mode '(gdbmi gdba))
|
||||
(Info-goto-node "(emacs)GDB Graphical Interface")
|
||||
(Info-goto-node "(emacs)Debuggers")))
|
||||
(let ((same-window-regexps same-window-regexps)
|
||||
(display-buffer-reuse-frames t))
|
||||
(catch 'info-found
|
||||
(walk-windows
|
||||
'(lambda (window)
|
||||
(if (eq (window-buffer window) (get-buffer "*info*"))
|
||||
(progn
|
||||
(setq same-window-regexps nil)
|
||||
(throw 'info-found nil))))
|
||||
nil 0)
|
||||
(require 'info)
|
||||
(select-frame (make-frame)))
|
||||
(if (memq gud-minor-mode '(gdbmi gdba))
|
||||
(Info-goto-node "(emacs)GDB Graphical Interface")
|
||||
(Info-goto-node "(emacs)Debuggers"))))
|
||||
|
||||
(easy-mmode-defmap gud-menu-map
|
||||
'(([help] "Info" . gud-goto-info)
|
||||
|
|
@ -1417,7 +1428,7 @@ and source-file directory for your debugger."
|
|||
|
||||
output))
|
||||
|
||||
(defcustom gud-pdb-command-name "pydb"
|
||||
(defcustom gud-pdb-command-name "pdb"
|
||||
"File name for executing the Python debugger.
|
||||
This should be an executable on your path, or an absolute file name."
|
||||
:type 'string
|
||||
|
|
@ -2518,7 +2529,6 @@ It is saved for when this flag is not set.")
|
|||
|
||||
(defvar gud-minor-mode-type nil)
|
||||
(defvar gud-overlay-arrow-position nil)
|
||||
(put 'gud-overlay-arrow-position 'overlay-arrow-string "=>")
|
||||
(add-to-list 'overlay-arrow-variable-list 'gud-overlay-arrow-position)
|
||||
|
||||
(defun gud-sentinel (proc msg)
|
||||
|
|
@ -2614,7 +2624,6 @@ Obeying it means displaying in another window the specified file and line."
|
|||
(widen)
|
||||
(goto-line line)
|
||||
(setq pos (point))
|
||||
(setq overlay-arrow-string "=>")
|
||||
(or gud-overlay-arrow-position
|
||||
(setq gud-overlay-arrow-position (make-marker)))
|
||||
(set-marker gud-overlay-arrow-position (point) (current-buffer)))
|
||||
|
|
|
|||
|
|
@ -555,14 +555,24 @@ The actual command ends at the end of the first \\(grouping\\)."
|
|||
|
||||
|
||||
|
||||
(defvar sh-here-document-word "EOF"
|
||||
(defcustom sh-here-document-word "EOF"
|
||||
"Word to delimit here documents.
|
||||
If the first character of this string is \"-\", this character will
|
||||
be removed from the string when it is used to close the here document.
|
||||
This convention is used by the Bash shell, for example, to indicate
|
||||
that leading tabs inside the here document should be ignored.
|
||||
Note that Emacs currently has no support for indenting inside here
|
||||
documents - you must insert literal tabs by hand.")
|
||||
If the first character of this string is \"-\", this is taken as
|
||||
part of the redirection operator, rather than part of the
|
||||
word (that is, \"<<-\" instead of \"<<\"). This is a feature
|
||||
used by some shells (for example Bash) to indicate that leading
|
||||
tabs inside the here document should be ignored. In this case,
|
||||
Emacs indents the initial body and end of the here document with
|
||||
tabs, to the same level as the start (note that apart from this
|
||||
there is no support for indentation of here documents). This
|
||||
will only work correctly if `sh-basic-offset' is a multiple of
|
||||
`tab-width'.
|
||||
|
||||
Any quote characters or leading whitespace in the word are
|
||||
removed when closing the here document."
|
||||
:type 'string
|
||||
:group 'sh-script)
|
||||
|
||||
|
||||
(defvar sh-test
|
||||
'((sh "[ ]" . 3)
|
||||
|
|
@ -3247,7 +3257,7 @@ t means to return a list of all possible completions of STRING.
|
|||
(let ((sh-add-buffer (current-buffer)))
|
||||
(list (completing-read "Variable: " 'sh-add-completer)
|
||||
(prefix-numeric-value current-prefix-arg))))
|
||||
(insert (sh-feature '((bash . "$[ ")
|
||||
(insert (sh-feature '((bash . "$(( ")
|
||||
(ksh88 . "$(( ")
|
||||
(posix . "$(( ")
|
||||
(rc . "`{expr $")
|
||||
|
|
@ -3256,7 +3266,7 @@ t means to return a list of all possible completions of STRING.
|
|||
(sh-remember-variable var)
|
||||
(if (< delta 0) " - " " + ")
|
||||
(number-to-string (abs delta))
|
||||
(sh-feature '((bash . " ]")
|
||||
(sh-feature '((bash . " ))")
|
||||
(ksh88 . " ))")
|
||||
(posix . " ))")
|
||||
(rc . "}")
|
||||
|
|
@ -3482,7 +3492,8 @@ option followed by a colon `:' if the option accepts an argument."
|
|||
"esac" >
|
||||
\n "done"
|
||||
> \n
|
||||
"shift " (sh-add "OPTIND" -1) \n))
|
||||
"shift " (sh-add "OPTIND" -1) \n
|
||||
"OPTIND=1" \n))
|
||||
|
||||
|
||||
|
||||
|
|
@ -3500,7 +3511,6 @@ option followed by a colon `:' if the option accepts an argument."
|
|||
(match-string 1))))))
|
||||
|
||||
|
||||
|
||||
(defun sh-maybe-here-document (arg)
|
||||
"Insert self. Without prefix, following unquoted `<' inserts here document.
|
||||
The document is bounded by `sh-here-document-word'."
|
||||
|
|
@ -3511,18 +3521,21 @@ The document is bounded by `sh-here-document-word'."
|
|||
(save-excursion
|
||||
(backward-char 2)
|
||||
(sh-quoted-p))
|
||||
(progn
|
||||
(let ((tabs (if (string-match "\\`-" sh-here-document-word)
|
||||
(make-string (/ (current-indentation) tab-width) ?\t)
|
||||
""))
|
||||
(delim (replace-regexp-in-string "['\"]" ""
|
||||
sh-here-document-word)))
|
||||
(insert sh-here-document-word)
|
||||
(or (eolp) (looking-at "[ \t]") (insert ? ))
|
||||
(end-of-line 1)
|
||||
(while
|
||||
(sh-quoted-p)
|
||||
(end-of-line 2))
|
||||
(newline)
|
||||
(insert ?\n tabs)
|
||||
(save-excursion
|
||||
(insert ?\n (substring
|
||||
sh-here-document-word
|
||||
(if (string-match "^-" sh-here-document-word) 1 0)))))))
|
||||
(insert ?\n tabs (replace-regexp-in-string
|
||||
"\\`-?[ \t]*" "" delim))))))
|
||||
|
||||
|
||||
;; various other commands
|
||||
|
|
@ -3574,7 +3587,7 @@ With an argument, deletes the backslashes.
|
|||
|
||||
This function does not modify the last line of the region if the region ends
|
||||
right at the start of the following line; it does not modify blank lines
|
||||
at the start of the region. So you can put the region around an entire
|
||||
at the start of the region. So you can put the region around an entire
|
||||
shell command and conveniently use this command."
|
||||
(interactive "r\nP")
|
||||
(save-excursion
|
||||
|
|
|
|||
|
|
@ -284,7 +284,9 @@ can be modified by the global variable `repeat-on-final-keystroke'."
|
|||
;; does not alter it.
|
||||
(let ((real-last-command real-last-command))
|
||||
(execute-kbd-macro real-last-command))
|
||||
(call-interactively real-last-command)))))
|
||||
(run-hooks 'pre-command-hook)
|
||||
(call-interactively real-last-command)
|
||||
(run-hooks 'post-command-hook)))))
|
||||
(when repeat-repeat-char
|
||||
;; A simple recursion here gets into trouble with max-lisp-eval-depth
|
||||
;; on long sequences of repetitions of a command like `forward-word'
|
||||
|
|
|
|||
|
|
@ -1279,7 +1279,9 @@ Return 0 if current buffer is not a mini-buffer."
|
|||
(defalias 'advertised-undo 'undo)
|
||||
|
||||
(defconst undo-equiv-table (make-hash-table :test 'eq :weakness t)
|
||||
"Table mapping redo records to the corresponding undo one.")
|
||||
"Table mapping redo records to the corresponding undo one.
|
||||
A redo record for undo-in-region maps to t.
|
||||
A redo record for ordinary undo maps to the following (earlier) undo.")
|
||||
|
||||
(defvar undo-in-region nil
|
||||
"Non-nil if `pending-undo-list' is not just a tail of `buffer-undo-list'.")
|
||||
|
|
@ -1339,7 +1341,7 @@ as an argument limits undo to changes within the current region."
|
|||
(message (if undo-in-region
|
||||
(if equiv "Redo in region!" "Undo in region!")
|
||||
(if equiv "Redo!" "Undo!"))))
|
||||
(when (and equiv undo-no-redo)
|
||||
(when (and (consp equiv) undo-no-redo)
|
||||
;; The equiv entry might point to another redo record if we have done
|
||||
;; undo-redo-undo-redo-... so skip to the very last equiv.
|
||||
(while (let ((next (gethash equiv undo-equiv-table)))
|
||||
|
|
@ -1350,10 +1352,13 @@ as an argument limits undo to changes within the current region."
|
|||
(prefix-numeric-value arg)
|
||||
1))
|
||||
;; Record the fact that the just-generated undo records come from an
|
||||
;; undo operation, so we can skip them later on.
|
||||
;; undo operation--that is, they are redo records.
|
||||
;; In the ordinary case (not within a region), map the redo
|
||||
;; record to the following undos.
|
||||
;; I don't know how to do that in the undo-in-region case.
|
||||
(unless undo-in-region
|
||||
(puthash buffer-undo-list pending-undo-list undo-equiv-table))
|
||||
(puthash buffer-undo-list
|
||||
(if undo-in-region t pending-undo-list)
|
||||
undo-equiv-table)
|
||||
;; Don't specify a position in the undo record for the undo command.
|
||||
;; Instead, undoing this should move point to where the change is.
|
||||
(let ((tail buffer-undo-list)
|
||||
|
|
@ -2547,7 +2552,7 @@ The argument is used for internal purposes; do not supply one."
|
|||
;; This is actually used in subr.el but defcustom does not work there.
|
||||
(defcustom yank-excluded-properties
|
||||
'(read-only invisible intangible field mouse-face help-echo local-map keymap
|
||||
yank-handler)
|
||||
yank-handler follow-link)
|
||||
"*Text properties to discard when yanking.
|
||||
The value should be a list of text properties to discard or t,
|
||||
which means to discard all text properties."
|
||||
|
|
|
|||
|
|
@ -719,10 +719,19 @@ opening the first frame (e.g. open a connection to the server).")
|
|||
(and command-line-args
|
||||
(setcdr command-line-args args)))
|
||||
|
||||
;; Under X Windows, this creates the X frame and deletes the terminal frame.
|
||||
;; Under X Window, this creates the X frame and deletes the terminal frame.
|
||||
(when (fboundp 'frame-initialize)
|
||||
(frame-initialize))
|
||||
|
||||
;; Turn off blinking cursor if so specified in X resources. This is here
|
||||
;; only because all other settings of no-blinking-cursor are here.
|
||||
(unless (or noninteractive
|
||||
emacs-basic-display
|
||||
(and (memq window-system '(x w32 mac))
|
||||
(not (member (x-get-resource "cursorBlink" "CursorBlink")
|
||||
'("off" "false")))))
|
||||
(setq no-blinking-cursor t))
|
||||
|
||||
;; If frame was created with a menu bar, set menu-bar-mode on.
|
||||
(unless (or noninteractive
|
||||
emacs-basic-display
|
||||
|
|
@ -742,6 +751,9 @@ opening the first frame (e.g. open a connection to the server).")
|
|||
(custom-reevaluate-setting 'blink-cursor-mode)
|
||||
(custom-reevaluate-setting 'normal-erase-is-backspace)
|
||||
|
||||
;; If you change the code below, you need to also change the
|
||||
;; corresponding code in the tooltip-mode defcustom. The two need
|
||||
;; to be equivalent under all conditions, or Custom will get confused.
|
||||
(unless (or noninteractive
|
||||
emacs-basic-display
|
||||
(not (display-graphic-p))
|
||||
|
|
@ -1067,15 +1079,15 @@ Each element in the list should be a list of strings or pairs
|
|||
:group 'initialization)
|
||||
|
||||
|
||||
(defcustom fancy-splash-delay 10
|
||||
(defcustom fancy-splash-delay 7
|
||||
"*Delay in seconds between splash screens."
|
||||
:group 'fancy-splash-screen
|
||||
:type 'integer)
|
||||
|
||||
|
||||
(defcustom fancy-splash-max-time 60
|
||||
(defcustom fancy-splash-max-time 30
|
||||
"*Show splash screens for at most this number of seconds.
|
||||
Values less than 60 seconds are ignored."
|
||||
Values less than twice `fancy-splash-delay' are ignored."
|
||||
:group 'fancy-splash-screen
|
||||
:type 'integer)
|
||||
|
||||
|
|
@ -1253,7 +1265,7 @@ mouse."
|
|||
mode-line-format (propertize "---- %b %-"
|
||||
'face '(:weight bold))
|
||||
fancy-splash-stop-time (+ (float-time)
|
||||
(max 60 fancy-splash-max-time))
|
||||
fancy-splash-max-time)
|
||||
timer (run-with-timer 0 fancy-splash-delay
|
||||
#'fancy-splash-screens-1
|
||||
splash-buffer))
|
||||
|
|
|
|||
73
lisp/term.el
73
lisp/term.el
|
|
@ -684,14 +684,13 @@ Buffer local variable.")
|
|||
(defvar term-ansi-at-save-user nil)
|
||||
(defvar term-ansi-at-save-pwd nil)
|
||||
(defvar term-ansi-at-save-anon nil)
|
||||
(defvar term-ansi-current-bold 0)
|
||||
(defvar term-ansi-current-bold nil)
|
||||
(defvar term-ansi-current-color 0)
|
||||
(defvar term-ansi-face-already-done 0)
|
||||
(defvar term-ansi-face-already-done nil)
|
||||
(defvar term-ansi-current-bg-color 0)
|
||||
(defvar term-ansi-current-underline 0)
|
||||
(defvar term-ansi-current-highlight 0)
|
||||
(defvar term-ansi-current-reverse 0)
|
||||
(defvar term-ansi-current-invisible 0)
|
||||
(defvar term-ansi-current-underline nil)
|
||||
(defvar term-ansi-current-reverse nil)
|
||||
(defvar term-ansi-current-invisible nil)
|
||||
|
||||
;;; Four should be enough, if you want more, just add. -mm
|
||||
(defvar term-terminal-more-parameters 0)
|
||||
|
|
@ -732,8 +731,7 @@ is buffer-local.")
|
|||
[ "Enable paging" term-pager-toggle (not term-pager-count)]
|
||||
[ "Disable paging" term-pager-toggle term-pager-count])))
|
||||
|
||||
(if term-mode-map
|
||||
nil
|
||||
(unless term-mode-map
|
||||
(setq term-mode-map (make-sparse-keymap))
|
||||
(define-key term-mode-map "\ep" 'term-previous-input)
|
||||
(define-key term-mode-map "\en" 'term-next-input)
|
||||
|
|
@ -1062,7 +1060,6 @@ Entry to this mode runs the hooks on `term-mode-hook'."
|
|||
(make-local-variable 'term-ansi-face-already-done)
|
||||
(make-local-variable 'term-ansi-current-bg-color)
|
||||
(make-local-variable 'term-ansi-current-underline)
|
||||
(make-local-variable 'term-ansi-current-highlight)
|
||||
(make-local-variable 'term-ansi-current-reverse)
|
||||
(make-local-variable 'term-ansi-current-invisible)
|
||||
|
||||
|
|
@ -2509,14 +2506,14 @@ See `term-prompt-regexp'."
|
|||
(defun term-horizontal-column ()
|
||||
(- (term-current-column) (term-start-line-column)))
|
||||
|
||||
;; Calls either vertical-motion or buffer-vertical-motion
|
||||
;; Calls either vertical-motion or term-buffer-vertical-motion
|
||||
(defmacro term-vertical-motion (count)
|
||||
(list 'funcall 'term-vertical-motion count))
|
||||
|
||||
;; An emulation of vertical-motion that is independent of having a window.
|
||||
;; Instead, it uses the term-width variable as the logical window width.
|
||||
|
||||
(defun buffer-vertical-motion (count)
|
||||
(defun term-buffer-vertical-motion (count)
|
||||
(cond ((= count 0)
|
||||
(move-to-column (* term-width (/ (current-column) term-width)))
|
||||
0)
|
||||
|
|
@ -2701,7 +2698,7 @@ See `term-prompt-regexp'."
|
|||
(setq term-vertical-motion (symbol-function 'vertical-motion))
|
||||
(term-check-size proc))
|
||||
(setq term-vertical-motion
|
||||
(symbol-function 'buffer-vertical-motion)))
|
||||
(symbol-function 'term-buffer-vertical-motion)))
|
||||
|
||||
(setq save-marker (copy-marker (process-mark proc)))
|
||||
|
||||
|
|
@ -3041,12 +3038,12 @@ See `term-prompt-regexp'."
|
|||
(setq term-current-column 1)
|
||||
(setq term-insert-mode nil)
|
||||
(setq term-current-face nil)
|
||||
(setq term-ansi-current-underline 0)
|
||||
(setq term-ansi-current-bold 0)
|
||||
(setq term-ansi-current-reverse 0)
|
||||
(setq term-ansi-current-underline nil)
|
||||
(setq term-ansi-current-bold nil)
|
||||
(setq term-ansi-current-reverse nil)
|
||||
(setq term-ansi-current-color 0)
|
||||
(setq term-ansi-current-invisible 0)
|
||||
(setq term-ansi-face-already-done 0)
|
||||
(setq term-ansi-current-invisible nil)
|
||||
(setq term-ansi-face-already-done nil)
|
||||
(setq term-ansi-current-bg-color 0))
|
||||
|
||||
;;; New function to deal with ansi colorized output, as you can see you can
|
||||
|
|
@ -3057,32 +3054,32 @@ See `term-prompt-regexp'."
|
|||
|
||||
;;; Bold (terminfo: bold)
|
||||
((eq parameter 1)
|
||||
(setq term-ansi-current-bold 1))
|
||||
(setq term-ansi-current-bold t))
|
||||
|
||||
;;; Underline
|
||||
((eq parameter 4)
|
||||
(setq term-ansi-current-underline 1))
|
||||
(setq term-ansi-current-underline t))
|
||||
|
||||
;;; Blink (unsupported by Emacs), will be translated to bold.
|
||||
;;; This may change in the future though.
|
||||
((eq parameter 5)
|
||||
(setq term-ansi-current-bold 1))
|
||||
(setq term-ansi-current-bold t))
|
||||
|
||||
;;; Reverse
|
||||
((eq parameter 7)
|
||||
(setq term-ansi-current-reverse 1))
|
||||
(setq term-ansi-current-reverse t))
|
||||
|
||||
;;; Invisible
|
||||
((eq parameter 8)
|
||||
(setq term-ansi-current-invisible 1))
|
||||
(setq term-ansi-current-invisible t))
|
||||
|
||||
;;; Reset underline (i.e. terminfo rmul)
|
||||
((eq parameter 24)
|
||||
(setq term-ansi-current-underline 0))
|
||||
(setq term-ansi-current-underline nil))
|
||||
|
||||
;;; Reset reverse (i.e. terminfo rmso)
|
||||
((eq parameter 27)
|
||||
(setq term-ansi-current-reverse 0))
|
||||
(setq term-ansi-current-reverse nil))
|
||||
|
||||
;;; Foreground
|
||||
((and (>= parameter 30) (<= parameter 37))
|
||||
|
|
@ -3103,12 +3100,12 @@ See `term-prompt-regexp'."
|
|||
;;; 0 (Reset) or unknown (reset anyway)
|
||||
(t
|
||||
(setq term-current-face nil)
|
||||
(setq term-ansi-current-underline 0)
|
||||
(setq term-ansi-current-bold 0)
|
||||
(setq term-ansi-current-reverse 0)
|
||||
(setq term-ansi-current-underline nil)
|
||||
(setq term-ansi-current-bold nil)
|
||||
(setq term-ansi-current-reverse nil)
|
||||
(setq term-ansi-current-color 0)
|
||||
(setq term-ansi-current-invisible 0)
|
||||
(setq term-ansi-face-already-done 1)
|
||||
(setq term-ansi-current-invisible nil)
|
||||
(setq term-ansi-face-already-done t)
|
||||
(setq term-ansi-current-bg-color 0)))
|
||||
|
||||
; (message "Debug: U-%d R-%d B-%d I-%d D-%d F-%d B-%d"
|
||||
|
|
@ -3121,9 +3118,9 @@ See `term-prompt-regexp'."
|
|||
; term-ansi-current-bg-color)
|
||||
|
||||
|
||||
(if (= term-ansi-face-already-done 0)
|
||||
(if (= term-ansi-current-reverse 1)
|
||||
(if (= term-ansi-current-invisible 1)
|
||||
(unless term-ansi-face-already-done
|
||||
(if term-ansi-current-reverse
|
||||
(if term-ansi-current-invisible
|
||||
(setq term-current-face
|
||||
(if (= term-ansi-current-color 0)
|
||||
(list :background
|
||||
|
|
@ -3145,13 +3142,13 @@ See `term-prompt-regexp'."
|
|||
(if (= term-ansi-current-bg-color 0)
|
||||
(face-background 'default)
|
||||
(elt ansi-term-color-vector term-ansi-current-bg-color))))
|
||||
(if (= term-ansi-current-bold 1)
|
||||
(when term-ansi-current-bold
|
||||
(setq term-current-face
|
||||
(append '(:weight bold) term-current-face)))
|
||||
(if (= term-ansi-current-underline 1)
|
||||
(when term-ansi-current-underline
|
||||
(setq term-current-face
|
||||
(append '(:underline t) term-current-face))))
|
||||
(if (= term-ansi-current-invisible 1)
|
||||
(if term-ansi-current-invisible
|
||||
(setq term-current-face
|
||||
(if (= term-ansi-current-bg-color 0)
|
||||
(list :background
|
||||
|
|
@ -3169,15 +3166,15 @@ See `term-prompt-regexp'."
|
|||
(elt ansi-term-color-vector term-ansi-current-color)
|
||||
:background
|
||||
(elt ansi-term-color-vector term-ansi-current-bg-color)))
|
||||
(if (= term-ansi-current-bold 1)
|
||||
(when term-ansi-current-bold
|
||||
(setq term-current-face
|
||||
(append '(:weight bold) term-current-face)))
|
||||
(if (= term-ansi-current-underline 1)
|
||||
(when term-ansi-current-underline
|
||||
(setq term-current-face
|
||||
(append '(:underline t) term-current-face))))))
|
||||
|
||||
;;; (message "Debug %S" term-current-face)
|
||||
(setq term-ansi-face-already-done 0))
|
||||
(setq term-ansi-face-already-done nil))
|
||||
|
||||
|
||||
;;; Handle a character assuming (eq terminal-state 2) -
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@
|
|||
;;(require 'select)
|
||||
(require 'menu-bar)
|
||||
(require 'fontset)
|
||||
(require 'x-dnd)
|
||||
(require 'dnd)
|
||||
|
||||
(defvar x-invocation-args)
|
||||
|
||||
|
|
@ -1085,13 +1085,38 @@ XConsortium: rgb.txt,v 10.41 94/02/20 18:39:36 rws Exp")
|
|||
(put 'escape 'ascii-character ?\e)
|
||||
|
||||
|
||||
;;;; Keysyms
|
||||
;;;; Script codes and coding systems
|
||||
(defconst mac-script-code-coding-systems
|
||||
'((0 . mac-roman) ; smRoman
|
||||
(1 . japanese-shift-jis) ; smJapanese
|
||||
(2 . chinese-big5) ; smTradChinese
|
||||
(3 . korean-iso-8bit) ; smKorean
|
||||
(7 . mac-cyrillic) ; smCyrillic
|
||||
(25 . chinese-iso-8bit) ; smSimpChinese
|
||||
(29 . mac-centraleurroman) ; smCentralEuroRoman
|
||||
)
|
||||
"Alist of Mac script codes vs Emacs coding systems.")
|
||||
|
||||
;; Define constant values to be set to mac-keyboard-text-encoding
|
||||
(defconst kTextEncodingMacRoman 0)
|
||||
(defconst kTextEncodingISOLatin1 513 "0x201")
|
||||
(defconst kTextEncodingISOLatin2 514 "0x202")
|
||||
(defconst mac-system-coding-system
|
||||
(let ((base (or (cdr (assq mac-system-script-code
|
||||
mac-script-code-coding-systems))
|
||||
'mac-roman)))
|
||||
(if (eq system-type 'darwin)
|
||||
base
|
||||
(coding-system-change-eol-conversion base 'mac)))
|
||||
"Coding system derived from the system script code.")
|
||||
|
||||
;;;; Keyboard layout/language change events
|
||||
(defun mac-handle-language-change (event)
|
||||
(interactive "e")
|
||||
(let ((coding-system
|
||||
(cdr (assq (car (cadr event)) mac-script-code-coding-systems))))
|
||||
(set-keyboard-coding-system (or coding-system 'mac-roman))
|
||||
;; MacJapanese maps reverse solidus to ?\x80.
|
||||
(if (eq coding-system 'japanese-shift-jis)
|
||||
(define-key key-translation-map [?\x80] "\\"))))
|
||||
|
||||
(define-key special-event-map [language-change] 'mac-handle-language-change)
|
||||
|
||||
;;;; Selections and cut buffers
|
||||
|
||||
|
|
@ -1139,21 +1164,14 @@ XConsortium: rgb.txt,v 10.41 94/02/20 18:39:36 rws Exp")
|
|||
|
||||
(setq frame-creation-function 'x-create-frame-with-faces)
|
||||
|
||||
(define-ccl-program ccl-encode-mac-roman-font
|
||||
`(0
|
||||
(if (r0 != ,(charset-id 'ascii))
|
||||
(if (r0 <= ?\x8f)
|
||||
(translate-character mac-roman-encoder r0 r1)
|
||||
((r1 <<= 7)
|
||||
(r1 |= r2)
|
||||
(translate-character mac-roman-encoder r0 r1)))))
|
||||
"CCL program for Mac Roman font")
|
||||
|
||||
(let
|
||||
((encoding-vector (make-vector 256 nil))
|
||||
(i 0)
|
||||
(vec ;; mac-centraleurroman (128..255) -> UCS mapping
|
||||
[ #x00C4 ;; 128:LATIN CAPITAL LETTER A WITH DIAERESIS
|
||||
(cp-make-coding-system
|
||||
mac-centraleurroman
|
||||
(apply
|
||||
'vector
|
||||
(mapcar
|
||||
(lambda (c) (decode-char 'ucs c))
|
||||
;; mac-centraleurroman (128..255) -> UCS mapping
|
||||
[ #x00C4 ;; 128:LATIN CAPITAL LETTER A WITH DIAERESIS
|
||||
#x0100 ;; 129:LATIN CAPITAL LETTER A WITH MACRON
|
||||
#x0101 ;; 130:LATIN SMALL LETTER A WITH MACRON
|
||||
#x00C9 ;; 131:LATIN CAPITAL LETTER E WITH ACUTE
|
||||
|
|
@ -1281,26 +1299,18 @@ XConsortium: rgb.txt,v 10.41 94/02/20 18:39:36 rws Exp")
|
|||
#x017C ;; 253:LATIN SMALL LETTER Z WITH DOT ABOVE
|
||||
#x0122 ;; 254:LATIN CAPITAL LETTER G WITH CEDILLA
|
||||
#x02C7 ;; 255:CARON
|
||||
])
|
||||
translation-table)
|
||||
(while (< i 128)
|
||||
(aset encoding-vector i i)
|
||||
(setq i (1+ i)))
|
||||
(while (< i 256)
|
||||
(aset encoding-vector i
|
||||
(decode-char 'ucs (aref vec (- i 128))))
|
||||
(setq i (1+ i)))
|
||||
(setq translation-table
|
||||
(make-translation-table-from-vector encoding-vector))
|
||||
;; (define-translation-table 'mac-centraleurroman-decoder translation-table)
|
||||
(define-translation-table 'mac-centraleurroman-encoder
|
||||
(char-table-extra-slot translation-table 0)))
|
||||
]))
|
||||
"Mac Central European Roman Encoding (MIME:x-mac-centraleurroman).")
|
||||
(coding-system-put 'mac-centraleurroman 'mime-charset 'x-mac-centraleurroman)
|
||||
|
||||
(let
|
||||
((encoding-vector (make-vector 256 nil))
|
||||
(i 0)
|
||||
(vec ;; mac-cyrillic (128..255) -> UCS mapping
|
||||
[ #x0410 ;; 128:CYRILLIC CAPITAL LETTER A
|
||||
(cp-make-coding-system
|
||||
mac-cyrillic
|
||||
(apply
|
||||
'vector
|
||||
(mapcar
|
||||
(lambda (c) (decode-char 'ucs c))
|
||||
;; mac-cyrillic (128..255) -> UCS mapping
|
||||
[ #x0410 ;; 128:CYRILLIC CAPITAL LETTER A
|
||||
#x0411 ;; 129:CYRILLIC CAPITAL LETTER BE
|
||||
#x0412 ;; 130:CYRILLIC CAPITAL LETTER VE
|
||||
#x0413 ;; 131:CYRILLIC CAPITAL LETTER GHE
|
||||
|
|
@ -1428,27 +1438,16 @@ XConsortium: rgb.txt,v 10.41 94/02/20 18:39:36 rws Exp")
|
|||
#x044D ;; 253:CYRILLIC SMALL LETTER E
|
||||
#x044E ;; 254:CYRILLIC SMALL LETTER YU
|
||||
#x20AC ;; 255:EURO SIGN
|
||||
])
|
||||
translation-table)
|
||||
(while (< i 128)
|
||||
(aset encoding-vector i i)
|
||||
(setq i (1+ i)))
|
||||
(while (< i 256)
|
||||
(aset encoding-vector i
|
||||
(decode-char 'ucs (aref vec (- i 128))))
|
||||
(setq i (1+ i)))
|
||||
(setq translation-table
|
||||
(make-translation-table-from-vector encoding-vector))
|
||||
;; (define-translation-table 'mac-cyrillic-decoder translation-table)
|
||||
(define-translation-table 'mac-cyrillic-encoder
|
||||
(char-table-extra-slot translation-table 0)))
|
||||
]))
|
||||
"Mac Cyrillic Encoding (MIME:x-mac-cyrillic).")
|
||||
(coding-system-put 'mac-cyrillic 'mime-charset 'x-mac-cyrillic)
|
||||
|
||||
(defvar mac-font-encoder-list
|
||||
'(("mac-roman" mac-roman-encoder
|
||||
ccl-encode-mac-roman-font "%s")
|
||||
("mac-centraleurroman" mac-centraleurroman-encoder
|
||||
("mac-centraleurroman" encode-mac-centraleurroman
|
||||
ccl-encode-mac-centraleurroman-font "%s ce")
|
||||
("mac-cyrillic" mac-cyrillic-encoder
|
||||
("mac-cyrillic" encode-mac-cyrillic
|
||||
ccl-encode-mac-cyrillic-font "%s cy")))
|
||||
|
||||
(let ((encoder-list
|
||||
|
|
@ -1468,24 +1467,34 @@ XConsortium: rgb.txt,v 10.41 94/02/20 18:39:36 rws Exp")
|
|||
(if mac-encoded
|
||||
(aset table c mac-encoded))))))))
|
||||
|
||||
(define-ccl-program ccl-encode-mac-roman-font
|
||||
`(0
|
||||
(if (r0 != ,(charset-id 'ascii))
|
||||
(if (r0 <= ?\x8f)
|
||||
(translate-character mac-roman-encoder r0 r1)
|
||||
((r1 <<= 7)
|
||||
(r1 |= r2)
|
||||
(translate-character mac-roman-encoder r0 r1)))))
|
||||
"CCL program for Mac Roman font")
|
||||
|
||||
(define-ccl-program ccl-encode-mac-centraleurroman-font
|
||||
`(0
|
||||
(if (r0 != ,(charset-id 'ascii))
|
||||
(if (r0 <= ?\x8f)
|
||||
(translate-character mac-centraleurroman-encoder r0 r1)
|
||||
(translate-character encode-mac-centraleurroman r0 r1)
|
||||
((r1 <<= 7)
|
||||
(r1 |= r2)
|
||||
(translate-character mac-centraleurroman-encoder r0 r1)))))
|
||||
(translate-character encode-mac-centraleurroman r0 r1)))))
|
||||
"CCL program for Mac Central European Roman font")
|
||||
|
||||
(define-ccl-program ccl-encode-mac-cyrillic-font
|
||||
`(0
|
||||
(if (r0 != ,(charset-id 'ascii))
|
||||
(if (r0 <= ?\x8f)
|
||||
(translate-character mac-cyrillic-encoder r0 r1)
|
||||
(translate-character encode-mac-cyrillic r0 r1)
|
||||
((r1 <<= 7)
|
||||
(r1 |= r2)
|
||||
(translate-character mac-cyrillic-encoder r0 r1)))))
|
||||
(translate-character encode-mac-cyrillic r0 r1)))))
|
||||
"CCL program for Mac Cyrillic font")
|
||||
|
||||
|
||||
|
|
@ -1648,8 +1657,8 @@ Switch to a buffer editing the last file dropped."
|
|||
(if (and (> start 0) (> end 0))
|
||||
(progn (set-mark start)
|
||||
(goto-char end)))))
|
||||
(x-dnd-handle-one-url window 'private
|
||||
(concat "file:" file-name))))
|
||||
(dnd-handle-one-url window 'private
|
||||
(concat "file:" file-name))))
|
||||
(car (cdr (cdr event)))))
|
||||
(raise-frame))
|
||||
|
||||
|
|
@ -1739,14 +1748,11 @@ Switch to a buffer editing the last file dropped."
|
|||
;; started (see run_mac_command in sysdep.c).
|
||||
(setq shell-file-name "sh")
|
||||
|
||||
;; To display filenames in Chinese or Japanese, replace mac-roman with
|
||||
;; big5 or sjis
|
||||
(setq file-name-coding-system 'mac-roman))
|
||||
|
||||
;; X Window emulation in macterm.c is not complete enough to start a
|
||||
;; frame without a minibuffer properly. Call this to tell ediff
|
||||
;; library to use a single frame.
|
||||
; (ediff-toggle-multiframe)
|
||||
;; Some system variables are encoded with the system script code.
|
||||
(dolist (v '(system-name
|
||||
emacs-build-system ; Mac OS 9 version cannot dump
|
||||
user-login-name user-real-login-name user-full-name))
|
||||
(set v (decode-coding-string (symbol-value v) mac-system-coding-system))))
|
||||
|
||||
;; If Emacs is started from the Finder, change the default directory
|
||||
;; to the user's home directory.
|
||||
|
|
@ -1763,7 +1769,5 @@ Switch to a buffer editing the last file dropped."
|
|||
;; or bold bitmap versions will not display these variants correctly.
|
||||
(setq scalable-fonts-allowed t)
|
||||
|
||||
;; (prefer-coding-system 'mac-roman)
|
||||
|
||||
;; arch-tag: 71dfcd14-cde8-4d66-b05c-85ec94fb23a6
|
||||
;;; mac-win.el ends here
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@
|
|||
(require 'faces)
|
||||
(require 'select)
|
||||
(require 'menu-bar)
|
||||
(require 'x-dnd)
|
||||
(require 'dnd)
|
||||
(require 'code-pages)
|
||||
|
||||
;; Conditional on new-fontset so bootstrapping works on non-GUI compiles
|
||||
|
|
@ -109,8 +109,8 @@ Switch to a buffer editing the last file dropped."
|
|||
(if (and (> x 0) (> y 0))
|
||||
(set-frame-selected-window nil window))
|
||||
(mapcar (lambda (file-name)
|
||||
(x-dnd-handle-one-url window 'private
|
||||
(concat "file:" file-name)))
|
||||
(dnd-handle-one-url window 'private
|
||||
(concat "file:" file-name)))
|
||||
(car (cdr (cdr event)))))
|
||||
(raise-frame)))
|
||||
|
||||
|
|
|
|||
|
|
@ -53,15 +53,85 @@
|
|||
(define-key map "\e[24~" [f12])
|
||||
(define-key map "\e[29~" [print])
|
||||
|
||||
(define-key map "\e[11;2~" [S-f1])
|
||||
(define-key map "\e[12;2~" [S-f2])
|
||||
(define-key map "\e[13;2~" [S-f3])
|
||||
(define-key map "\e[14;2~" [S-f4])
|
||||
(define-key map "\e[15;2~" [S-f5])
|
||||
(define-key map "\e[17;2~" [S-f6])
|
||||
(define-key map "\e[18;2~" [S-f7])
|
||||
(define-key map "\e[19;2~" [S-f8])
|
||||
(define-key map "\e[20;2~" [S-f9])
|
||||
(define-key map "\e[21;2~" [S-f10])
|
||||
(define-key map "\e[23;2~" [S-f11])
|
||||
(define-key map "\e[24;2~" [S-f12])
|
||||
|
||||
(define-key map "\e[11;5~" [C-f1])
|
||||
(define-key map "\e[12;5~" [C-f2])
|
||||
(define-key map "\e[13;5~" [C-f3])
|
||||
(define-key map "\e[14;5~" [C-f4])
|
||||
(define-key map "\e[15;5~" [C-f5])
|
||||
(define-key map "\e[17;5~" [C-f6])
|
||||
(define-key map "\e[18;5~" [C-f7])
|
||||
(define-key map "\e[19;5~" [C-f8])
|
||||
(define-key map "\e[20;5~" [C-f9])
|
||||
(define-key map "\e[21;5~" [C-f10])
|
||||
(define-key map "\e[23;5~" [C-f11])
|
||||
(define-key map "\e[24;5~" [C-f12])
|
||||
|
||||
(define-key map "\e[11;6~" [C-S-f1])
|
||||
(define-key map "\e[12;6~" [C-S-f2])
|
||||
(define-key map "\e[13;6~" [C-S-f3])
|
||||
(define-key map "\e[14;6~" [C-S-f4])
|
||||
(define-key map "\e[15;6~" [C-S-f5])
|
||||
(define-key map "\e[17;6~" [C-S-f6])
|
||||
(define-key map "\e[18;6~" [C-S-f7])
|
||||
(define-key map "\e[19;6~" [C-S-f8])
|
||||
(define-key map "\e[20;6~" [C-S-f9])
|
||||
(define-key map "\e[21;6~" [C-S-f10])
|
||||
(define-key map "\e[23;6~" [C-S-f11])
|
||||
(define-key map "\e[24;6~" [C-S-f12])
|
||||
|
||||
(define-key map "\e[11;3~" [A-f1])
|
||||
(define-key map "\e[12;3~" [A-f2])
|
||||
(define-key map "\e[13;3~" [A-f3])
|
||||
(define-key map "\e[14;3~" [A-f4])
|
||||
(define-key map "\e[15;3~" [A-f5])
|
||||
(define-key map "\e[17;3~" [A-f6])
|
||||
(define-key map "\e[18;3~" [A-f7])
|
||||
(define-key map "\e[19;3~" [A-f8])
|
||||
(define-key map "\e[20;3~" [A-f9])
|
||||
(define-key map "\e[21;3~" [A-f10])
|
||||
(define-key map "\e[23;3~" [A-f11])
|
||||
(define-key map "\e[24;3~" [A-f12])
|
||||
|
||||
(define-key map "\e[1;2A" [S-up])
|
||||
(define-key map "\e[1;2B" [S-down])
|
||||
(define-key map "\e[1;2C" [S-right])
|
||||
(define-key map "\e[1;2D" [S-left])
|
||||
(define-key map "\e[1;2F" [S-end])
|
||||
(define-key map "\e[1;2H" [S-home])
|
||||
|
||||
(define-key map "\e[1;5A" [C-up])
|
||||
(define-key map "\e[1;5B" [C-down])
|
||||
(define-key map "\e[1;5C" [C-right])
|
||||
(define-key map "\e[1;5D" [C-left])
|
||||
(define-key map "\e[1;5F" [C-end])
|
||||
(define-key map "\e[1;5H" [C-home])
|
||||
|
||||
(define-key map "\e[1;6A" [C-S-up])
|
||||
(define-key map "\e[1;6B" [C-S-down])
|
||||
(define-key map "\e[1;6C" [C-S-right])
|
||||
(define-key map "\e[1;6D" [C-S-left])
|
||||
(define-key map "\e[1;6F" [C-S-end])
|
||||
(define-key map "\e[1;6H" [C-S-home])
|
||||
|
||||
(define-key map "\e[1;3A" [A-up])
|
||||
(define-key map "\e[1;3B" [A-down])
|
||||
(define-key map "\e[1;3C" [A-right])
|
||||
(define-key map "\e[1;3D" [A-left])
|
||||
(define-key map "\e[1;3F" [A-end])
|
||||
(define-key map "\e[1;3H" [A-home])
|
||||
|
||||
(define-key map "\e[2;2~" [S-insert])
|
||||
(define-key map "\e[3;2~" [S-delete])
|
||||
|
|
@ -73,6 +143,16 @@
|
|||
(define-key map "\e[5;5~" [C-prior])
|
||||
(define-key map "\e[6;5~" [C-next])
|
||||
|
||||
(define-key map "\e[2;6~" [C-S-insert])
|
||||
(define-key map "\e[3;6~" [C-S-delete])
|
||||
(define-key map "\e[5;6~" [C-S-prior])
|
||||
(define-key map "\e[6;6~" [C-S-next])
|
||||
|
||||
(define-key map "\e[2;3~" [A-insert])
|
||||
(define-key map "\e[3;3~" [A-delete])
|
||||
(define-key map "\e[5;3~" [A-prior])
|
||||
(define-key map "\e[6;3~" [A-next])
|
||||
|
||||
(define-key map "\eOA" [up])
|
||||
(define-key map "\eOB" [down])
|
||||
(define-key map "\eOC" [right])
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -139,10 +139,8 @@ only tooltips in the buffer containing the overlay arrow."
|
|||
:tag "GUD buffers predicate"
|
||||
:group 'tooltip)
|
||||
|
||||
(defcustom tooltip-use-echo-area nil
|
||||
"Use the echo area instead of tooltip frames.
|
||||
This is only relevant GUD display, since otherwise it is equivalent to
|
||||
turning off Tooltip mode."
|
||||
(defcustom tooltip-gud-echo-area nil
|
||||
"Use the echo area instead of frames for GUD tooltips."
|
||||
:type 'boolean
|
||||
:tag "Use echo area"
|
||||
:group 'tooltip)
|
||||
|
|
@ -187,6 +185,12 @@ This might return nil if the event did not occur over a buffer."
|
|||
"Toggle Tooltip display.
|
||||
With ARG, turn tooltip mode on if and only if ARG is positive."
|
||||
:global t
|
||||
;; If you change the :init-value below, you also need to change the
|
||||
;; corresponding code in startup.el.
|
||||
:init-value (not (or noninteractive
|
||||
emacs-quick-startup
|
||||
(not (display-graphic-p))
|
||||
(not (fboundp 'x-show-tip))))
|
||||
:group 'tooltip
|
||||
(unless (or (null tooltip-mode) (fboundp 'x-show-tip))
|
||||
(error "Sorry, tooltips are not yet available on this system"))
|
||||
|
|
@ -285,17 +289,19 @@ change the existing association. Value is the resulting alist."
|
|||
(push (cons key value) alist))
|
||||
alist))
|
||||
|
||||
(defun tooltip-show (text)
|
||||
(defun tooltip-show (text gud-tip)
|
||||
"Show a tooltip window displaying TEXT.
|
||||
|
||||
Text larger than `x-max-tooltip-size' (which see) is clipped.
|
||||
Text larger than `x-max-tooltip-size' is clipped.
|
||||
|
||||
If the alist in `tooltip-frame-parameters' includes `left' and `top'
|
||||
parameters, they determine the x and y position where the tooltip
|
||||
is displayed. Otherwise, the tooltip pops at offsets specified by
|
||||
`tooltip-x-offset' and `tooltip-y-offset' from the current mouse
|
||||
position."
|
||||
(if tooltip-use-echo-area
|
||||
position.
|
||||
|
||||
GUD-TIP is t if the tooltip is from a GUD session and nil otherwise."
|
||||
(if (and gud-tip tooltip-gud-echo-area)
|
||||
(message "%s" text)
|
||||
(condition-case error
|
||||
(let ((params (copy-sequence tooltip-frame-parameters))
|
||||
|
|
@ -411,7 +417,7 @@ This event can be examined by forms in TOOLTIP-GUD-DISPLAY.")
|
|||
(defun tooltip-gud-process-output (process output)
|
||||
"Process debugger output and show it in a tooltip window."
|
||||
(set-process-filter process tooltip-gud-original-filter)
|
||||
(tooltip-show (tooltip-strip-prompt process output)))
|
||||
(tooltip-show (tooltip-strip-prompt process output) t))
|
||||
|
||||
(defun tooltip-gud-print-command (expr)
|
||||
"Return a suitable command to print the expression EXPR.
|
||||
|
|
@ -457,8 +463,8 @@ This function must return nil if it doesn't handle EVENT."
|
|||
(tooltip-show
|
||||
(with-current-buffer (gdb-get-buffer 'gdb-partial-output-buffer)
|
||||
(let ((string (buffer-string)))
|
||||
;; remove newline for tooltip-use-echo-area
|
||||
(substring string 0 (- (length string) 1))))))
|
||||
;; remove newline for tooltip-gud-echo-area
|
||||
(substring string 0 (- (length string) 1)))) t))
|
||||
|
||||
|
||||
;;; Tooltip help.
|
||||
|
|
@ -491,7 +497,7 @@ This is installed on the hook `tooltip-hook', which is run when
|
|||
the timer with ID `tooltip-timeout-id' fires.
|
||||
Value is non-nil if this function handled the tip."
|
||||
(when (stringp tooltip-help-message)
|
||||
(tooltip-show tooltip-help-message)
|
||||
(tooltip-show tooltip-help-message nil)
|
||||
t))
|
||||
|
||||
(provide 'tooltip)
|
||||
|
|
|
|||
173
lisp/wdired.el
173
lisp/wdired.el
|
|
@ -31,8 +31,8 @@
|
|||
;;
|
||||
;; Have you ever wished to use C-x r t (string-rectangle), M-%
|
||||
;; (query-replace), M-c (capitalize-word), etc. to change the name of
|
||||
;; the files in a "dired" buffer? Now you can do this. All the power
|
||||
;; of emacs commands are available to renaming files!
|
||||
;; the files in a "dired" buffer? Now you can do this. All the power
|
||||
;; of Emacs commands are available to renaming files!
|
||||
;;
|
||||
;; This package provides a function that makes the filenames of a a
|
||||
;; dired buffer editable, by changing the buffer mode (which inhibits
|
||||
|
|
@ -40,7 +40,7 @@
|
|||
;; one or more files and directories, and when you press C-c C-c, the
|
||||
;; renaming takes effect and you are back to dired mode.
|
||||
;;
|
||||
;; Another things you can do with wdired:
|
||||
;; Another things you can do with WDired:
|
||||
;;
|
||||
;; - To move files to another directory (by typing their path,
|
||||
;; absolute or relative, as a part of the new filename).
|
||||
|
|
@ -49,21 +49,16 @@
|
|||
;;
|
||||
;; - To change the permission bits of the filenames (in systems with a
|
||||
;; working unix-alike `dired-chmod-program'). See and customize the
|
||||
;; variable `wdired-allow-to-change-permissions'. To change a single
|
||||
;; variable `wdired-allow-to-change-permissions'. To change a single
|
||||
;; char (toggling between its two more usual values) you can press
|
||||
;; the space bar over it or left-click the mouse. To set any char to
|
||||
;; the space bar over it or left-click the mouse. To set any char to
|
||||
;; an specific value (this includes the SUID, SGID and STI bits) you
|
||||
;; can use the key labeled as the letter you want. Please note that
|
||||
;; can use the key labeled as the letter you want. Please note that
|
||||
;; permissions of the links cannot be changed in that way, because
|
||||
;; the change would affect to their targets, and this would not be
|
||||
;; WYSIWYG :-).
|
||||
;;
|
||||
;; - To mark files for deletion, by deleting their whole filename.
|
||||
;;
|
||||
;; I do not have a URL to hang wdired, but you can use the one below
|
||||
;; to find the latest version:
|
||||
;;
|
||||
;; http://groups.google.com/groups?as_ugroup=gnu.emacs.sources&as_q=wdired
|
||||
|
||||
;;; Installation:
|
||||
|
||||
|
|
@ -75,21 +70,19 @@
|
|||
;; (require 'wdired)
|
||||
;; (define-key dired-mode-map "r" 'wdired-change-to-wdired-mode)
|
||||
;;
|
||||
;; This is recommended way for faster emacs startup time and lower
|
||||
;; memory consumption, but remind to add these lines before dired.el
|
||||
;; gets loaded (i.e., near the beginning of your .emacs file):
|
||||
;; This is the recommended way for faster Emacs startup time and lower
|
||||
;; memory consumption:
|
||||
;;
|
||||
;; (autoload 'wdired-change-to-wdired-mode "wdired")
|
||||
;; (add-hook 'dired-load-hook
|
||||
;; (eval-after-load "dired"
|
||||
;; '(lambda ()
|
||||
;; (define-key dired-mode-map "r" 'wdired-change-to-wdired-mode)
|
||||
;; (define-key dired-mode-map
|
||||
;; [menu-bar immediate wdired-change-to-wdired-mode]
|
||||
;; '("Edit File Names" . wdired-change-to-wdired-mode))))
|
||||
;;
|
||||
;;
|
||||
;; Type "M-x customize-group RET wdired" if you want make changes to
|
||||
;; the default behavior.
|
||||
;; Type "M-x customize-group RET wdired" if you want to make changes
|
||||
;; to the default behavior.
|
||||
|
||||
;;; Usage:
|
||||
|
||||
|
|
@ -103,60 +96,12 @@
|
|||
|
||||
;;; Change Log:
|
||||
|
||||
;; From 1.9 to 1.91
|
||||
;;
|
||||
;; - Fixed a bug (introduced in 1.9) so now files can be marked for
|
||||
;; deletion again, by deleting their whole filename.
|
||||
|
||||
;; From 1.8 to 1.9
|
||||
;;
|
||||
;; - Another alternative way of editing permissions allowed, see
|
||||
;; `wdired-allow-to-change-permissions' for details.
|
||||
;;
|
||||
;; - Now wdired doesn't rely on regexp so much. As a consequence of
|
||||
;; this, you can add newlines to filenames and symlinks targets
|
||||
;; (although this is not very usual, IMHO). Please note that dired
|
||||
;; (at least in Emacs 21.1 and previous) does not work very well
|
||||
;; with filenames with newlines in them, so RET is deactivated in
|
||||
;; wdired mode. But you can activate it if you want.
|
||||
;;
|
||||
;; - Now `upcase-word' `capitalize-word' and `downcase-word' are not
|
||||
;; advised to work better with wdired mode, but the keys bound to
|
||||
;; them use wdired versions of those commands.
|
||||
;;
|
||||
;; - Now "undo" actions are not inherited from wdired mode when
|
||||
;; changing to dired mode.
|
||||
;;
|
||||
;; - Code and documentation cleanups.
|
||||
;;
|
||||
;; - Fixed a bug that was making wdired to fail on users with
|
||||
;; `dired-backup-overwrite' set to t.
|
||||
;;
|
||||
;; - C-c C-[ now abort changes.
|
||||
|
||||
;; From 1.7 to 1.8
|
||||
;;
|
||||
;; - Now permission (access-control) bits of the files can be changed.
|
||||
;; Please see the commentary section and the custom variable
|
||||
;; `wdired-allow-to-change-permissions' for details.
|
||||
;;
|
||||
;; - Added another possible value for the variable
|
||||
;; `wdired-always-move-to-filename-beginning', useful to change
|
||||
;; permission bits of several files without the cursor jumping to
|
||||
;; filenames when changing lines.
|
||||
|
||||
;; From 0.1 to 1.7
|
||||
|
||||
;; - I've moved the list of changes to another file, because it was
|
||||
;; huge. Ask me for it or search older versions in google.
|
||||
|
||||
;;; TODO:
|
||||
|
||||
;; - Make it to work in XEmacs. Any volunteer?
|
||||
;; Google is your friend (previous versions with complete changelogs
|
||||
;; were posted to gnu.emacs.sources)
|
||||
|
||||
;;; Code:
|
||||
|
||||
(defvar dired-backup-overwrite) ; Only in emacs 20.x this is a custom var
|
||||
(defvar dired-backup-overwrite) ; Only in Emacs 20.x this is a custom var
|
||||
(eval-when-compile
|
||||
(set (make-local-variable 'byte-compile-dynamic) t))
|
||||
|
||||
|
|
@ -170,22 +115,22 @@
|
|||
:group 'dired)
|
||||
|
||||
(defcustom wdired-use-interactive-rename nil
|
||||
"*If t, confirmation is required before actually rename the files.
|
||||
Confirmation is required also for overwriting files. If nil, no
|
||||
confirmation is required for change the file names, and the variable
|
||||
`wdired-is-ok-overwrite' is used to see if it is ok to overwrite files
|
||||
without asking."
|
||||
"*If non-nil, WDired requires confirmation before actually renaming files.
|
||||
If nil, WDired doesn't require confirmation to change the file names,
|
||||
and the variable `wdired-confirm-overwrite' controls whether it is ok
|
||||
to overwrite files without asking."
|
||||
:type 'boolean
|
||||
:group 'wdired)
|
||||
|
||||
(defcustom wdired-is-ok-overwrite nil
|
||||
"*If non-nil the renames can overwrite files without asking.
|
||||
This variable is used only if `wdired-use-interactive-rename' is nil."
|
||||
(defcustom wdired-confirm-overwrite t
|
||||
"*If nil the renames can overwrite files without asking.
|
||||
This variable has no effect at all if `wdired-use-interactive-rename'
|
||||
is not nil."
|
||||
:type 'boolean
|
||||
:group 'wdired)
|
||||
|
||||
(defcustom wdired-always-move-to-filename-beginning nil
|
||||
"*If t the \"up\" and \"down\" movement is done as in dired mode.
|
||||
(defcustom wdired-use-dired-vertical-movement nil
|
||||
"*If t, the \"up\" and \"down\" movement works as in Dired mode.
|
||||
That is, always move the point to the beginning of the filename at line.
|
||||
|
||||
If `sometimes, only move to the beginning of filename if the point is
|
||||
|
|
@ -199,20 +144,20 @@ If nil, \"up\" and \"down\" movement is done as in any other buffer."
|
|||
:group 'wdired)
|
||||
|
||||
(defcustom wdired-allow-to-redirect-links t
|
||||
"*If non-nil, the target of the symbolic links can be changed also.
|
||||
"*If non-nil, the target of the symbolic links are editable.
|
||||
In systems without symbolic links support, this variable has no effect
|
||||
at all."
|
||||
:type 'boolean
|
||||
:group 'wdired)
|
||||
|
||||
(defcustom wdired-allow-to-change-permissions nil
|
||||
"*If non-nil, the permissions bits of the files can be changed also.
|
||||
"*If non-nil, the permissions bits of the files are editable.
|
||||
|
||||
If t, to change a single bit, put the cursor over it and press the
|
||||
space bar, or left click over it. You can also hit the letter you want
|
||||
to set: if this value is allowed, the character in the buffer will be
|
||||
changed. Anyway, the point is advanced one position, so, for example,
|
||||
you can keep the \"x\" key pressed to give execution permissions to
|
||||
you can keep the <x> key pressed to give execution permissions to
|
||||
everybody to that file.
|
||||
|
||||
If `advanced, the bits are freely editable. You can use
|
||||
|
|
@ -220,7 +165,7 @@ If `advanced, the bits are freely editable. You can use
|
|||
newlines), but if you want your changes to be useful, you better put a
|
||||
intelligible value.
|
||||
|
||||
Anyway, the real change of the permissions is done with the external
|
||||
Anyway, the real change of the permissions is done by the external
|
||||
program `dired-chmod-program', which must exist."
|
||||
:type '(choice (const :tag "Not allowed" nil)
|
||||
(const :tag "Toggle/set bits" t)
|
||||
|
|
@ -233,9 +178,9 @@ program `dired-chmod-program', which must exist."
|
|||
(define-key map "\C-c\C-c" 'wdired-finish-edit)
|
||||
(define-key map "\C-c\C-k" 'wdired-abort-changes)
|
||||
(define-key map "\C-c\C-[" 'wdired-abort-changes)
|
||||
(define-key map "\C-m" 'wdired-newline)
|
||||
(define-key map "\C-j" 'wdired-newline)
|
||||
(define-key map "\C-o" 'wdired-newline)
|
||||
(define-key map "\C-m" 'ignore)
|
||||
(define-key map "\C-j" 'ignore)
|
||||
(define-key map "\C-o" 'ignore)
|
||||
(define-key map [up] 'wdired-previous-line)
|
||||
(define-key map "\C-p" 'wdired-previous-line)
|
||||
(define-key map [down] 'wdired-next-line)
|
||||
|
|
@ -261,7 +206,7 @@ program `dired-chmod-program', which must exist."
|
|||
map))
|
||||
|
||||
(defvar wdired-mode-hook nil
|
||||
"Hook run when changing to wdired mode.")
|
||||
"Hooks run when changing to WDired mode.")
|
||||
|
||||
;; Local variables (put here to avoid compilation gripes)
|
||||
(defvar wdired-col-perm) ;; Column where the permission bits start
|
||||
|
|
@ -271,15 +216,15 @@ program `dired-chmod-program', which must exist."
|
|||
(defun wdired-mode ()
|
||||
"\\<wdired-mode-map>File Names Editing mode.
|
||||
|
||||
Press \\[wdired-finish-edit] to make the changes to take effect and
|
||||
exit. To abort the edit, use \\[wdired-abort-changes].
|
||||
Press \\[wdired-finish-edit] to make the changes to take effect
|
||||
and exit. To abort the edit, use \\[wdired-abort-changes].
|
||||
|
||||
In this mode you can edit the names of the files, the target of the
|
||||
links and the permission bits of the files. You can `customize-group'
|
||||
wdired.
|
||||
In this mode you can edit the names of the files, the target of
|
||||
the links and the permission bits of the files. You can use
|
||||
\\[customize-group] RET wdired to customize WDired behavior.
|
||||
|
||||
Editing things out of the filenames, or adding or deleting lines is
|
||||
not allowed, because the rest of the buffer is read-only."
|
||||
The only editable texts in a WDired buffer are filenames,
|
||||
symbolic link targets, and filenames permission."
|
||||
(interactive)
|
||||
(error "This mode can be enabled only by `wdired-change-to-wdired-mode'"))
|
||||
(put 'wdired-mode 'mode-class 'special)
|
||||
|
|
@ -288,8 +233,10 @@ not allowed, because the rest of the buffer is read-only."
|
|||
;;;###autoload
|
||||
(defun wdired-change-to-wdired-mode ()
|
||||
"Put a dired buffer in a mode in which filenames are editable.
|
||||
In this mode the names of the files can be changed, and after
|
||||
typing C-c C-c the files and directories in disk are renamed.
|
||||
\\<wdired-mode-map>
|
||||
This mode allows the user to change the names of the files, and after
|
||||
typing \\[wdired-finish-edit] Emacs renames the files and directories
|
||||
in disk.
|
||||
|
||||
See `wdired-mode'."
|
||||
(interactive)
|
||||
|
|
@ -302,7 +249,7 @@ See `wdired-mode'."
|
|||
(dired-unadvertise default-directory)
|
||||
(add-hook 'kill-buffer-hook 'wdired-check-kill-buffer nil t)
|
||||
(setq major-mode 'wdired-mode)
|
||||
(setq mode-name "Edit filenames")
|
||||
(setq mode-name "Editable Dired")
|
||||
(setq revert-buffer-function 'wdired-revert)
|
||||
;; I temp disable undo for performance: since I'm going to clear the
|
||||
;; undo list, it can save more than a 9% of time with big
|
||||
|
|
@ -359,7 +306,7 @@ or \\[wdired-abort-changes] to abort changes")))
|
|||
(defun wdired-get-filename (&optional no-dir old)
|
||||
"Return the filename at line.
|
||||
Similar to `dired-get-filename' but it doesn't rely on regexps. It
|
||||
relies on wdired buffer's properties. Optional arg NO-DIR with value
|
||||
relies on WDired buffer's properties. Optional arg NO-DIR with value
|
||||
non-nil means don't include directory. Optional arg OLD with value
|
||||
non-nil means return old filename."
|
||||
;; FIXME: Use dired-get-filename's new properties.
|
||||
|
|
@ -411,7 +358,7 @@ non-nil means return old filename."
|
|||
"Actually rename files based on your editing in the Dired buffer."
|
||||
(interactive)
|
||||
(wdired-change-to-dired-mode)
|
||||
(let ((overwrite (or wdired-is-ok-overwrite 1))
|
||||
(let ((overwrite (or (not wdired-confirm-overwrite) 1))
|
||||
(changes nil)
|
||||
(files-deleted nil)
|
||||
(errors 0)
|
||||
|
|
@ -510,12 +457,13 @@ non-nil means return old filename."
|
|||
(forward-line)))))
|
||||
|
||||
(defun wdired-customize ()
|
||||
"Customize wdired options."
|
||||
"Customize WDired options."
|
||||
(interactive)
|
||||
(customize-apropos "wdired" 'groups))
|
||||
|
||||
(defun wdired-revert (&optional arg noconfirm)
|
||||
"Discard changes in the buffer and update the changes in the disk."
|
||||
"Discard changes in the buffer and update it based on changes on disk.
|
||||
Optional arguments are ignored."
|
||||
(wdired-change-to-dired-mode)
|
||||
(revert-buffer)
|
||||
(wdired-change-to-wdired-mode))
|
||||
|
|
@ -529,12 +477,12 @@ non-nil means return old filename."
|
|||
|
||||
(defun wdired-next-line (arg)
|
||||
"Move down lines then position at filename or the current column.
|
||||
See `wdired-always-move-to-filename-beginning'. Optional prefix ARG
|
||||
See `wdired-use-dired-vertical-movement'. Optional prefix ARG
|
||||
says how many lines to move; default is one line."
|
||||
(interactive "p")
|
||||
(next-line arg)
|
||||
(if (or (eq wdired-always-move-to-filename-beginning t)
|
||||
(and wdired-always-move-to-filename-beginning
|
||||
(if (or (eq wdired-use-dired-vertical-movement t)
|
||||
(and wdired-use-dired-vertical-movement
|
||||
(< (current-column)
|
||||
(save-excursion (dired-move-to-filename)
|
||||
(current-column)))))
|
||||
|
|
@ -542,22 +490,17 @@ says how many lines to move; default is one line."
|
|||
|
||||
(defun wdired-previous-line (arg)
|
||||
"Move up lines then position at filename or the current column.
|
||||
See `wdired-always-move-to-filename-beginning'. Optional prefix ARG
|
||||
See `wdired-use-dired-vertical-movement'. Optional prefix ARG
|
||||
says how many lines to move; default is one line."
|
||||
(interactive "p")
|
||||
(previous-line arg)
|
||||
(if (or (eq wdired-always-move-to-filename-beginning t)
|
||||
(and wdired-always-move-to-filename-beginning
|
||||
(if (or (eq wdired-use-dired-vertical-movement t)
|
||||
(and wdired-use-dired-vertical-movement
|
||||
(< (current-column)
|
||||
(save-excursion (dired-move-to-filename)
|
||||
(current-column)))))
|
||||
(dired-move-to-filename)))
|
||||
|
||||
;; dired doesn't works well with newlines, so ...
|
||||
(defun wdired-newline ()
|
||||
"Do nothing."
|
||||
(interactive))
|
||||
|
||||
;; Put the needed properties to allow the user to change links' targets
|
||||
(defun wdired-preprocess-symlinks ()
|
||||
(let ((inhibit-read-only t))
|
||||
|
|
@ -634,19 +577,19 @@ If OLD, return the old target. If MOVE, move point before it."
|
|||
(setq arg 0))))))))
|
||||
|
||||
(defun wdired-downcase-word (arg)
|
||||
"Wdired version of `downcase-word'.
|
||||
"WDired version of `downcase-word'.
|
||||
Like original function but it skips read-only words."
|
||||
(interactive "p")
|
||||
(wdired-xcase-word 'downcase-word arg))
|
||||
|
||||
(defun wdired-upcase-word (arg)
|
||||
"Wdired version of `upcase-word'.
|
||||
"WDired version of `upcase-word'.
|
||||
Like original function but it skips read-only words."
|
||||
(interactive "p")
|
||||
(wdired-xcase-word 'upcase-word arg))
|
||||
|
||||
(defun wdired-capitalize-word (arg)
|
||||
"Wdired version of `capitalize-word'.
|
||||
"WDired version of `capitalize-word'.
|
||||
Like original function but it skips read-only words."
|
||||
(interactive "p")
|
||||
(wdired-xcase-word 'capitalize-word arg))
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@
|
|||
|
||||
;;; Code:
|
||||
|
||||
(defvar whitespace-version "3.4" "Version of the whitespace library.")
|
||||
(defvar whitespace-version "3.5" "Version of the whitespace library.")
|
||||
|
||||
(defvar whitespace-all-buffer-files nil
|
||||
"An associated list of buffers and files checked for whitespace cleanliness.
|
||||
|
|
@ -599,7 +599,7 @@ whitespace problems."
|
|||
(setq pmax (point))
|
||||
(if (equal pmin pmax)
|
||||
(progn
|
||||
(whitespace-highlight-the-space pmin pmax)
|
||||
(whitespace-highlight-the-space pmin (1+ pmax))
|
||||
t)
|
||||
nil))))
|
||||
|
||||
|
|
@ -637,7 +637,7 @@ whitespace problems."
|
|||
(setq pmax (point))
|
||||
(if (equal pmin pmax)
|
||||
(progn
|
||||
(whitespace-highlight-the-space pmin pmax)
|
||||
(whitespace-highlight-the-space (- pmin 1) pmax)
|
||||
t)
|
||||
nil))
|
||||
nil))))
|
||||
|
|
@ -733,12 +733,11 @@ Also with whitespaces whose testing has been turned off."
|
|||
"Highlight the current line, unhighlighting a previously jumped to line."
|
||||
(if whitespace-display-spaces-in-color
|
||||
(let ((ol (whitespace-make-overlay b e)))
|
||||
(whitespace-unhighlight-the-space)
|
||||
(push ol whitespace-highlighted-space)
|
||||
(whitespace-overlay-put ol 'face 'whitespace-highlight-face))))
|
||||
;; (add-hook 'pre-command-hook 'whitespace-unhighlight-the-space))
|
||||
|
||||
(defun whitespace-unhighlight-the-space ()
|
||||
(defun whitespace-unhighlight-the-space()
|
||||
"Unhighlight the currently highlight line."
|
||||
(if (and whitespace-display-spaces-in-color whitespace-highlighted-space)
|
||||
(progn
|
||||
|
|
|
|||
177
lisp/x-dnd.el
177
lisp/x-dnd.el
|
|
@ -31,9 +31,9 @@
|
|||
|
||||
;;; Code:
|
||||
|
||||
(require 'dnd)
|
||||
|
||||
;;; Customizable variables
|
||||
|
||||
|
||||
(defcustom x-dnd-test-function 'x-dnd-default-test-function
|
||||
"The function drag and drop uses to determine if to accept or reject a drop.
|
||||
The function takes three arguments, WINDOW ACTION and TYPES.
|
||||
|
|
@ -51,28 +51,6 @@ The default value for this variable is `x-dnd-default-test-function'."
|
|||
:type 'symbol
|
||||
:group 'x)
|
||||
|
||||
(defcustom x-dnd-protocol-alist
|
||||
'(
|
||||
("^file:///" . x-dnd-open-local-file) ; XDND format.
|
||||
("^file://" . x-dnd-open-file) ; URL with host
|
||||
("^file:" . x-dnd-open-local-file) ; Old KDE, Motif, Sun
|
||||
)
|
||||
|
||||
"The functions to call for different protocols when a drop is made.
|
||||
This variable is used by `x-dnd-handle-uri-list', `x-dnd-handle-file-name'
|
||||
and `x-dnd-handle-moz-url'. The list contains of (REGEXP . FUNCTION) pairs.
|
||||
The functions shall take two arguments, URL, which is the URL dropped and
|
||||
ACTION which is the action to be performed for the drop (move, copy, link,
|
||||
private or ask).
|
||||
If no match is found here, and the value of `browse-url-browser-function'
|
||||
is a pair of (REGEXP . FUNCTION), those regexps are tried for a match.
|
||||
Insertion of text is not handeled by these functions, see `x-dnd-types-alist'
|
||||
for that.
|
||||
The function shall return the action done (move, copy, link or private)
|
||||
if some action was made, or nil if the URL is ignored."
|
||||
:version "22.1"
|
||||
:type 'alist
|
||||
:group 'x)
|
||||
|
||||
|
||||
(defcustom x-dnd-types-alist
|
||||
|
|
@ -85,10 +63,10 @@ if some action was made, or nil if the URL is ignored."
|
|||
("text/plain;charset=UTF-8" . x-dnd-insert-utf8-text)
|
||||
("text/plain;charset=utf-8" . x-dnd-insert-utf8-text)
|
||||
("text/unicode" . x-dnd-insert-utf16-text)
|
||||
("text/plain" . x-dnd-insert-text)
|
||||
("text/plain" . dnd-insert-text)
|
||||
("COMPOUND_TEXT" . x-dnd-insert-ctext)
|
||||
("STRING" . x-dnd-insert-text)
|
||||
("TEXT" . x-dnd-insert-text)
|
||||
("STRING" . dnd-insert-text)
|
||||
("TEXT" . dnd-insert-text)
|
||||
)
|
||||
"Which function to call to handle a drop of that type.
|
||||
If the type for the drop is not present, or the function is nil,
|
||||
|
|
@ -102,12 +80,6 @@ is successful, nil if not."
|
|||
:type 'alist
|
||||
:group 'x)
|
||||
|
||||
(defcustom x-dnd-open-file-other-window nil
|
||||
"If non-nil, always use find-file-other-window to open dropped files."
|
||||
:version "22.1"
|
||||
:type 'boolean
|
||||
:group 'x)
|
||||
|
||||
(defcustom x-dnd-known-types
|
||||
'("text/uri-list"
|
||||
"text/x-moz-url"
|
||||
|
|
@ -236,109 +208,6 @@ EXTRA-DATA is data needed for a specific protocol."
|
|||
(setcdr (x-dnd-get-state-cons-for-frame window) current-state)))
|
||||
|
||||
|
||||
(defun x-dnd-handle-one-url (window action arg)
|
||||
"Handle one dropped url by calling the appropriate handler.
|
||||
The handler is first localted by looking at `x-dnd-protocol-alist'.
|
||||
If no match is found here, and the value of `browse-url-browser-function'
|
||||
is a pair of (REGEXP . FUNCTION), those regexps are tried for a match.
|
||||
If no match is found, just call `x-dnd-insert-text'.
|
||||
WINDOW is where the drop happend, ACTION is the action for the drop,
|
||||
ARG is the URL that has been dropped.
|
||||
Returns ACTION."
|
||||
(require 'browse-url)
|
||||
(let* ((uri (replace-regexp-in-string
|
||||
"%[A-Z0-9][A-Z0-9]"
|
||||
(lambda (arg)
|
||||
(format "%c" (string-to-number (substring arg 1) 16)))
|
||||
arg))
|
||||
ret)
|
||||
(or
|
||||
(catch 'done
|
||||
(dolist (bf x-dnd-protocol-alist)
|
||||
(when (string-match (car bf) uri)
|
||||
(setq ret (funcall (cdr bf) uri action))
|
||||
(throw 'done t)))
|
||||
nil)
|
||||
(when (not (functionp browse-url-browser-function))
|
||||
(catch 'done
|
||||
(dolist (bf browse-url-browser-function)
|
||||
(when (string-match (car bf) uri)
|
||||
(setq ret 'private)
|
||||
(funcall (cdr bf) uri action)
|
||||
(throw 'done t)))
|
||||
nil))
|
||||
(progn
|
||||
(x-dnd-insert-text window action uri)
|
||||
(setq ret 'private)))
|
||||
ret))
|
||||
|
||||
|
||||
(defun x-dnd-get-local-file-uri (uri)
|
||||
"Return an uri converted to file:/// syntax if uri is a local file.
|
||||
Return nil if URI is not a local file."
|
||||
|
||||
;; The hostname may be our hostname, in that case, convert to a local
|
||||
;; file. Otherwise return nil. TODO: How about an IP-address as hostname?
|
||||
(let ((hostname (when (string-match "^file://\\([^/]*\\)" uri)
|
||||
(downcase (match-string 1 uri))))
|
||||
(system-name-no-dot
|
||||
(downcase (if (string-match "^[^\\.]+" system-name)
|
||||
(match-string 0 system-name)
|
||||
system-name))))
|
||||
(when (and hostname
|
||||
(or (string-equal "localhost" hostname)
|
||||
(string-equal (downcase system-name) hostname)
|
||||
(string-equal system-name-no-dot hostname)))
|
||||
(concat "file://" (substring uri (+ 7 (length hostname)))))))
|
||||
|
||||
(defun x-dnd-get-local-file-name (uri &optional must-exist)
|
||||
"Return file name converted from file:/// or file: syntax.
|
||||
URI is the uri for the file. If MUST-EXIST is given and non-nil,
|
||||
only return non-nil if the file exists.
|
||||
Return nil if URI is not a local file."
|
||||
(let ((f (cond ((string-match "^file:///" uri) ; XDND format.
|
||||
(substring uri (1- (match-end 0))))
|
||||
((string-match "^file:" uri) ; Old KDE, Motif, Sun
|
||||
(substring uri (match-end 0))))))
|
||||
(when (and f must-exist)
|
||||
(let* ((decoded-f (decode-coding-string
|
||||
f
|
||||
(or file-name-coding-system
|
||||
default-file-name-coding-system)))
|
||||
(try-f (if (file-readable-p decoded-f) decoded-f f)))
|
||||
(when (file-readable-p try-f) try-f)))))
|
||||
|
||||
|
||||
(defun x-dnd-open-local-file (uri action)
|
||||
"Open a local file.
|
||||
The file is opened in the current window, or a new window if
|
||||
`x-dnd-open-file-other-window' is set. URI is the url for the file,
|
||||
and must have the format file:file-name or file:///file-name.
|
||||
The last / in file:/// is part of the file name. ACTION is ignored."
|
||||
|
||||
(let* ((f (x-dnd-get-local-file-name uri t)))
|
||||
(if (and f (file-readable-p f))
|
||||
(progn
|
||||
(if x-dnd-open-file-other-window
|
||||
(find-file-other-window f)
|
||||
(find-file f))
|
||||
'private)
|
||||
(error "Can not read %s" uri))))
|
||||
|
||||
(defun x-dnd-open-file (uri action)
|
||||
"Open a local or remote file.
|
||||
The file is opened in the current window, or a new window if
|
||||
`x-dnd-open-file-other-window' is set. URI is the url for the file,
|
||||
and must have the format file://hostname/file-name. ACTION is ignored.
|
||||
The last / in file://hostname/ is part of the file name."
|
||||
|
||||
;; The hostname may be our hostname, in that case, convert to a local
|
||||
;; file. Otherwise return nil.
|
||||
(let ((local-file (x-dnd-get-local-file-uri uri)))
|
||||
(if local-file (x-dnd-open-local-file local-file action)
|
||||
(error "Remote files not supported"))))
|
||||
|
||||
|
||||
(defun x-dnd-handle-moz-url (window action data)
|
||||
"Handle one item of type text/x-moz-url.
|
||||
WINDOW is the window where the drop happened. ACTION is ignored.
|
||||
|
|
@ -360,49 +229,36 @@ DATA is encoded in utf-16. Decode the URL and call `x-dnd-handle-uri-list'."
|
|||
(defun x-dnd-insert-utf8-text (window action text)
|
||||
"Decode the UTF-8 text and insert it at point.
|
||||
TEXT is the text as a string, WINDOW is the window where the drop happened."
|
||||
(x-dnd-insert-text window action (decode-coding-string text 'utf-8)))
|
||||
(dnd-insert-text window action (decode-coding-string text 'utf-8)))
|
||||
|
||||
(defun x-dnd-insert-utf16-text (window action text)
|
||||
"Decode the UTF-16 text and insert it at point.
|
||||
TEXT is the text as a string, WINDOW is the window where the drop happened."
|
||||
;; See comment in x-dnd-handle-moz-url about coding.
|
||||
(let ((coding (if (eq (byteorder) ?B) 'utf-16be 'utf-16le)))
|
||||
(x-dnd-insert-text window action (decode-coding-string text coding))))
|
||||
(dnd-insert-text window action (decode-coding-string text coding))))
|
||||
|
||||
(defun x-dnd-insert-ctext (window action text)
|
||||
"Decode the compound text and insert it at point.
|
||||
TEXT is the text as a string, WINDOW is the window where the drop happened."
|
||||
(x-dnd-insert-text window action
|
||||
(decode-coding-string text
|
||||
'compound-text-with-extensions)))
|
||||
|
||||
(defun x-dnd-insert-text (window action text)
|
||||
"Insert text at point or push to the kill ring if buffer is read only.
|
||||
TEXT is the text as a string, WINDOW is the window where the drop happened."
|
||||
(if (or buffer-read-only
|
||||
(not (windowp window)))
|
||||
(progn
|
||||
(kill-new text)
|
||||
(message
|
||||
(substitute-command-keys
|
||||
"The dropped text can be accessed with \\[yank]")))
|
||||
(insert text))
|
||||
action)
|
||||
(dnd-insert-text window action
|
||||
(decode-coding-string text
|
||||
'compound-text-with-extensions)))
|
||||
|
||||
(defun x-dnd-handle-uri-list (window action string)
|
||||
"Split an uri-list into separate URIs and call `x-dnd-handle-one-url'.
|
||||
"Split an uri-list into separate URIs and call `dnd-handle-one-url'.
|
||||
WINDOW is the window where the drop happened.
|
||||
STRING is the uri-list as a string. The URIs are separated by \r\n."
|
||||
(let ((uri-list (split-string string "[\0\r\n]" t))
|
||||
retval)
|
||||
(dolist (bf uri-list)
|
||||
;; If one URL is handeled, treat as if the whole drop succeeded.
|
||||
(let ((did-action (x-dnd-handle-one-url window action bf)))
|
||||
(let ((did-action (dnd-handle-one-url window action bf)))
|
||||
(when did-action (setq retval did-action))))
|
||||
retval))
|
||||
|
||||
(defun x-dnd-handle-file-name (window action string)
|
||||
"Prepend file:// to file names and call `x-dnd-handle-one-url'.
|
||||
"Prepend file:// to file names and call `dnd-handle-one-url'.
|
||||
WINDOW is the window where the drop happened.
|
||||
STRING is the file names as a string, separated by nulls."
|
||||
(let ((uri-list (split-string string "[\0\r\n]" t))
|
||||
|
|
@ -410,7 +266,7 @@ STRING is the file names as a string, separated by nulls."
|
|||
(dolist (bf uri-list)
|
||||
;; If one URL is handeled, treat as if the whole drop succeeded.
|
||||
(let* ((file-uri (concat "file://" bf))
|
||||
(did-action (x-dnd-handle-one-url window action file-uri)))
|
||||
(did-action (dnd-handle-one-url window action file-uri)))
|
||||
(when did-action (setq retval did-action))))
|
||||
retval))
|
||||
|
||||
|
|
@ -456,10 +312,10 @@ nil if not."
|
|||
(if (and (windowp w) (window-live-p w))
|
||||
;; If dropping in a window, open files in that window rather
|
||||
;; than in a new widow.
|
||||
(let ((x-dnd-open-file-other-window nil))
|
||||
(let ((dnd-open-file-other-window nil))
|
||||
(goto-char (posn-point (event-start event)))
|
||||
(funcall handler window action data))
|
||||
(let ((x-dnd-open-file-other-window t)) ;; Dropping on non-window.
|
||||
(let ((dnd-open-file-other-window t)) ;; Dropping on non-window.
|
||||
(select-frame frame)
|
||||
(funcall handler window action data))))))
|
||||
|
||||
|
|
@ -881,7 +737,6 @@ FORMAT is 32 (not used). MESSAGE is the data part of an XClientMessageEvent."
|
|||
|
||||
;;;
|
||||
|
||||
|
||||
(provide 'x-dnd)
|
||||
|
||||
;;; arch-tag: b621fb7e-50da-4323-850b-5fc71ae64621
|
||||
|
|
|
|||
|
|
@ -156,10 +156,12 @@
|
|||
With prefix arg, turn XTerm mouse mode on iff arg is positive.
|
||||
|
||||
Turn it on to use Emacs mouse commands, and off to use xterm mouse commands.
|
||||
This works in terminal emulators compatible with xterm. Only single clicks
|
||||
are supported. When turned on, the normal xterm mouse functionality is still
|
||||
available by holding down the SHIFT key while pressing the mouse button."
|
||||
nil " Mouse" nil :global t :group 'mouse
|
||||
This works in terminal emulators compatible with xterm. It only
|
||||
works for simple uses of the mouse. Basically, only non-modified
|
||||
single clicks are supported. When turned on, the normal xterm
|
||||
mouse functionality for such clicks is still available by holding
|
||||
down the SHIFT key while pressing the mouse button."
|
||||
:global t :group 'mouse
|
||||
(if xterm-mouse-mode
|
||||
;; Turn it on
|
||||
(unless window-system
|
||||
|
|
|
|||
|
|
@ -1,3 +1,11 @@
|
|||
2005-04-17 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* buffers.texi (Indirect Buffers): Clarify.
|
||||
|
||||
* positions.texi (Positions): Clarify converting marker to integer.
|
||||
|
||||
* strings.texi (String Basics): Mention string-match; clarify.
|
||||
|
||||
2005-04-08 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* modes.texi (Search-based Fontification): Fix cross references.
|
||||
|
|
|
|||
|
|
@ -1067,11 +1067,11 @@ in the other. This includes the text properties as well as the characters
|
|||
themselves.
|
||||
|
||||
In all other respects, the indirect buffer and its base buffer are
|
||||
completely separate. They have different names, different values of
|
||||
point, different narrowing, different markers and overlays (though
|
||||
completely separate. They have different names, independent values of
|
||||
point, independent narrowing, independent markers and overlays (though
|
||||
inserting or deleting text in either buffer relocates the markers and
|
||||
overlays for both), different major modes, and different buffer-local
|
||||
variables.
|
||||
overlays for both), independent major modes, and independent
|
||||
buffer-local variable bindings.
|
||||
|
||||
An indirect buffer cannot visit a file, but its base buffer can. If
|
||||
you try to save the indirect buffer, that actually saves the base
|
||||
|
|
|
|||
|
|
@ -15,14 +15,17 @@ speak of the character before or after a given position. However, we
|
|||
often speak of the character ``at'' a position, meaning the character
|
||||
after that position.
|
||||
|
||||
Positions are usually represented as integers starting from 1, but can
|
||||
also be represented as @dfn{markers}---special objects that relocate
|
||||
automatically when text is inserted or deleted so they stay with the
|
||||
surrounding characters. Functions that expect an argument to be a
|
||||
position (an integer), but accept a marker as a substitute, normally
|
||||
ignore the marker buffer. Of course, markers used this way usually
|
||||
point to a position in the buffer that the function operates on, but
|
||||
that is entirely the programmer's responsibility. @xref{Markers}.
|
||||
Positions are usually represented as integers starting from 1, but
|
||||
can also be represented as @dfn{markers}---special objects that
|
||||
relocate automatically when text is inserted or deleted so they stay
|
||||
with the surrounding characters. Functions that expect an argument to
|
||||
be a position (an integer), but accept a marker as a substitute,
|
||||
normally ignore which buffer the marker points into; they convert the
|
||||
marker to an integer, and use that integer, exactly as if you had
|
||||
passed the integer as the argument, even if the marker points to the
|
||||
``wrong'' buffer. A marker that points nowhere cannot convert to an
|
||||
integer; using it instead of an integer causes an error.
|
||||
@xref{Markers}.
|
||||
|
||||
See also the ``field'' feature (@pxref{Fields}), which provides
|
||||
functions that are used by many cursor-motion commands.
|
||||
|
|
|
|||
|
|
@ -74,10 +74,11 @@ a key sequence, you must use a vector instead of a string.
|
|||
and other modifiers for keyboard input characters.
|
||||
|
||||
Strings are useful for holding regular expressions. You can also
|
||||
match regular expressions against strings (@pxref{Regexp Search}). The
|
||||
functions @code{match-string} (@pxref{Simple Match Data}) and
|
||||
@code{replace-match} (@pxref{Replacing Match}) are useful for
|
||||
decomposing and modifying strings based on regular expression matching.
|
||||
match regular expressions against strings with @code{string-match}
|
||||
(@pxref{Regexp Search}). The functions @code{match-string}
|
||||
(@pxref{Simple Match Data}) and @code{replace-match} (@pxref{Replacing
|
||||
Match}) are useful for decomposing and modifying strings after
|
||||
matching regular expressions against them.
|
||||
|
||||
Like a buffer, a string can contain text properties for the characters
|
||||
in it, as well as the characters themselves. @xref{Text Properties}.
|
||||
|
|
|
|||
|
|
@ -1,3 +1,8 @@
|
|||
2005-04-14 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* makefile.MPW (NonCarbonLibs): Add LocalesLib. Delete
|
||||
TextEncodingConverter.
|
||||
|
||||
2005-04-06 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* Emacs.app/Contents/Resources/English.lproj/InfoPlist.strings
|
||||
|
|
|
|||
|
|
@ -146,7 +146,7 @@ NonCarbonLibs =
|
|||
"{SharedLibraries}StdCLib" ¶
|
||||
"{SharedLibraries}MathLib" ¶
|
||||
"{SharedLibraries}AppleScriptLib" ¶
|
||||
"{SharedLibraries}TextEncodingConverter" ¶
|
||||
"{SharedLibraries}LocalesLib" ¶
|
||||
"{SharedLibraries}AppearanceLib" ¶
|
||||
"{SharedLibraries}QuickTimeLib" ¶
|
||||
"{PPCLibraries}StdCRuntime.o" ¶
|
||||
|
|
|
|||
30
make-dist
30
make-dist
|
|
@ -6,7 +6,8 @@
|
|||
#### be distributed. This means that if you add a file with an odd name,
|
||||
#### you should make sure that this script will include it.
|
||||
|
||||
# Copyright (C) 1995, 1997, 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
|
||||
# Copyright (C) 1995, 1997, 1998, 2000, 2001, 2002, 2005
|
||||
# Free Software Foundation, Inc.
|
||||
#
|
||||
# This file is part of GNU Emacs.
|
||||
#
|
||||
|
|
@ -183,9 +184,9 @@ fi
|
|||
if [ $check = yes ];
|
||||
then
|
||||
### Check for .elc files with no corresponding .el file.
|
||||
ls -1 lisp/[a-z]*.el lisp/[a-z]*/[a-z]*.el \
|
||||
ls -1 lisp/[a-zA-Z]*.el lisp/[a-z]*/[a-zA-Z0-9]*.el \
|
||||
leim/[a-z]*/[a-z]*.el | sed 's/\.el$/.elc/' > /tmp/el
|
||||
ls -1 lisp/[a-z]*.elc lisp/[a-z]*/[a-z]*.elc \
|
||||
ls -1 lisp/[a-zA-Z]*.elc lisp/[a-z]*/[a-zA-Z0-9]*.elc \
|
||||
leim/[a-z]*/[a-z]*.elc > /tmp/elc
|
||||
bogosities="`comm -13 /tmp/el /tmp/elc`"
|
||||
if [ "${bogosities}" != "" ]; then
|
||||
|
|
@ -195,21 +196,17 @@ then
|
|||
rm -f /tmp/el /tmp/elc
|
||||
|
||||
### Check for .el files with no corresponding .elc file.
|
||||
(cd lisp; ls -1 [a-z]*.el [a-z]*/[a-z]*.el ; \
|
||||
cd ../leim; ls -1 [a-z]*/[a-z]*.el) > /tmp/el
|
||||
(cd lisp; ls -1 [a-z]*.elc [a-z]*/[a-z]*.elc; \
|
||||
cd ../leim; ls -1 [a-z]*/[a-z]*.elc) | sed 's/\.elc$/.el/' > /tmp/elc
|
||||
ls -1 lisp/[a-zA-Z]*.el lisp/[a-z]*/[a-zA-Z0-9]*.el \
|
||||
leim/[a-z]*/[a-z]*.el > /tmp/el
|
||||
ls -1 lisp/[a-zA-Z]*.elc lisp/[a-z]*/[a-zA-Z0-9]*.elc \
|
||||
leim/[a-z]*/[a-z]*.elc | sed 's/\.elc$/.el/' > /tmp/elc
|
||||
losers="`comm -23 /tmp/el /tmp/elc`"
|
||||
bogosities=
|
||||
for file in $losers; do
|
||||
file1=`echo $file | sed -e "s|.*/||"`
|
||||
if ! sed -n -e "/^DONTCOMPILE/,/[^\\]\$/p" lisp/Makefile.in |
|
||||
grep -q "[ ]$file1\($\| \)"; then
|
||||
if ! grep -q "no-byte-compile: t" $file; then
|
||||
case $file in
|
||||
site-init.el | site-load.el | site-start.el | default.el)
|
||||
;;
|
||||
term/*)
|
||||
;;
|
||||
*)
|
||||
bogosities="$file $bogosities"
|
||||
;;
|
||||
|
|
@ -347,11 +344,12 @@ echo "Making links to \`lisp' and its subdirectories"
|
|||
done
|
||||
## simula.el doesn't keep abbreviations in simula.defns any more.
|
||||
## ln [a-zA-Z]*.defns ../${tempdir}/lisp
|
||||
ln ChangeLog Makefile.in makefile.nt ChangeLog.? ../${tempdir}/lisp
|
||||
ln makefile.w32-in ../${tempdir}/lisp
|
||||
ln ChangeLog ChangeLog.*[0-9] ../${tempdir}/lisp
|
||||
ln Makefile.in makefile.w32-in ../${tempdir}/lisp
|
||||
test -f README && ln README ../${tempdir}/lisp
|
||||
(cd ../${tempdir}/lisp
|
||||
rm -f TAGS =*
|
||||
rm -f ldefs-boot.el
|
||||
rm -f site-init site-init.el site-init.elc
|
||||
rm -f site-load site-load.el site-load.elc
|
||||
rm -f site-start site-start.el site-start.elc
|
||||
|
|
@ -387,7 +385,7 @@ echo "Making links to \`lisp' and its subdirectories"
|
|||
|
||||
if [ -f $file/ChangeLog ]; then
|
||||
ln $file/ChangeLog ../${tempdir}/lisp/$file
|
||||
for f in $file/ChangeLog.[0-9]; do
|
||||
for f in $file/ChangeLog.*[0-9]; do
|
||||
if [ -f $f ]; then
|
||||
ln $f ../${tempdir}/lisp/$file
|
||||
fi
|
||||
|
|
@ -407,6 +405,8 @@ echo "Making links to \`leim' and its subdirectories"
|
|||
ln ja-dic/*.el ja-dic/*.elc ../${tempdir}/leim/ja-dic
|
||||
ln Makefile.in ../${tempdir}/leim/Makefile.in
|
||||
ln leim-ext.el ../${tempdir}/leim/leim-ext.el
|
||||
## Lisp files that start with a capital are generated from TIT
|
||||
## dictionaries so we don't distribute them.
|
||||
ln quail/[a-z]*.el quail/[a-z]*.elc ../${tempdir}/leim/quail
|
||||
rm -f ../${tempdir}/leim/quail/quick-b5.*
|
||||
rm -f ../${tempdir}/leim/quail/quick-cns.*
|
||||
|
|
|
|||
|
|
@ -1,3 +1,42 @@
|
|||
2005-04-17 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* frames.texi (XTerm Mouse): Xterm Mouse mode is no longer enabled
|
||||
by default in terminals compatible with xterm. Mention that
|
||||
xterm-mouse-mode is a minor mode and put in pxref to Minor Modes
|
||||
node.
|
||||
|
||||
2005-04-15 Carsten Dominik <dominik@science.uva.nl>
|
||||
|
||||
* org.texi: Update to version 3.06.
|
||||
|
||||
2005-04-13 Lute Kamstra <lute@gnu.org>
|
||||
|
||||
* cc-mode.texi: Prevent creating an unnecessary empty cc-mode.ss file.
|
||||
|
||||
2005-04-12 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* frames.texi (XTerm Mouse): Xterm Mouse mode is now enabled by
|
||||
default.
|
||||
|
||||
2005-04-12 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
|
||||
* xresources.texi (Table of Resources): Add cursorBlink.
|
||||
|
||||
2005-04-11 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* rmail.texi (Rmail Summary Edit): Explain numeric arguments to
|
||||
`d', `C-d' and `u'.
|
||||
|
||||
2005-04-11 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* cmdargs.texi (Initial Options): -Q is now --quick, and does less.
|
||||
(Misc X): Add -D, --basic-display.
|
||||
|
||||
* maintaining.texi (Change Log): Correct the description of
|
||||
the example.
|
||||
|
||||
* major.texi (Choosing Modes): Document magic-mode-alist.
|
||||
|
||||
2005-04-10 Thien-Thi Nguyen <ttn@gnu.org>
|
||||
|
||||
* cl.texi (Porting Common Lisp): Fix typo.
|
||||
|
|
@ -53,6 +92,10 @@
|
|||
|
||||
* calendar.texi (Diary): Mention shell utility `calendar'.
|
||||
|
||||
2005-04-01 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* cmdargs.texi (Misc X): Explain horizontal scroll bars don't exist.
|
||||
|
||||
2005-04-01 Jay Belanger <belanger@truman.edu>
|
||||
|
||||
* calc.texi (Troubleshooting Commands): Remove comment about
|
||||
|
|
@ -878,7 +921,7 @@
|
|||
|
||||
2005-01-15 Sergey Poznyakoff <gray@Mirddin.farlep.net>
|
||||
|
||||
* man/rmail.texi (Movemail): Explain differences
|
||||
* rmail.texi (Movemail): Explain differences
|
||||
between standard and mailutils versions of movemail.
|
||||
Describe command line and configuration options introduced
|
||||
with the latter.
|
||||
|
|
|
|||
|
|
@ -55,7 +55,9 @@
|
|||
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
||||
|
||||
@comment Define an index for syntactic symbols.
|
||||
@ifnottex
|
||||
@defindex ss
|
||||
@end ifnottex
|
||||
|
||||
@comment Combine key, syntactic symbol and concept indices into one.
|
||||
@syncodeindex ss cp
|
||||
|
|
|
|||
|
|
@ -268,12 +268,10 @@ option and @samp{-Q} are the only options that block it.
|
|||
|
||||
@item -Q
|
||||
@opindex -Q
|
||||
@itemx --bare-bones
|
||||
@opindex --bare-bones
|
||||
Start emacs with minimum customizations and window decorations.
|
||||
This is like using @samp{-q} and @samp{--no-site-file}, but in
|
||||
addition it also disables the menu-bar, the tool-bar, the scroll-bars,
|
||||
tool tips, the blinking cursor, and the fancy startup screen.
|
||||
@itemx --quick
|
||||
@opindex --quick
|
||||
Start emacs with minimum customizations. This is like using @samp{-q}
|
||||
and @samp{--no-site-file}, but also disables the startup screen.
|
||||
|
||||
@item --no-splash
|
||||
@opindex --no-splash
|
||||
|
|
@ -1222,6 +1220,14 @@ Specify @var{pixels} as additional space to put between lines, in pixels.
|
|||
@opindex --no-blinking-cursor
|
||||
@cindex blinking cursor disable, command-line argument
|
||||
Disable the blinking cursor on graphical terminals.
|
||||
|
||||
@item -D
|
||||
@opindex -D
|
||||
@itemx --basic-display
|
||||
@opindex --basic-display
|
||||
Disable the menu-bar, the tool-bar, the scroll-bars, and tool tips,
|
||||
and turn off the blinking cursor. This can be useful for making a
|
||||
test case that simplifies debugging of display problems.
|
||||
@end table
|
||||
|
||||
The @samp{--xrm} option (@pxref{Resources}) specifies additional
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
@c This is part of the Emacs manual.
|
||||
@c Copyright (C) 1985,86,87,93,94,95,97,2000,2001,2002,2004
|
||||
@c Copyright (C) 1985,86,87,93,94,95,97,2000,2001,2002,2004,2005
|
||||
@c Free Software Foundation, Inc.
|
||||
@c See file emacs.texi for copying conditions.
|
||||
@node Customization, Quitting, Amusements, Top
|
||||
|
|
@ -2313,8 +2313,44 @@ Enable the use of the command @code{narrow-to-region} without confirmation.
|
|||
@example
|
||||
(put 'narrow-to-region 'disabled nil)
|
||||
@end example
|
||||
|
||||
@item
|
||||
Adjusting the configuration to various contexts.
|
||||
|
||||
In most of the cases, people want their Emacs to behave the same on
|
||||
all their machines, so their configuration should be the same, no
|
||||
matter whether it's GNU/Linux or not, under X11 or on a tty, with one
|
||||
version of Emacs or another, ...
|
||||
|
||||
What can happen, tho, is that depending on the circumstance some
|
||||
features may or may not be available. In that case just prepend each
|
||||
such customization with a little test that ensures that the feature
|
||||
can be used. The best tests are usually checking that the feature is
|
||||
available, rather than checking what kind of environment is
|
||||
being used.
|
||||
|
||||
@example
|
||||
(if (fboundp 'blinking-cursor-mode)
|
||||
(blinking-cursor-mode 0))
|
||||
@end example
|
||||
|
||||
@example
|
||||
(if (boundp 'coding-category-utf-8)
|
||||
(set-coding-priority '(coding-category-utf-8)))
|
||||
@end example
|
||||
|
||||
@example
|
||||
(require 'cl) ; To define `ignore-errors'.
|
||||
(ignore-errors (set-face-background 'region "grey75"))
|
||||
@end example
|
||||
|
||||
Note also that a @code{setq} on a variable which does not exist is
|
||||
generally harmless, so those usually do not need to be made
|
||||
conditional on any kind of test.
|
||||
|
||||
@end itemize
|
||||
|
||||
|
||||
@node Terminal Init
|
||||
@subsection Terminal-specific Initialization
|
||||
|
||||
|
|
|
|||
|
|
@ -1055,10 +1055,14 @@ when the frame is selected.
|
|||
|
||||
Some terminal emulators under X support mouse clicks in the terminal
|
||||
window. In a terminal emulator which is compatible with @code{xterm},
|
||||
you can use @kbd{M-x xterm-mouse-mode} to enable simple use of the
|
||||
mouse---only single clicks are supported. The normal @code{xterm} mouse
|
||||
functionality is still available by holding down the @kbd{SHIFT} key
|
||||
when you press the mouse button.
|
||||
you can use @kbd{M-x xterm-mouse-mode} to give Emacs control over
|
||||
simple use of the mouse---basically, only non-modified single clicks
|
||||
are supported. The normal @code{xterm} mouse functionality for such
|
||||
clicks is still available by holding down the @kbd{SHIFT} key when you
|
||||
press the mouse button.
|
||||
|
||||
Xterm Mouse mode is a global minor mode (@pxref{Minor Modes}).
|
||||
Repeating the command turns the mode off again.
|
||||
|
||||
@ignore
|
||||
arch-tag: 7dcf3a31-a43b-45d4-a900-445b10d77e49
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ date, your name, and your email address (taken from the variable
|
|||
line in the change log starts with a space or a tab. The bulk of the
|
||||
entry consists of @dfn{items}, each of which starts with a line starting
|
||||
with whitespace and a star. Here are two entries, both dated in May
|
||||
1993, each with two items:
|
||||
1993, with two items and one item respectively.
|
||||
|
||||
@iftex
|
||||
@medbreak
|
||||
|
|
@ -79,10 +79,10 @@ with whitespace and a star. Here are two entries, both dated in May
|
|||
@end smallexample
|
||||
|
||||
One entry can describe several changes; each change should have its
|
||||
own item. Normally there should be a blank line between items. When
|
||||
items are related (parts of the same change, in different places), group
|
||||
them by leaving no blank line between them. The second entry above
|
||||
contains two items grouped in this way.
|
||||
own item, or its own line in an item. Normally there should be a
|
||||
blank line between items. When items are related (parts of the same
|
||||
change, in different places), group them by leaving no blank line
|
||||
between them.
|
||||
|
||||
@kbd{C-x 4 a} visits the change log file and creates a new entry
|
||||
unless the most recent entry is for today's date and your name. It
|
||||
|
|
@ -92,8 +92,8 @@ changed.
|
|||
|
||||
@vindex add-log-keep-changes-together
|
||||
When the variable @code{add-log-keep-changes-together} is
|
||||
non-@code{nil}, @kbd{C-x 4 a} adds to any existing entry for the file
|
||||
rather than starting a new entry.
|
||||
non-@code{nil}, @kbd{C-x 4 a} adds to any existing item for the file
|
||||
rather than starting a new item.
|
||||
|
||||
@vindex change-log-version-info-enabled
|
||||
@vindex change-log-version-number-regexp-list
|
||||
|
|
|
|||
|
|
@ -98,6 +98,21 @@ the element has the form @code{(@var{regexp} @var{mode-function}
|
|||
@var{mode-function}, Emacs discards the suffix that matched
|
||||
@var{regexp} and searches the list again for another match.
|
||||
|
||||
@vindex magic-mode-alist
|
||||
Sometimes the major mode is determined from the way the file's text
|
||||
begins. The variable @code{magic-mode-alist} controls this. Its value
|
||||
is a list of elements of this form:
|
||||
|
||||
@example
|
||||
(@var{regexp} . @var{mode-function})
|
||||
@end example
|
||||
|
||||
@noindent
|
||||
This looks like an element of @code{auto-mode-alist}, but it doesn't work
|
||||
the same: this @var{regexp} is matched against the text at the start
|
||||
of the buffer, not against the file name. @code{magic-mode-alist}
|
||||
takes priority over @code{auto-mode-alist}.
|
||||
|
||||
You can specify the major mode to use for editing a certain file by
|
||||
special text in the first nonblank line of the file. The
|
||||
mode name should appear in this line both preceded and followed by
|
||||
|
|
|
|||
259
man/org.texi
259
man/org.texi
|
|
@ -3,7 +3,7 @@
|
|||
@setfilename ../info/org
|
||||
@settitle Org Mode Manual
|
||||
|
||||
@set VERSION 3.05
|
||||
@set VERSION 3.06
|
||||
@set DATE April 2005
|
||||
|
||||
@dircategory Emacs
|
||||
|
|
@ -92,7 +92,7 @@ Software Foundation raise funds for GNU development.''
|
|||
Introduction
|
||||
|
||||
* Summary:: Brief summary of what Org-mode does
|
||||
* Installation:: How to install Org-mode
|
||||
* Installation and Activation:: How to install Org-mode
|
||||
|
||||
Document Structure
|
||||
|
||||
|
|
@ -106,8 +106,8 @@ Document Structure
|
|||
TODO items
|
||||
|
||||
* TODO basics:: Marking and displaying TODO entries
|
||||
* Priorities:: Some things are more important than others
|
||||
* TODO extensions:: Workflow and assignments
|
||||
* Priorities:: Some things are more important than others
|
||||
|
||||
Extended use of TODO keywords
|
||||
|
||||
|
|
@ -133,8 +133,8 @@ Timestamps
|
|||
|
||||
Timeline and Agenda
|
||||
|
||||
* Timeline (single file):: Time-sorted view for single file
|
||||
* Agenda (multiple files):: Your weekly planner
|
||||
* Timeline:: Time-sorted view for single file
|
||||
* Agenda:: Your weekly planner
|
||||
* Agenda commands:: Remote editing of org trees
|
||||
* Calendar/Diary integration:: Integrating Anniversaries and more
|
||||
|
||||
|
|
@ -168,10 +168,10 @@ Miscellaneous
|
|||
|
||||
@menu
|
||||
* Summary:: Brief summary of what Org-mode does
|
||||
* Installation:: How to install Org-mode
|
||||
* Installation and Activation:: How to install Org-mode
|
||||
@end menu
|
||||
|
||||
@node Summary, Installation, Introduction, Introduction
|
||||
@node Summary, Installation and Activation, Introduction, Introduction
|
||||
@section Summary
|
||||
@cindex summary
|
||||
|
||||
|
|
@ -214,8 +214,8 @@ and example files. This page is located at
|
|||
|
||||
@page
|
||||
|
||||
@node Installation, , Summary, Introduction
|
||||
@section Installation
|
||||
@node Installation and Activation, , Summary, Introduction
|
||||
@section Installation and Activation
|
||||
@cindex installation
|
||||
@cindex autoload
|
||||
@cindex global keybindings
|
||||
|
|
@ -236,12 +236,15 @@ define @emph{global} keys for the commands @command{org-store-link}
|
|||
and @command{org-agenda} - please choose suitable keys yourself.
|
||||
|
||||
@lisp
|
||||
;; These lines only if org-mode is not part of the X/Emacs distribution.
|
||||
(autoload 'org-mode "org" "Org mode" t)
|
||||
(autoload 'org-diary "org" "Diary entries from Org mode")
|
||||
(autoload 'org-agenda "org" "Multi-file agenda from Org mode" t)
|
||||
(autoload 'org-store-link "org" "Store a link to the current location" t)
|
||||
(autoload 'orgtbl-mode "org" "Org tables as a minor mode" t)
|
||||
(autoload 'turn-on-orgtbl "org" "Org tables as a minor mode")
|
||||
|
||||
;; The following lines are always needed. Choose your own keys.
|
||||
(add-to-list 'auto-mode-alist '("\\.org$" . org-mode))
|
||||
(define-key global-map "\C-cl" 'org-store-link)
|
||||
(define-key global-map "\C-ca" 'org-agenda)
|
||||
|
|
@ -257,7 +260,8 @@ MY PROJECTS -*- mode: org; -*-
|
|||
@end example
|
||||
|
||||
@noindent which will select Org-mode for this buffer no matter what
|
||||
the file's name is.
|
||||
the file's name is. See also the variable
|
||||
@code{org-insert-mode-line-in-empty-file'}.
|
||||
|
||||
@node Document Structure, TODO items, Introduction, Top
|
||||
@chapter Document Structure
|
||||
|
|
@ -361,9 +365,9 @@ buffer:
|
|||
@example
|
||||
#+STARTUP: fold
|
||||
#+STARTUP: nofold
|
||||
#+STARTUP: content
|
||||
@end example
|
||||
|
||||
|
||||
@node Motion, Structure editing, Visibility cycling, Document Structure
|
||||
@section Motion
|
||||
@cindex motion, between headlines
|
||||
|
|
@ -411,6 +415,9 @@ visible.
|
|||
@kindex M-@key{RET}
|
||||
@item M-@key{RET}
|
||||
Insert new heading with same level as current
|
||||
@kindex M-S-@key{RET}
|
||||
@item M-S-@key{RET}
|
||||
Insert new TODO entry with same level as current heading.
|
||||
@kindex M-@key{left}
|
||||
@item M-@key{left}
|
||||
Promote current heading by one level
|
||||
|
|
@ -437,7 +444,7 @@ Kill subtree, i.e. remove it from buffer but save in kill ring.
|
|||
Copy subtree to kill ring.
|
||||
@kindex C-c C-h C-y
|
||||
@item C-c C-h C-y
|
||||
Yank subtree from kill ring. This does modify the level of subtree to
|
||||
Yank subtree from kill ring. This does modify the level of the subtree to
|
||||
make sure the tree fits in nicely at the yank position. The yank
|
||||
level can also be specified with a prefix arg, or by yanking after a
|
||||
headline marker like @samp{****}.
|
||||
|
|
@ -513,11 +520,11 @@ things you have to do.
|
|||
|
||||
@menu
|
||||
* TODO basics:: Marking and displaying TODO entries
|
||||
* Priorities:: Some things are more important than others
|
||||
* TODO extensions:: Workflow and assignments
|
||||
* Priorities:: Some things are more important than others
|
||||
@end menu
|
||||
|
||||
@node TODO basics, Priorities, TODO items, TODO items
|
||||
@node TODO basics, TODO extensions, TODO items, TODO items
|
||||
@section Basic TODO functionality
|
||||
|
||||
Any headline can become a TODO item by starting it with the word TODO,
|
||||
|
|
@ -538,49 +545,20 @@ Rotate the TODO state of the current item between
|
|||
,-> (unmarked) -> TODO -> DONE --.
|
||||
'--------------------------------'
|
||||
@end example
|
||||
The same rotation can also be done ``remotely'' from the timeline and
|
||||
agenda buffers with the @kbd{t} command key (@pxref{Agenda commands}).
|
||||
@kindex C-c C-v
|
||||
@cindex sparse tree, for TODO
|
||||
@item C-c C-v
|
||||
View TODO items in a @emph{sparse tree} (@pxref{Sparse trees}). Folds
|
||||
the entire buffer, but shows all TODO items and the headings hierarchy
|
||||
above them. With prefix arg, show also the DONE entries.
|
||||
@item C-u C-c a
|
||||
A @kbd{C-u} argument to the @code{org-agenda command} (@pxref{Agenda})
|
||||
collects all unfinished TODO items into a single place.
|
||||
@end table
|
||||
|
||||
@node Priorities, TODO extensions, TODO basics, TODO items
|
||||
@section Priorities
|
||||
@cindex priorities
|
||||
|
||||
If you use Org-mode extensively to organize your work, you may end up
|
||||
with a number of TODO entries so large that you'd like to prioritize
|
||||
them. You can do this by placing a @emph{priority cookie} into the
|
||||
headline, like this
|
||||
|
||||
@example
|
||||
*** TODO [#A] Write letter to Sam Fortune
|
||||
@end example
|
||||
|
||||
@noindent
|
||||
With its standard setup, Org-mode supports priorities @samp{A},
|
||||
@samp{B}, and @samp{C}. @samp{A} is the highest priority. An entry
|
||||
without a cookie is treated as priority @samp{B}. Priorities make a
|
||||
difference only in the multi-file agenda (@pxref{Agenda (multiple files)}).
|
||||
|
||||
@table @kbd
|
||||
@kindex @kbd{C-c ,}
|
||||
@item @kbd{C-c ,}
|
||||
Set the priority of the current item. The command prompts for a
|
||||
priority character @samp{A}, @samp{B} or @samp{C}. When you press
|
||||
@key{SPC} instead, the priority cookie is removed from the headline.
|
||||
@kindex S-@key{up}
|
||||
@kindex S-@key{down}
|
||||
@item S-@key{up}
|
||||
@itemx S-@key{down}
|
||||
Increase/decrease priority of current item. Note that these keys are
|
||||
also used to modify time stamps (@pxref{Creating timestamps}).
|
||||
@end table
|
||||
|
||||
|
||||
@node TODO extensions, , Priorities, TODO items
|
||||
@node TODO extensions, Priorities, TODO basics, TODO items
|
||||
@section Extended use of TODO keywords
|
||||
@cindex extended TODO keywords
|
||||
|
||||
|
|
@ -624,9 +602,11 @@ If you define many keywords, you can use in-buffer completion (see
|
|||
@cindex types as TODO keywords
|
||||
|
||||
The second possibility is to use TODO keywords to indicate different
|
||||
types of action items. For example, when you work with several people
|
||||
on a single project, you might want to assign action items to
|
||||
persons.
|
||||
types of action items. For example, you might want to indicate that
|
||||
items are for ``work'' or ``home''. Or, when you work with several
|
||||
people on a single project, you might want to assign action items
|
||||
directly to persons, by using their names as TODO keywords. This
|
||||
would be set up like this:
|
||||
|
||||
@lisp
|
||||
(setq org-todo-keywords '("Fred" "Sara" "Lucy" "Mike" "DONE")
|
||||
|
|
@ -634,12 +614,15 @@ persons.
|
|||
@end lisp
|
||||
|
||||
In this case, different keywords do not indicate a sequence, but
|
||||
rather different types. This changes the behavior of the command
|
||||
@kbd{C-c C-t} slightly. When used several times in succession, it
|
||||
will still cycle through all names. But when when you return to the
|
||||
item after some time and execute @kbd{C-c C-t} again, it will switch
|
||||
from each name directly to DONE. Use prefix arguments or completion
|
||||
to quickly select a specific name.
|
||||
rather different types. So it is normally not useful to change from
|
||||
one type to another. Therefore, in this case the the behavior of the
|
||||
command @kbd{C-c C-t} is changed slightly@footnote{This is also true
|
||||
for the @kbd{t} command in the timeline and agenda buffers}. When
|
||||
used several times in succession, it will still cycle through all
|
||||
names. But when when you return to the item after some time and
|
||||
execute @kbd{C-c C-t} again, it will switch from each name directly to
|
||||
DONE. Use prefix arguments or completion to quickly select a specific
|
||||
name.
|
||||
|
||||
@node Per file keywords, , TODO types, TODO extensions
|
||||
@subsection Setting up TODO keywords for individual files
|
||||
|
|
@ -647,11 +630,12 @@ to quickly select a specific name.
|
|||
@cindex per file keywords
|
||||
|
||||
It can be very useful to use different aspects of the TODO mechanism
|
||||
in different files. For this you need to add special lines to the
|
||||
file which set the keywords and interpretation for that file only.
|
||||
For example, to set one of the two examples discussed above, you
|
||||
need one of the following lines, starting in column zero anywhere in
|
||||
the file:
|
||||
in different files, which is not possible with the global settings
|
||||
described above. For file-local settings, you need to add special
|
||||
lines to the file which set the keywords and interpretation for that
|
||||
file only. For example, to set one of the two examples discussed
|
||||
above, you need one of the following lines, starting in column zero
|
||||
anywhere in the file:
|
||||
|
||||
@example
|
||||
#+SEQ_TODO: TODO FEEDBACK VERIFY DONE
|
||||
|
|
@ -664,11 +648,15 @@ the file:
|
|||
@samp{#+} into the buffer and then use @kbd{M-@key{TAB}} completion.
|
||||
|
||||
@cindex DONE, final TODO keyword
|
||||
Remember that the last keyword must always mean that the
|
||||
item is DONE (you may use a different word, though). After changing
|
||||
these lines, use @kbd{M-x normal-mode} to make the changes known to
|
||||
Org-mode. Also note that in each file, only one of the two aspects
|
||||
of TODO keywords can be used.
|
||||
Remember that the last keyword must always mean that the item is DONE
|
||||
(you may use a different word, though). Also note that in each file,
|
||||
only one of the two aspects of TODO keywords can be used. After
|
||||
changing one of these lines, use @kbd{C-c C-c} with the cursor still
|
||||
in the line to make the changes known to Org-mode@footnote{Org-mode
|
||||
parses these lines only when Org-mode is activated after visiting a
|
||||
file. @kbd{C-c C-c} with the cursor in a line starting with @samp{#-}
|
||||
is simply restarting Org-mode, making sure that these changes will be
|
||||
respected.}.
|
||||
|
||||
If you want to use very many keywords, for example when working with a
|
||||
large group of people, you may split the names over several lines:
|
||||
|
|
@ -680,6 +668,43 @@ large group of people, you may split the names over several lines:
|
|||
#+TYP_TODO: DONE
|
||||
@end example
|
||||
|
||||
@node Priorities, , TODO extensions, TODO items
|
||||
@section Priorities
|
||||
@cindex priorities
|
||||
|
||||
If you use Org-mode extensively to organize your work, you may end up
|
||||
with a number of TODO entries so large that you'd like to prioritize
|
||||
them. This can be done by placing a @emph{priority cookie} into the
|
||||
headline, like this
|
||||
|
||||
@example
|
||||
*** TODO [#A] Write letter to Sam Fortune
|
||||
@end example
|
||||
|
||||
@noindent
|
||||
With its standard setup, Org-mode supports priorities @samp{A},
|
||||
@samp{B}, and @samp{C}. @samp{A} is the highest priority. An entry
|
||||
without a cookie is treated as priority @samp{B}. Priorities make a
|
||||
difference only in the agenda (@pxref{Agenda}).
|
||||
|
||||
@table @kbd
|
||||
@kindex @kbd{C-c ,}
|
||||
@item @kbd{C-c ,}
|
||||
Set the priority of the current item. The command prompts for a
|
||||
priority character @samp{A}, @samp{B} or @samp{C}. When you press
|
||||
@key{SPC} instead, the priority cookie is removed from the headline.
|
||||
The priorities can also be changed ``remotely'' from the timeline and
|
||||
agenda buffer with the @kbd{,} command (@pxref{Agenda commands}).
|
||||
|
||||
@kindex S-@key{up}
|
||||
@kindex S-@key{down}
|
||||
@item S-@key{up}
|
||||
@itemx S-@key{down}
|
||||
Increase/decrease priority of current item. Note that these keys are
|
||||
also used to modify time stamps (@pxref{Creating timestamps}).
|
||||
@end table
|
||||
|
||||
|
||||
@node Tables, Hyperlinks, TODO items, Top
|
||||
@chapter Tables
|
||||
@cindex tables
|
||||
|
|
@ -995,7 +1020,7 @@ RMAIL, WANDERLUST, GNUS and BBDB buffers, the link will point to the
|
|||
current article/entry. For W3 and W3M buffer, the link goes to the
|
||||
current URL. For any other files, the link will just point to the file.
|
||||
The key binding @kbd{C-c l} is only a suggestion - see
|
||||
@ref{Installation}.
|
||||
@ref{Installation and Activation}.
|
||||
|
||||
@kindex C-c C-l
|
||||
@item C-c C-l
|
||||
|
|
@ -1048,7 +1073,6 @@ directly to the correct location in your Org-mode outline tree. The
|
|||
following customization will tell @emph{Remember} to use org files as
|
||||
target, and to create annotations compatible with Org-mode links.
|
||||
|
||||
|
||||
@c FIXME: The autoload will not be necessary when Org-mode is part of Emacs
|
||||
@example
|
||||
(autoload 'org-remember-annotation "org")
|
||||
|
|
@ -1113,7 +1137,7 @@ A time stamp is a specification of a date (possibly with time) in a
|
|||
special format, either @samp{<2003-09-16 Tue>} or @samp{<2003-09-16
|
||||
Tue 09:39>}. A time stamp can appear anywhere in the headline or body
|
||||
of an org-tree entry. Its presence allows to show entries on specific
|
||||
dates in the agenda (@pxref{Agenda (multiple files)}). We distinguish:
|
||||
dates in the agenda (@pxref{Agenda}). We distinguish:
|
||||
|
||||
@table @var
|
||||
@cindex timestamp
|
||||
|
|
@ -1192,7 +1216,7 @@ instead.
|
|||
@kindex C-c C-o
|
||||
@item C-c C-o
|
||||
Access the agenda for the date given by the time stamp at point
|
||||
(@pxref{Agenda (multiple files)}).
|
||||
(@pxref{Agenda}).
|
||||
|
||||
@kindex C-c C-d
|
||||
@item C-c C-d
|
||||
|
|
@ -1303,13 +1327,13 @@ which covers all of your current projects, action items and
|
|||
appointments.
|
||||
|
||||
@menu
|
||||
* Timeline (single file):: Time-sorted view for single file
|
||||
* Agenda (multiple files):: Your weekly planner
|
||||
* Timeline:: Time-sorted view for single file
|
||||
* Agenda:: Your weekly planner
|
||||
* Agenda commands:: Remote editing of org trees
|
||||
* Calendar/Diary integration:: Integrating Anniversaries and more
|
||||
@end menu
|
||||
|
||||
@node Timeline (single file), Agenda (multiple files), Timeline and Agenda, Timeline and Agenda
|
||||
@node Timeline, Agenda, Timeline and Agenda, Timeline and Agenda
|
||||
@section Timeline for a single file
|
||||
@cindex single file summary
|
||||
@cindex agenda, for single file
|
||||
|
|
@ -1335,9 +1359,9 @@ The timeline is shown in a temporary buffer @file{*Org Agenda*}. The
|
|||
commands available in the Agenda buffer are listed in @ref{Agenda
|
||||
commands}.
|
||||
|
||||
@node Agenda (multiple files), Agenda commands, Timeline (single file), Timeline and Agenda
|
||||
@section Agenda from multiple files
|
||||
@cindex agenda, from multiple files
|
||||
@node Agenda, Agenda commands, Timeline, Timeline and Agenda
|
||||
@section Agenda
|
||||
@cindex agenda
|
||||
|
||||
An agenda can be compiled from one or more org files. The main
|
||||
purpose of this command is to act like a planner, in order to show you
|
||||
|
|
@ -1374,7 +1398,7 @@ when the variable @code{org-agenda-include-all-todo} is @code{t}), all
|
|||
unfinished TODO items (also those without a date) are also listed at
|
||||
the beginning of the buffer, before the first date.@*
|
||||
The key binding @kbd{C-c a} is only a suggestion - see
|
||||
@ref{Installation}.
|
||||
@ref{Installation and Activation}.
|
||||
@end table
|
||||
|
||||
The commands available in the Agenda buffer are listed in
|
||||
|
|
@ -1384,24 +1408,18 @@ The commands available in the Agenda buffer are listed in
|
|||
|
||||
@cindex category
|
||||
In the agenda buffer, each entry is preceded by a @emph{category},
|
||||
which is derived from the file name. You can also set the category of
|
||||
a file through file variables, for example by making the first line of
|
||||
the file look like this:
|
||||
|
||||
@cindex file variables
|
||||
@example
|
||||
Planet Finder -*- mode: org; org-category: Cheops -*-
|
||||
@end example
|
||||
@noindent
|
||||
Or, like with TODO keywords (@pxref{Per file keywords}), you can
|
||||
insert a special line anywhere in the file:
|
||||
|
||||
which is derived from the file name. The category can also be set
|
||||
with a special line anywhere in the buffer, looking like this:
|
||||
@example
|
||||
#+CATEGORY: Cheops
|
||||
@end example
|
||||
@noindent
|
||||
The display looks best if the category is no longer than 10 characters.
|
||||
After changing this line, press @kbd{C-c C-c} with the cursor still in
|
||||
the line, to make the changes know to org-mode. Otherwise, the change
|
||||
will only be active the next time you visit this file with Emacs.
|
||||
|
||||
The display in the agenda buffer looks best if the category is no
|
||||
longer than 10 characters.
|
||||
|
||||
@subsection Sorting of agenda items
|
||||
@cindex sorting, of agenda items
|
||||
|
|
@ -1427,7 +1445,7 @@ plus additional increments for overdue scheduled or deadline items.
|
|||
Sorting can be customized using the variable
|
||||
@code{org-agenda-sorting-strategy}.
|
||||
|
||||
@node Agenda commands, Calendar/Diary integration, Agenda (multiple files), Timeline and Agenda
|
||||
@node Agenda commands, Calendar/Diary integration, Agenda, Timeline and Agenda
|
||||
@section Commands in the agenda buffer
|
||||
|
||||
Entries in the agenda buffer are linked back to the org file or diary
|
||||
|
|
@ -1443,6 +1461,13 @@ commands are available for both timelines and the agenda. The
|
|||
exceptions are marked.
|
||||
|
||||
@table @kbd
|
||||
@tsubheading{Motion}
|
||||
@kindex n
|
||||
@item n
|
||||
Next line (same as @key{up}).
|
||||
@kindex p
|
||||
@item p
|
||||
Previous line (same as @key{down}).
|
||||
@tsubheading{View/GoTo org file}
|
||||
@kindex mouse-3
|
||||
@kindex @key{SPC}
|
||||
|
|
@ -1470,7 +1495,6 @@ Toggle follow mode. In follow mode, as you move the cursor through
|
|||
the agenda buffer, the other window always shows the corresponding
|
||||
location in the org file.
|
||||
|
||||
|
||||
@tsubheading{Change display}
|
||||
@kindex o
|
||||
@item o
|
||||
|
|
@ -1515,8 +1539,8 @@ Digit argument.
|
|||
Change the TODO state of the item, both in the agenda and in the
|
||||
original org file.
|
||||
|
||||
@kindex p
|
||||
@item p
|
||||
@kindex ,
|
||||
@item ,
|
||||
Set the priority for the current item. Org-mode prompts for the
|
||||
priority character. If you reply with @key{SPC}, the priority cookie
|
||||
is removed from the entry.
|
||||
|
|
@ -1526,13 +1550,17 @@ is removed from the entry.
|
|||
Display weighted priority of current item.
|
||||
|
||||
@kindex +
|
||||
@kindex S-@key{up}
|
||||
@item +
|
||||
@item S-@key{up}
|
||||
Increase the priority of the current item. The priority is changed in
|
||||
the original buffer, but the agenda is not resorted. Use the @kbd{r}
|
||||
key for this.
|
||||
|
||||
@kindex -
|
||||
@kindex S-@key{down}
|
||||
@item -
|
||||
@item S-@key{down}
|
||||
Decrease the priority of the current item.
|
||||
|
||||
@kindex S-@key{right}
|
||||
|
|
@ -1568,10 +1596,9 @@ The date is taken from the cursor position.
|
|||
@item c
|
||||
Open the Emacs calendar and move to the date at the agenda cursor.
|
||||
|
||||
@kindex C
|
||||
@item C
|
||||
Convert the date at cursor into many other cultural and historic
|
||||
calendars.
|
||||
@item c
|
||||
When in the calendar, compute and show the Org-mode agenda for the
|
||||
date at the cursor.
|
||||
|
||||
@kindex M
|
||||
@item M
|
||||
|
|
@ -1579,8 +1606,13 @@ Show the phases of the moon for three month around current date.
|
|||
|
||||
@kindex S
|
||||
@item S
|
||||
Show sunrise and sunset times. The location must be set with calendar
|
||||
variables, see documentation of the Emacs calendar.
|
||||
Show sunrise and sunset times. The geographical location must be set
|
||||
with calendar variables, see documentation of the Emacs calendar.
|
||||
|
||||
@kindex C
|
||||
@item C
|
||||
Convert the date at cursor into many other cultural and historic
|
||||
calendars.
|
||||
|
||||
@kindex H
|
||||
@item H
|
||||
|
|
@ -1643,7 +1675,8 @@ file, in order to edit existing diary entries. Also the @kbd{i}
|
|||
command to insert new entries for the current date works in the agenda
|
||||
buffer, as well as the commands @kbd{S}, @kbd{M}, and @kbd{C} to
|
||||
display Sunrise/Sunset times, show lunar phases and to convert to
|
||||
other calendars, respectively.
|
||||
other calendars, respectively. @kbd{c} can be used to switch back and
|
||||
forth between calendar and agenda.
|
||||
|
||||
@node Agenda to diary, , Diary to agenda, Calendar/Diary integration
|
||||
@subsection Including the agenda into the diary
|
||||
|
|
@ -1651,8 +1684,8 @@ other calendars, respectively.
|
|||
If you prefer to use the Emacs diary as your main instrument and if
|
||||
you wish to include the Org-mode agenda into it, the following steps
|
||||
are necessary: Autoload the function @command{org-diary} as shown
|
||||
above under @ref{Installation}. You also need to use @emph{fancy
|
||||
diary display} by setting in @file{.emacs}:
|
||||
above under @ref{Installation and Activation}. You also need to use
|
||||
@emph{fancy diary display} by setting in @file{.emacs}:
|
||||
|
||||
@lisp
|
||||
(add-hook 'diary-display-hook 'fancy-diary-display)
|
||||
|
|
@ -2038,11 +2071,6 @@ planner.
|
|||
Org mode cooperates with table.el, see @ref{table.el}.
|
||||
@end table
|
||||
|
||||
@c EmacsWiki
|
||||
@c organizer-mode
|
||||
@c todo-mode
|
||||
@c records mode
|
||||
|
||||
@page @c FIXME
|
||||
|
||||
@node Acknowledgments, Bugs, Interaction, Miscellaneous
|
||||
|
|
@ -2068,9 +2096,9 @@ in HTML output, and other export improvements.
|
|||
Christian Egli converted the documentation into TeXInfo format. He
|
||||
also showed me his plans for a multifile summary for Org-mode. Some of
|
||||
his ideas have found their way into the agenda.
|
||||
@item
|
||||
Philip Rooke created the Org-mode reference card and did some
|
||||
beta-testing.
|
||||
@item
|
||||
Philip Rooke created the Org-mode reference card. He also helped with
|
||||
beta testing and contributed a number of very useful ideas.
|
||||
@item
|
||||
Linking to VM/BBDB/GNUS was inspired by Tom Shannon's
|
||||
@file{organizer-mode.el}.
|
||||
|
|
@ -2102,8 +2130,8 @@ the file), it does so silently. No error message is displayed.
|
|||
Under XEmacs, if Org-mode entries are included into the diary, it is
|
||||
not possible to jump back from the diary to the org file. Apparently,
|
||||
the text properties are lost when the fancy-diary-display is used.
|
||||
However, from Org-mode's agenda (created with @kbd{C-c C-r} or
|
||||
@kbd{M-x org-agenda}), things do work correctly.
|
||||
However, from Org-mode's timeline and agenda buffers (created with
|
||||
@kbd{C-c C-r} and @kbd{C-c a}), things do work correctly.
|
||||
@item
|
||||
Linux should also have a default viewer application, using mailcap.
|
||||
Maybe we can use GNUS or VM mime code? Or dired's guessing commands?
|
||||
|
|
@ -2126,7 +2154,6 @@ The exporters work well, but could be made more efficient.
|
|||
|
||||
@bye
|
||||
|
||||
|
||||
@ignore
|
||||
arch-tag: 7893d1fe-cc57-4d13-b5e5-f494a1bcc7ac
|
||||
@end ignore
|
||||
|
|
|
|||
|
|
@ -891,10 +891,13 @@ message is selected in the Rmail buffer.
|
|||
|
||||
Almost all Rmail commands work in the summary buffer as well as in the
|
||||
Rmail buffer. Thus, @kbd{d} in the summary buffer deletes the current
|
||||
message, @kbd{u} undeletes, and @kbd{x} expunges. @kbd{o} and @kbd{C-o}
|
||||
output the current message to a file; @kbd{r} starts a reply to it. You
|
||||
can scroll the current message while remaining in the summary buffer
|
||||
using @key{SPC} and @key{DEL}.
|
||||
message, @kbd{u} undeletes, and @kbd{x} expunges. (However, in the
|
||||
summary buffer, a numeric argument to @kbd{d}, @kbd{C-d} and @kbd{u}
|
||||
serves as a repeat count. A negative argument reverses the meaning of
|
||||
@kbd{d} and @kbd{C-d}.) @kbd{o} and @kbd{C-o} output the current
|
||||
message to a file; @kbd{r} starts a reply to it. You can scroll the
|
||||
current message while remaining in the summary buffer using @key{SPC}
|
||||
and @key{DEL}.
|
||||
|
||||
The Rmail commands to move between messages also work in the summary
|
||||
buffer, but with a twist: they move through the set of messages included
|
||||
|
|
|
|||
|
|
@ -175,6 +175,10 @@ Width in pixels of the external border.
|
|||
@item @code{cursorColor} (class @code{Foreground})
|
||||
Color name for text cursor (point).
|
||||
|
||||
@item @code{cursorBlink} (class @code{CursorBlink})
|
||||
Specifies whether to make the cursor blink. The default is @samp{on}. Use
|
||||
@samp{off} or @samp{false} to turn cursor blinking off.
|
||||
|
||||
@item @code{font} (class @code{Font})
|
||||
Font name for text (or fontset name, @pxref{Fontsets}).
|
||||
|
||||
|
|
|
|||
130
src/ChangeLog
130
src/ChangeLog
|
|
@ -1,3 +1,102 @@
|
|||
2005-04-16 Dan Nicolaescu <dann@ics.uci.edu>
|
||||
|
||||
* term.c (struct keys): Add support for shifted keys.
|
||||
|
||||
2005-04-16 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* xdisp.c (with_echo_area_buffer): Delete WHICH < 0 case.
|
||||
(set_message): Call with_echo_area_buffer with WHICH = 0.
|
||||
(set_message_1): Erase the echo area buffer first thing.
|
||||
(echo_area_display): Don't clear echo_message_buffer.
|
||||
|
||||
2005-04-16 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* Makefile.in (mac.o): Depend on charset.h and coding.h.
|
||||
|
||||
* mac.c: Include charset.h and coding.h.
|
||||
[TARGET_API_MAC_CARBON] (Qutf_8): Remove extern.
|
||||
[TARGET_API_MAC_CARBON] (cfstring_create_with_string): New
|
||||
function.
|
||||
[TARGET_API_MAC_CARBON] (Fmac_get_preference): Use it.
|
||||
|
||||
* macfns.c [TARGET_API_MAC_CARBON] (Fx_file_dialog): Likewise.
|
||||
|
||||
* image.c [MAC_OSX] (image_load_quartz2d): Likewise.
|
||||
|
||||
* macterm.c (x_autoselect_window_p): Remove variable.
|
||||
(last_window): New variable.
|
||||
(XTreassert_line_highlight, x_change_line_highlight): Remove
|
||||
declarations.
|
||||
(mac_focus_changed, x_detect_focus_change): New functions and
|
||||
declarations.
|
||||
(XTextExtents16, front_emacs_window): Remove function.
|
||||
(mac_focus_frame): New function.
|
||||
(XTmouse_position, do_menu_choice, do_zoom_window, XTread_socket)
|
||||
(mac_check_for_quit_char): Use it instead of front_emacs_window.
|
||||
(x_scroll_bar_report_motion): Obtain window from control owner.
|
||||
(x_make_frame_invisible): Set window manager size hint.
|
||||
(do_mouse_moved): Remove function.
|
||||
(XTread_socket): Move its contents here. Generate select-window
|
||||
event on mouse movement if needed. Use x_detect_focus_change on
|
||||
activate/deactivate events. Don't deiconify frame or invalidate
|
||||
window rectangle when dnd items are dropped. Don't
|
||||
activate/deactivate root control.
|
||||
(frame_highlight, frame_unhighlight): Activate/deactivate root
|
||||
control here.
|
||||
(syms_of_macterm): Delete DEFVAR_BOOL for x_autoselect_window_p.
|
||||
|
||||
* macterm.h (cfstring_create_with_string) [TARGET_API_MAC_CARBON]:
|
||||
New extern.
|
||||
|
||||
2005-04-15 Luc Teirlinck <teirllm@auburn.edu>
|
||||
|
||||
* Makefile.in: Define new macro TOOLTIP_SUPPORT.
|
||||
(lisp): Use it.
|
||||
(SOME_MACHINE_LISP): Add tooltip.
|
||||
|
||||
2005-04-14 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* mac.c [!TARGET_API_MAC_CARBON]: Include MacLocales.h. Don't
|
||||
include TextEncodingConverter.h.
|
||||
(mac_system_script_code, Vmac_system_locale): New variables.
|
||||
(syms_of_mac): Defvar them.
|
||||
(mac_get_system_locale): New function.
|
||||
|
||||
* macfns.c (x_set_name, x_set_title) [!TARGET_API_MAC_CARBON]: Use
|
||||
ENCODE_SYSTEM to encode title bar string.
|
||||
(x_create_tip_frame): Apply 2005-03-18 change for xfns.c.
|
||||
(Fx_file_dialog) [TARGET_API_MAC_CARBON && !MAC_OSX]: Use
|
||||
CFStringGetSystemEncoding to get system default string encoding.
|
||||
|
||||
* macterm.c [!TARGET_API_MAC_CARBON]: Don't include
|
||||
TextEncodingConverter.h.
|
||||
|
||||
2005-04-13 Steven Tamm <steventamm@mac.com>
|
||||
|
||||
* macterm.c (syms_of_macterm): Remove redundant definition of
|
||||
mac-pass-control-to-system.
|
||||
|
||||
2005-04-12 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* window.c (Fset_window_configuration): Be careful when you choose
|
||||
among several possible points for the new_current_buffer.
|
||||
|
||||
2005-04-12 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
|
||||
|
||||
* keyboard.c (poll_for_input) [SYNC_INPUT]: Don't call
|
||||
poll_for_input_1. Set interrupt_input_pending to 1 instead.
|
||||
(Qlanguage_change) [MAC_OS]: New variable.
|
||||
(syms_of_keyboard) [MAC_OS]: Intern and staticpro it.
|
||||
(kbd_buffer_get_event) [MAC_OS]: Make event for LANGUAGE_CHANGE_EVENT.
|
||||
|
||||
* macterm.c (mac_keyboard_text_encoding)
|
||||
(current_mac_keyboard_text_encoding): Remove variables.
|
||||
(XTread_socket): Store language-change event if keyboard script change
|
||||
is detected. Don't convert input to `mac_keyboard_text_encoding'.
|
||||
(syms_of_macterm): Delete DEFVAR_INT for mac-keyboard-text-encoding.
|
||||
|
||||
* termhooks.h (enum event_kind) [MAC_OS]: Add LANGUAGE_CHANGE_EVENT.
|
||||
|
||||
2005-04-10 Richard M. Stallman <rms@gnu.org>
|
||||
|
||||
* emacs.c (standard_args): Rename --bare-bones to --quick.
|
||||
|
|
@ -48,8 +147,8 @@
|
|||
* mac.c (cfdate_to_lisp): Add `const' for variable `epoch_gdate'.
|
||||
(Fmac_get_preference): Doc fix.
|
||||
|
||||
* macfns.c (Fx_create_frame, x_create_tip_frame): Add
|
||||
"fontset-mac" to fallback font/fontsets.
|
||||
* macfns.c (Fx_create_frame, x_create_tip_frame):
|
||||
Add "fontset-mac" to fallback font/fontsets.
|
||||
|
||||
2005-04-04 Kim F. Storm <storm@cua.dk>
|
||||
|
||||
|
|
@ -80,8 +179,8 @@
|
|||
Vascii_downcase_table.
|
||||
(fast_string_match_ignore_case): Likewise.
|
||||
(search_buffer): Fix checking of boyer-moore usability.
|
||||
(boyer_moore): Calculate translate_prev_byte1/2/3 in advance. No
|
||||
need of tranlating characters in PAT. Fix calculation of
|
||||
(boyer_moore): Calculate translate_prev_byte1/2/3 in advance.
|
||||
No need of tranlating characters in PAT. Fix calculation of
|
||||
simple_translate.
|
||||
|
||||
2005-03-31 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
|
@ -885,9 +984,9 @@
|
|||
|
||||
2005-02-02 Steven Tamm <steventamm@mac.com>
|
||||
|
||||
* macfns.c (unwind_create_frame): Fixing compile error due to
|
||||
* macfns.c (unwind_create_frame): Fix compile error due to
|
||||
xassert being uncondition, but predicate is.
|
||||
* dispnew.c (update_window): Fixing compile error due to
|
||||
* dispnew.c (update_window): Fix compile error due to
|
||||
xassert being uncondition, but predicate is.
|
||||
|
||||
2005-02-02 Miles Bader <miles@gnu.org>
|
||||
|
|
@ -1031,6 +1130,7 @@
|
|||
|
||||
* s/darwin.h: Removed PTY_ITERATION from here.
|
||||
(DARWIN): Define.
|
||||
|
||||
* process.c (init_process): Default process-connection-type to
|
||||
nil on darwin 6 or less, t if it is 7 or higher. This way the
|
||||
broken pty behavior is still allowed on darwin 6 for interactive
|
||||
|
|
@ -3536,8 +3636,8 @@
|
|||
2004-08-26 Steven Tamm <steventamm@mac.com>
|
||||
|
||||
* fileio.c (Fread_file_name): Call x_file_dialog on carbon on
|
||||
tool-bar/menu click
|
||||
* macfns.c (Fx_file_dialog): Implemented using NavServices
|
||||
tool-bar/menu click.
|
||||
* macfns.c (Fx_file_dialog): Implement using NavServices.
|
||||
|
||||
2004-08-24 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
|
||||
|
||||
|
|
@ -5024,7 +5124,7 @@
|
|||
|
||||
2004-04-26 Steven Tamm <tamm@Steven-Tamms-Computer.local>
|
||||
|
||||
* lread.c (init_lread): Fixing typo HAVE_CARBON test logic
|
||||
* lread.c (init_lread): Fix typo in HAVE_CARBON test logic.
|
||||
|
||||
2004-04-26 Miles Bader <miles@gnu.org>
|
||||
|
||||
|
|
@ -5479,10 +5579,10 @@
|
|||
|
||||
2004-03-11 Steven Tamm <steventamm@mac.com>
|
||||
|
||||
* image.c [MAC_OSX]: Include sys/stat.h
|
||||
* image.c [MAC_OSX]: Include sys/stat.h.
|
||||
|
||||
* macfns.c (syms_of_macfns): Remove definitions of things now
|
||||
defined in image.c
|
||||
defined in image.c.
|
||||
|
||||
2004-03-11 Kim F. Storm <storm@cua.dk>
|
||||
|
||||
|
|
@ -6192,7 +6292,7 @@
|
|||
* macterm.c (Vmac_emulate_three_button_mouse): New variable for
|
||||
controlling emulation of a three button mouse with option and
|
||||
command keys.
|
||||
(Qreverse, mac_get_enumlated_btn): Handle the emulation
|
||||
(Qreverse, mac_get_enumlated_btn): Handle the emulation.
|
||||
(mac_event_to_emacs_modifiers, XTread_socket): Ditto.
|
||||
|
||||
2004-02-15 Kim F. Storm <storm@cua.dk>
|
||||
|
|
@ -11132,7 +11232,7 @@
|
|||
|
||||
2003-01-20 Steven Tamm <steventamm@mac.com>
|
||||
|
||||
* macterm.c (XTread_socket): Checks for valid, visible window
|
||||
* macterm.c (XTread_socket): Check for valid, visible window
|
||||
before sending a scroll-wheel event.
|
||||
|
||||
2003-01-20 Richard M. Stallman <rms@gnu.org>
|
||||
|
|
@ -11491,7 +11591,7 @@
|
|||
|
||||
2002-12-28 Steven Tamm <steventamm@mac.com>
|
||||
|
||||
* Makefile.in (macosx-bundle): Fixes to Mac OS X/Carbon port to
|
||||
* Makefile.in (macosx-bundle): Fix Mac OS X/Carbon port to
|
||||
allow building in a different directory than source. Uses some
|
||||
GNU Make extensions, but there is no other make on Mac OS X.
|
||||
|
||||
|
|
@ -11534,7 +11634,7 @@
|
|||
|
||||
* macterm.c (XTread_socket): Call KeyTranslate for control and
|
||||
meta to deal correctly shifted non-alpha characters, like C-S-5
|
||||
being treated like C-%. Does not look for shift key to deal
|
||||
being treated like C-%. Do not look for shift key to deal
|
||||
with masking off control-key with mac-reverse-ctrl-meta.
|
||||
|
||||
2002-12-21 Richard M. Stallman <rms@gnu.org>
|
||||
|
|
|
|||
|
|
@ -686,6 +686,12 @@ otherobj= $(termcapobj) lastfile.o $(mallocobj) $(allocaobj) $(widgetobj) $(LIBO
|
|||
#define WINNT_SUPPORT
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WINDOW_SYSTEM
|
||||
#define TOOLTIP_SUPPORT ${lispsource}tooltip.elc
|
||||
#else
|
||||
#define TOOLTIP_SUPPORT
|
||||
#endif
|
||||
|
||||
/* List of Lisp files loaded into the dumped Emacs. It's arranged
|
||||
like this because it's easier to generate it semi-mechanically from
|
||||
loadup.el this way.
|
||||
|
|
@ -780,6 +786,7 @@ lisp= \
|
|||
${lispsource}emacs-lisp/timer.elc \
|
||||
${lispsource}vc-hooks.elc \
|
||||
${lispsource}ediff-hook.elc \
|
||||
TOOLTIP_SUPPORT \
|
||||
VMS_SUPPORT \
|
||||
MSDOS_SUPPORT \
|
||||
WINNT_SUPPORT \
|
||||
|
|
@ -887,6 +894,7 @@ SOME_MACHINE_LISP = ${dotdot}/lisp/mouse.elc \
|
|||
${dotdot}/lisp/ls-lisp.elc ${dotdot}/lisp/dos-fns.elc \
|
||||
${dotdot}/lisp/w32-fns.elc ${dotdot}/lisp/dos-w32.elc \
|
||||
${dotdot}/lisp/disp-table.elc ${dotdot}/lisp/dos-vars.elc \
|
||||
${dotdot}/lisp/tooltip.elc \
|
||||
${dotdot}/lisp/international/ccl.elc \
|
||||
${dotdot}/lisp/international/codepage.elc \
|
||||
${dotdot}/lisp/mouse.elc ${dotdot}/lisp/international/fontset.elc \
|
||||
|
|
@ -1233,7 +1241,8 @@ abbrev.o buffer.o callint.o cmds.o dispnew.o editfns.o fileio.o frame.o \
|
|||
fontset.o indent.o insdel.o keyboard.o macros.o minibuf.o msdos.o process.o \
|
||||
scroll.o sysdep.o term.o widget.o window.o xdisp.o xfaces.o xfns.o xmenu.o \
|
||||
xterm.o xselect.o sound.o: macgui.h
|
||||
mac.o: mac.c process.h sysselect.h blockinput.h atimer.h systime.h $(config_h)
|
||||
mac.o: mac.c process.h sysselect.h blockinput.h atimer.h systime.h charset.h \
|
||||
coding.h $(config_h)
|
||||
macfns.o: macfns.c charset.h macterm.h macgui.h frame.h window.h buffer.h \
|
||||
dispextern.h macgui.h fontset.h $(INTERVAL_SRC) keyboard.h blockinput.h \
|
||||
atimer.h systime.h epaths.h termhooks.h coding.h systime.h $(config_h)
|
||||
|
|
|
|||
|
|
@ -2423,7 +2423,7 @@ image_load_quartz2d (f, img, png_p)
|
|||
UNGCPRO;
|
||||
return 0;
|
||||
}
|
||||
path = cfstring_create_with_utf8_cstring (SDATA (file));
|
||||
path = cfstring_create_with_string (file);
|
||||
url = CFURLCreateWithFileSystemPath (NULL, path,
|
||||
kCFURLPOSIXPathStyle, 0);
|
||||
CFRelease (path);
|
||||
|
|
|
|||
|
|
@ -521,7 +521,7 @@ Lisp_Object Qmouse_fixup_help_message;
|
|||
/* Symbols to denote kinds of events. */
|
||||
Lisp_Object Qfunction_key;
|
||||
Lisp_Object Qmouse_click;
|
||||
#ifdef WINDOWSNT
|
||||
#if defined (WINDOWSNT) || defined (MAC_OS)
|
||||
Lisp_Object Qlanguage_change;
|
||||
#endif
|
||||
Lisp_Object Qdrag_n_drop;
|
||||
|
|
@ -2100,7 +2100,11 @@ poll_for_input (timer)
|
|||
struct atimer *timer;
|
||||
{
|
||||
if (poll_suppress_count == 0)
|
||||
#ifdef SYNC_INPUT
|
||||
interrupt_input_pending = 1;
|
||||
#else
|
||||
poll_for_input_1 ();
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif /* POLL_FOR_INPUT */
|
||||
|
|
@ -4026,11 +4030,16 @@ kbd_buffer_get_event (kbp, used_mouse_menu)
|
|||
x_activate_menubar (XFRAME (event->frame_or_window));
|
||||
}
|
||||
#endif
|
||||
#ifdef WINDOWSNT
|
||||
#if defined (WINDOWSNT) || defined (MAC_OS)
|
||||
else if (event->kind == LANGUAGE_CHANGE_EVENT)
|
||||
{
|
||||
#ifdef MAC_OS
|
||||
/* Make an event (language-change (KEY_SCRIPT)). */
|
||||
obj = Fcons (make_number (event->code), Qnil);
|
||||
#else
|
||||
/* Make an event (language-change (FRAME CHARSET LCID)). */
|
||||
obj = Fcons (event->frame_or_window, Qnil);
|
||||
#endif
|
||||
obj = Fcons (Qlanguage_change, Fcons (obj, Qnil));
|
||||
kbd_fetch_ptr = event + 1;
|
||||
}
|
||||
|
|
@ -10976,7 +10985,7 @@ syms_of_keyboard ()
|
|||
staticpro (&Qfunction_key);
|
||||
Qmouse_click = intern ("mouse-click");
|
||||
staticpro (&Qmouse_click);
|
||||
#ifdef WINDOWSNT
|
||||
#if defined (WINDOWSNT) || defined (MAC_OS)
|
||||
Qlanguage_change = intern ("language-change");
|
||||
staticpro (&Qlanguage_change);
|
||||
#endif
|
||||
|
|
|
|||
82
src/mac.c
82
src/mac.c
|
|
@ -31,6 +31,8 @@ Boston, MA 02111-1307, USA. */
|
|||
#include "sysselect.h"
|
||||
#include "systime.h"
|
||||
#include "blockinput.h"
|
||||
#include "charset.h"
|
||||
#include "coding.h"
|
||||
|
||||
#include "macterm.h"
|
||||
|
||||
|
|
@ -49,6 +51,7 @@ Boston, MA 02111-1307, USA. */
|
|||
#include <Events.h>
|
||||
#include <Processes.h>
|
||||
#include <EPPC.h>
|
||||
#include <MacLocales.h>
|
||||
#endif /* not HAVE_CARBON */
|
||||
|
||||
#include <utime.h>
|
||||
|
|
@ -67,6 +70,12 @@ Boston, MA 02111-1307, USA. */
|
|||
|
||||
Lisp_Object QCLIPBOARD;
|
||||
|
||||
/* The system script code. */
|
||||
static int mac_system_script_code;
|
||||
|
||||
/* The system locale identifier string. */
|
||||
static Lisp_Object Vmac_system_locale;
|
||||
|
||||
/* An instance of the AppleScript component. */
|
||||
static ComponentInstance as_scripting_component;
|
||||
/* The single script context used for all script executions. */
|
||||
|
|
@ -258,7 +267,6 @@ posix_to_mac_pathname (const char *ufn, char *mfn, int mfnbuflen)
|
|||
#if TARGET_API_MAC_CARBON
|
||||
static Lisp_Object Qstring, Qnumber, Qboolean, Qdate, Qdata;
|
||||
static Lisp_Object Qarray, Qdictionary;
|
||||
extern Lisp_Object Qutf_8;
|
||||
#define DECODE_UTF_8(str) code_convert_string_norecord (str, Qutf_8, 0)
|
||||
|
||||
struct cfdict_context
|
||||
|
|
@ -267,7 +275,7 @@ struct cfdict_context
|
|||
int with_tag, hash_bound;
|
||||
};
|
||||
|
||||
/* C string to CFString. */
|
||||
/* C string to CFString. */
|
||||
|
||||
CFStringRef
|
||||
cfstring_create_with_utf8_cstring (c_str)
|
||||
|
|
@ -284,6 +292,37 @@ cfstring_create_with_utf8_cstring (c_str)
|
|||
}
|
||||
|
||||
|
||||
/* Lisp string to CFString. */
|
||||
|
||||
CFStringRef
|
||||
cfstring_create_with_string (s)
|
||||
Lisp_Object s;
|
||||
{
|
||||
CFStringRef string = NULL;
|
||||
|
||||
if (STRING_MULTIBYTE (s))
|
||||
{
|
||||
char *p, *end = SDATA (s) + SBYTES (s);
|
||||
|
||||
for (p = SDATA (s); p < end; p++)
|
||||
if (!isascii (*p))
|
||||
{
|
||||
s = ENCODE_UTF_8 (s);
|
||||
break;
|
||||
}
|
||||
string = CFStringCreateWithBytes (NULL, SDATA (s), SBYTES (s),
|
||||
kCFStringEncodingUTF8, false);
|
||||
}
|
||||
|
||||
if (string == NULL)
|
||||
/* Failed to interpret as UTF 8. Fall back on Mac Roman. */
|
||||
string = CFStringCreateWithBytes (NULL, SDATA (s), SBYTES (s),
|
||||
kCFStringEncodingMacRoman, false);
|
||||
|
||||
return string;
|
||||
}
|
||||
|
||||
|
||||
/* From CFData to a lisp string. Always returns a unibyte string. */
|
||||
|
||||
Lisp_Object
|
||||
|
|
@ -3704,11 +3743,11 @@ otherwise. */)
|
|||
app_id = kCFPreferencesCurrentApplication;
|
||||
if (!NILP (application))
|
||||
{
|
||||
app_id = cfstring_create_with_utf8_cstring (SDATA (application));
|
||||
app_id = cfstring_create_with_string (application);
|
||||
if (app_id == NULL)
|
||||
goto out;
|
||||
}
|
||||
key_str = cfstring_create_with_utf8_cstring (SDATA (XCAR (key)));
|
||||
key_str = cfstring_create_with_string (XCAR (key));
|
||||
if (key_str == NULL)
|
||||
goto out;
|
||||
app_plist = CFPreferencesCopyAppValue (key_str, app_id);
|
||||
|
|
@ -3721,7 +3760,7 @@ otherwise. */)
|
|||
{
|
||||
if (CFGetTypeID (plist) != CFDictionaryGetTypeID ())
|
||||
break;
|
||||
key_str = cfstring_create_with_utf8_cstring (SDATA (XCAR (key)));
|
||||
key_str = cfstring_create_with_string (XCAR (key));
|
||||
if (key_str == NULL)
|
||||
goto out;
|
||||
plist = CFDictionaryGetValue (plist, key_str);
|
||||
|
|
@ -4167,6 +4206,29 @@ init_mac_osx_environment ()
|
|||
}
|
||||
#endif /* MAC_OSX */
|
||||
|
||||
|
||||
static Lisp_Object
|
||||
mac_get_system_locale ()
|
||||
{
|
||||
OSErr err;
|
||||
LangCode lang;
|
||||
RegionCode region;
|
||||
LocaleRef locale;
|
||||
Str255 str;
|
||||
|
||||
lang = GetScriptVariable (smSystemScript, smScriptLang);
|
||||
region = GetScriptManagerVariable (smRegionCode);
|
||||
err = LocaleRefFromLangOrRegionCode (lang, region, &locale);
|
||||
if (err == noErr)
|
||||
err = LocaleRefGetPartString (locale, kLocaleAllPartsMask,
|
||||
sizeof (str), str);
|
||||
if (err == noErr)
|
||||
return build_string (str);
|
||||
else
|
||||
return Qnil;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
syms_of_mac ()
|
||||
{
|
||||
|
|
@ -4197,6 +4259,16 @@ syms_of_mac ()
|
|||
defsubr (&Sdo_applescript);
|
||||
defsubr (&Smac_file_name_to_posix);
|
||||
defsubr (&Sposix_file_name_to_mac);
|
||||
|
||||
DEFVAR_INT ("mac-system-script-code", &mac_system_script_code,
|
||||
doc: /* The system script code. */);
|
||||
mac_system_script_code = (ScriptCode) GetScriptManagerVariable (smSysScript);
|
||||
|
||||
DEFVAR_LISP ("mac-system-locale", &Vmac_system_locale,
|
||||
doc: /* The system locale identifier string.
|
||||
This is not a POSIX locale ID, but an ICU locale ID. So encoding
|
||||
information is not included. */);
|
||||
Vmac_system_locale = mac_get_system_locale ();
|
||||
}
|
||||
|
||||
/* arch-tag: 29d30c1f-0c6b-4f88-8a6d-0558d7f9dbff
|
||||
|
|
|
|||
18
src/macfns.c
18
src/macfns.c
|
|
@ -1895,7 +1895,7 @@ x_set_name (f, name, explicit)
|
|||
#if TARGET_API_MAC_CARBON
|
||||
name = ENCODE_UTF_8 (name);
|
||||
#else
|
||||
return;
|
||||
name = ENCODE_SYSTEM (name);
|
||||
#endif
|
||||
|
||||
BLOCK_INPUT;
|
||||
|
|
@ -1977,7 +1977,7 @@ x_set_title (f, name, old_name)
|
|||
#if TARGET_API_MAC_CARBON
|
||||
name = ENCODE_UTF_8 (name);
|
||||
#else
|
||||
return;
|
||||
name = ENCODE_SYSTEM (name);
|
||||
#endif
|
||||
|
||||
BLOCK_INPUT;
|
||||
|
|
@ -3637,9 +3637,6 @@ x_create_tip_frame (dpyinfo, parms, text)
|
|||
|
||||
check_mac ();
|
||||
|
||||
/* Use this general default value to start with until we know if
|
||||
this frame has a specified name. */
|
||||
Vx_resource_name = Vinvocation_name;
|
||||
|
||||
#ifdef MULTI_KBOARD
|
||||
kb = dpyinfo->kboard;
|
||||
|
|
@ -3653,7 +3650,6 @@ x_create_tip_frame (dpyinfo, parms, text)
|
|||
&& !EQ (name, Qunbound)
|
||||
&& !NILP (name))
|
||||
error ("Invalid frame name--not a string or nil");
|
||||
Vx_resource_name = name;
|
||||
|
||||
frame = Qnil;
|
||||
GCPRO3 (parms, name, frame);
|
||||
|
|
@ -4252,8 +4248,7 @@ If ONLY-DIR-P is non-nil, the user can only select directories. */)
|
|||
options.optionFlags |= kNavSelectAllReadableItem;
|
||||
if (!NILP(prompt))
|
||||
{
|
||||
message =
|
||||
cfstring_create_with_utf8_cstring (SDATA (ENCODE_UTF_8 (prompt)));
|
||||
message = cfstring_create_with_string (prompt);
|
||||
options.message = message;
|
||||
}
|
||||
/* Don't set the application, let it use default.
|
||||
|
|
@ -4362,7 +4357,12 @@ If ONLY-DIR-P is non-nil, the user can only select directories. */)
|
|||
filename[len++] = '/';
|
||||
CFStringGetCString(reply.saveFileName, filename+len,
|
||||
sizeof (filename) - len,
|
||||
kCFStringEncodingUTF8);
|
||||
#if MAC_OSX
|
||||
kCFStringEncodingUTF8
|
||||
#else
|
||||
CFStringGetSystemEncoding ()
|
||||
#endif
|
||||
);
|
||||
}
|
||||
file = DECODE_FILE (make_unibyte_string (filename,
|
||||
strlen (filename)));
|
||||
|
|
|
|||
467
src/macterm.c
467
src/macterm.c
|
|
@ -95,6 +95,7 @@ Boston, MA 02111-1307, USA. */
|
|||
: controlKey)
|
||||
#define macAltKey (NILP (Vmac_command_key_is_meta) ? cmdKey : optionKey)
|
||||
|
||||
#define mac_window_to_frame(wp) (((mac_output *) GetWRefCon (wp))->mFP)
|
||||
|
||||
|
||||
/* Non-nil means Emacs uses toolkit scroll bars. */
|
||||
|
|
@ -110,9 +111,8 @@ Lisp_Object Vmac_use_core_graphics;
|
|||
|
||||
static int any_help_event_p;
|
||||
|
||||
/* Non-zero means autoselect window with the mouse cursor. */
|
||||
|
||||
int x_autoselect_window_p;
|
||||
/* Last window where we saw the mouse. Used by mouse-autoselect-window. */
|
||||
static Lisp_Object last_window;
|
||||
|
||||
/* Non-zero means make use of UNDERLINE_POSITION font properties. */
|
||||
|
||||
|
|
@ -273,14 +273,16 @@ static void x_font_min_bounds P_ ((XFontStruct *, int *, int *));
|
|||
static int x_compute_min_glyph_bounds P_ ((struct frame *));
|
||||
static void x_update_end P_ ((struct frame *));
|
||||
static void XTframe_up_to_date P_ ((struct frame *));
|
||||
static void XTreassert_line_highlight P_ ((int, int));
|
||||
static void x_change_line_highlight P_ ((int, int, int, int));
|
||||
static void XTset_terminal_modes P_ ((void));
|
||||
static void XTreset_terminal_modes P_ ((void));
|
||||
static void x_clear_frame P_ ((void));
|
||||
static void frame_highlight P_ ((struct frame *));
|
||||
static void frame_unhighlight P_ ((struct frame *));
|
||||
static void x_new_focus_frame P_ ((struct x_display_info *, struct frame *));
|
||||
static void mac_focus_changed P_ ((int, struct mac_display_info *,
|
||||
struct frame *, struct input_event *));
|
||||
static void x_detect_focus_change P_ ((struct mac_display_info *,
|
||||
EventRecord *, struct input_event *));
|
||||
static void XTframe_rehighlight P_ ((struct frame *));
|
||||
static void x_frame_rehighlight P_ ((struct x_display_info *));
|
||||
static void x_draw_hollow_cursor P_ ((struct window *, struct glyph_row *));
|
||||
|
|
@ -1198,15 +1200,6 @@ XSetFont (display, gc, font)
|
|||
}
|
||||
|
||||
|
||||
static void
|
||||
XTextExtents16 (XFontStruct *font, XChar2b *text, int nchars,
|
||||
int *direction,int *font_ascent,
|
||||
int *font_descent, XCharStruct *cs)
|
||||
{
|
||||
/* MAC_TODO: Use GetTextMetrics to do this and inline it below. */
|
||||
}
|
||||
|
||||
|
||||
/* x_sync is a no-op on Mac. */
|
||||
void
|
||||
x_sync (f)
|
||||
|
|
@ -3494,6 +3487,14 @@ static void
|
|||
frame_highlight (f)
|
||||
struct frame *f;
|
||||
{
|
||||
OSErr err;
|
||||
ControlRef root_control;
|
||||
|
||||
BLOCK_INPUT;
|
||||
err = GetRootControl (FRAME_MAC_WINDOW (f), &root_control);
|
||||
if (err == noErr)
|
||||
ActivateControl (root_control);
|
||||
UNBLOCK_INPUT;
|
||||
x_update_cursor (f, 1);
|
||||
}
|
||||
|
||||
|
|
@ -3501,6 +3502,14 @@ static void
|
|||
frame_unhighlight (f)
|
||||
struct frame *f;
|
||||
{
|
||||
OSErr err;
|
||||
ControlRef root_control;
|
||||
|
||||
BLOCK_INPUT;
|
||||
err = GetRootControl (FRAME_MAC_WINDOW (f), &root_control);
|
||||
if (err == noErr)
|
||||
DeactivateControl (root_control);
|
||||
UNBLOCK_INPUT;
|
||||
x_update_cursor (f, 1);
|
||||
}
|
||||
|
||||
|
|
@ -3543,6 +3552,68 @@ x_new_focus_frame (dpyinfo, frame)
|
|||
x_frame_rehighlight (dpyinfo);
|
||||
}
|
||||
|
||||
/* Handle FocusIn and FocusOut state changes for FRAME.
|
||||
If FRAME has focus and there exists more than one frame, puts
|
||||
a FOCUS_IN_EVENT into *BUFP. */
|
||||
|
||||
static void
|
||||
mac_focus_changed (type, dpyinfo, frame, bufp)
|
||||
int type;
|
||||
struct mac_display_info *dpyinfo;
|
||||
struct frame *frame;
|
||||
struct input_event *bufp;
|
||||
{
|
||||
if (type == activeFlag)
|
||||
{
|
||||
if (dpyinfo->x_focus_event_frame != frame)
|
||||
{
|
||||
x_new_focus_frame (dpyinfo, frame);
|
||||
dpyinfo->x_focus_event_frame = frame;
|
||||
|
||||
/* Don't stop displaying the initial startup message
|
||||
for a switch-frame event we don't need. */
|
||||
if (GC_NILP (Vterminal_frame)
|
||||
&& GC_CONSP (Vframe_list)
|
||||
&& !GC_NILP (XCDR (Vframe_list)))
|
||||
{
|
||||
bufp->kind = FOCUS_IN_EVENT;
|
||||
XSETFRAME (bufp->frame_or_window, frame);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (dpyinfo->x_focus_event_frame == frame)
|
||||
{
|
||||
dpyinfo->x_focus_event_frame = 0;
|
||||
x_new_focus_frame (dpyinfo, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* The focus may have changed. Figure out if it is a real focus change,
|
||||
by checking both FocusIn/Out and Enter/LeaveNotify events.
|
||||
|
||||
Returns FOCUS_IN_EVENT event in *BUFP. */
|
||||
|
||||
static void
|
||||
x_detect_focus_change (dpyinfo, event, bufp)
|
||||
struct mac_display_info *dpyinfo;
|
||||
EventRecord *event;
|
||||
struct input_event *bufp;
|
||||
{
|
||||
struct frame *frame;
|
||||
|
||||
frame = mac_window_to_frame ((WindowPtr) event->message);
|
||||
if (! frame)
|
||||
return;
|
||||
|
||||
/* On Mac, this is only called from focus events, so no switch needed. */
|
||||
mac_focus_changed ((event->modifiers & activeFlag),
|
||||
dpyinfo, frame, bufp);
|
||||
}
|
||||
|
||||
|
||||
/* Handle an event saying the mouse has moved out of an Emacs frame. */
|
||||
|
||||
void
|
||||
|
|
@ -3980,25 +4051,19 @@ remember_mouse_glyph (f1, gx, gy)
|
|||
}
|
||||
|
||||
|
||||
static WindowPtr
|
||||
front_emacs_window ()
|
||||
static struct frame *
|
||||
mac_focus_frame (dpyinfo)
|
||||
struct mac_display_info *dpyinfo;
|
||||
{
|
||||
#if TARGET_API_MAC_CARBON
|
||||
WindowPtr wp = GetFrontWindowOfClass (kDocumentWindowClass, true);
|
||||
|
||||
while (wp && !is_emacs_window (wp))
|
||||
wp = GetNextWindowOfClass (wp, kDocumentWindowClass, true);
|
||||
#else
|
||||
WindowPtr wp = FrontWindow ();
|
||||
|
||||
while (wp && (wp == tip_window || !is_emacs_window (wp)))
|
||||
wp = GetNextWindow (wp);
|
||||
#endif
|
||||
|
||||
return wp;
|
||||
if (dpyinfo->x_focus_frame)
|
||||
return dpyinfo->x_focus_frame;
|
||||
else
|
||||
/* Mac version may get events, such as a menu bar click, even when
|
||||
all the frames are invisible. In this case, we regard the
|
||||
event came to the selected frame. */
|
||||
return SELECTED_FRAME ();
|
||||
}
|
||||
|
||||
#define mac_window_to_frame(wp) (((mac_output *) GetWRefCon (wp))->mFP)
|
||||
|
||||
/* Return the current position of the mouse.
|
||||
*fp should be a frame which indicates which display to ask about.
|
||||
|
|
@ -4031,13 +4096,10 @@ XTmouse_position (fp, insist, bar_window, part, x, y, time)
|
|||
{
|
||||
Point mouse_pos;
|
||||
int ignore1, ignore2;
|
||||
WindowPtr wp = front_emacs_window ();
|
||||
struct frame *f;
|
||||
struct frame *f = mac_focus_frame (FRAME_MAC_DISPLAY_INFO (*fp));
|
||||
WindowPtr wp = FRAME_MAC_WINDOW (f);
|
||||
Lisp_Object frame, tail;
|
||||
|
||||
if (is_emacs_window(wp))
|
||||
f = mac_window_to_frame (wp);
|
||||
|
||||
BLOCK_INPUT;
|
||||
|
||||
if (! NILP (last_mouse_scroll_bar) && insist == 0)
|
||||
|
|
@ -4604,7 +4666,12 @@ x_scroll_bar_report_motion (fp, bar_window, part, x, y, time)
|
|||
unsigned long *time;
|
||||
{
|
||||
struct scroll_bar *bar = XSCROLL_BAR (last_mouse_scroll_bar);
|
||||
WindowPtr wp = front_emacs_window ();
|
||||
ControlHandle ch = SCROLL_BAR_CONTROL_HANDLE (bar);
|
||||
#if TARGET_API_MAC_CARBON
|
||||
WindowPtr wp = GetControlOwner (ch);
|
||||
#else
|
||||
WindowPtr wp = (*ch)->contrlOwner;
|
||||
#endif
|
||||
Point mouse_pos;
|
||||
struct frame *f = mac_window_to_frame (wp);
|
||||
int win_y, top_range;
|
||||
|
|
@ -5050,7 +5117,7 @@ x_new_fontset (f, fontsetname)
|
|||
return Qnil;
|
||||
|
||||
/* Since x_new_font doesn't update any fontset information, do it now. */
|
||||
FRAME_FONTSET(f) = fontset;
|
||||
FRAME_FONTSET (f) = fontset;
|
||||
|
||||
return build_string (fontsetname);
|
||||
}
|
||||
|
|
@ -5498,6 +5565,13 @@ x_make_frame_invisible (f)
|
|||
|
||||
BLOCK_INPUT;
|
||||
|
||||
/* Before unmapping the window, update the WM_SIZE_HINTS property to claim
|
||||
that the current position of the window is user-specified, rather than
|
||||
program-specified, so that when the window is mapped again, it will be
|
||||
placed at the same location, without forcing the user to position it
|
||||
by hand again (they have already done that once for this window.) */
|
||||
x_wm_set_size_hint (f, (long) 0, 1);
|
||||
|
||||
HideWindow (FRAME_MAC_WINDOW (f));
|
||||
|
||||
/* We can't distinguish this from iconification
|
||||
|
|
@ -7070,7 +7144,6 @@ x_find_ccl_program (fontp)
|
|||
#include <Dialogs.h>
|
||||
#include <Script.h>
|
||||
#include <Types.h>
|
||||
#include <TextEncodingConverter.h>
|
||||
#include <Resources.h>
|
||||
|
||||
#if __MWERKS__
|
||||
|
|
@ -7146,11 +7219,6 @@ Lisp_Object Vmac_pass_command_to_system;
|
|||
Lisp_Object Vmac_pass_control_to_system;
|
||||
#endif
|
||||
|
||||
/* convert input from Mac keyboard (assumed to be in Mac Roman coding)
|
||||
to this text encoding */
|
||||
int mac_keyboard_text_encoding;
|
||||
int current_mac_keyboard_text_encoding = kTextEncodingMacRoman;
|
||||
|
||||
/* Set in term/mac-win.el to indicate that event loop can now generate
|
||||
drag and drop events. */
|
||||
Lisp_Object Qmac_ready_for_drag_n_drop;
|
||||
|
|
@ -7460,21 +7528,6 @@ do_app_resume ()
|
|||
{
|
||||
/* Window-activate events will do the job. */
|
||||
#if 0
|
||||
WindowPtr wp;
|
||||
struct frame *f;
|
||||
|
||||
wp = front_emacs_window ();
|
||||
if (wp)
|
||||
{
|
||||
f = mac_window_to_frame (wp);
|
||||
|
||||
if (f)
|
||||
{
|
||||
x_new_focus_frame (FRAME_MAC_DISPLAY_INFO (f), f);
|
||||
activate_scroll_bars (f);
|
||||
}
|
||||
}
|
||||
|
||||
app_is_suspended = false;
|
||||
app_sleep_time = WNE_SLEEP_AT_RESUME;
|
||||
#endif
|
||||
|
|
@ -7485,61 +7538,12 @@ do_app_suspend ()
|
|||
{
|
||||
/* Window-deactivate events will do the job. */
|
||||
#if 0
|
||||
WindowPtr wp;
|
||||
struct frame *f;
|
||||
|
||||
wp = front_emacs_window ();
|
||||
if (wp)
|
||||
{
|
||||
f = mac_window_to_frame (wp);
|
||||
|
||||
if (f == FRAME_MAC_DISPLAY_INFO (f)->x_focus_frame)
|
||||
{
|
||||
x_new_focus_frame (FRAME_MAC_DISPLAY_INFO (f), 0);
|
||||
deactivate_scroll_bars (f);
|
||||
}
|
||||
}
|
||||
|
||||
app_is_suspended = true;
|
||||
app_sleep_time = WNE_SLEEP_AT_SUSPEND;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
do_mouse_moved (mouse_pos, f)
|
||||
Point mouse_pos;
|
||||
FRAME_PTR *f;
|
||||
{
|
||||
WindowPtr wp = front_emacs_window ();
|
||||
struct x_display_info *dpyinfo;
|
||||
|
||||
if (wp)
|
||||
{
|
||||
*f = mac_window_to_frame (wp);
|
||||
dpyinfo = FRAME_MAC_DISPLAY_INFO (*f);
|
||||
|
||||
if (dpyinfo->mouse_face_hidden)
|
||||
{
|
||||
dpyinfo->mouse_face_hidden = 0;
|
||||
clear_mouse_face (dpyinfo);
|
||||
}
|
||||
|
||||
SetPortWindowPort (wp);
|
||||
|
||||
GlobalToLocal (&mouse_pos);
|
||||
|
||||
if (dpyinfo->grabbed && tracked_scroll_bar)
|
||||
x_scroll_bar_note_movement (tracked_scroll_bar,
|
||||
mouse_pos.v
|
||||
- XINT (tracked_scroll_bar->top),
|
||||
TickCount() * (1000 / 60));
|
||||
else
|
||||
note_mouse_movement (*f, &mouse_pos);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
do_apple_menu (SInt16 menu_item)
|
||||
{
|
||||
|
|
@ -7576,7 +7580,7 @@ do_menu_choice (SInt32 menu_choice)
|
|||
|
||||
default:
|
||||
{
|
||||
struct frame *f = mac_window_to_frame (front_emacs_window ());
|
||||
struct frame *f = mac_focus_frame (&one_mac_display_info);
|
||||
MenuHandle menu = GetMenuHandle (menu_id);
|
||||
if (menu)
|
||||
{
|
||||
|
|
@ -7654,13 +7658,14 @@ do_zoom_window (WindowPtr w, int zoom_in_or_out)
|
|||
Point top_left;
|
||||
int w_title_height, columns, rows, width, height;
|
||||
struct frame *f = mac_window_to_frame (w);
|
||||
struct mac_display_info *dpyinfo = FRAME_MAC_DISPLAY_INFO (f);
|
||||
|
||||
#if TARGET_API_MAC_CARBON
|
||||
{
|
||||
Point standard_size;
|
||||
|
||||
standard_size.h = FRAME_TEXT_COLS_TO_PIXEL_WIDTH (f, DEFAULT_NUM_COLS);
|
||||
standard_size.v = FRAME_MAC_DISPLAY_INFO (f)->height;
|
||||
standard_size.v = dpyinfo->height;
|
||||
|
||||
if (IsWindowInStandardState (w, &standard_size, &zoom_rect))
|
||||
zoom_in_or_out = inZoomIn;
|
||||
|
|
@ -7716,7 +7721,7 @@ do_zoom_window (WindowPtr w, int zoom_in_or_out)
|
|||
= zoom_rect;
|
||||
}
|
||||
|
||||
ZoomWindow (w, zoom_in_or_out, w == front_emacs_window ());
|
||||
ZoomWindow (w, zoom_in_or_out, f == mac_focus_frame (dpyinfo));
|
||||
|
||||
SetPort (save_port);
|
||||
#endif /* not TARGET_API_MAC_CARBON */
|
||||
|
|
@ -8582,10 +8587,13 @@ XTread_socket (sd, expected, hold_quit)
|
|||
{
|
||||
SInt32 delta;
|
||||
Point point;
|
||||
WindowPtr window_ptr = front_emacs_window ();
|
||||
struct frame *f = mac_focus_frame (dpyinfo);
|
||||
WindowPtr window_ptr;
|
||||
|
||||
if (!IsValidWindowPtr (window_ptr))
|
||||
if (!f)
|
||||
{
|
||||
/* Beep if wheel move occurs when all the frames
|
||||
are invisible. */
|
||||
SysBeep(1);
|
||||
break;
|
||||
}
|
||||
|
|
@ -8601,6 +8609,7 @@ XTread_socket (sd, expected, hold_quit)
|
|||
inev.modifiers = (mac_event_to_emacs_modifiers (eventRef)
|
||||
| ((delta < 0) ? down_modifier
|
||||
: up_modifier));
|
||||
window_ptr = FRAME_MAC_WINDOW (f);
|
||||
SetPortWindowPort (window_ptr);
|
||||
GlobalToLocal (&point);
|
||||
XSETINT (inev.x, point.h);
|
||||
|
|
@ -8659,14 +8668,14 @@ XTread_socket (sd, expected, hold_quit)
|
|||
switch (part_code)
|
||||
{
|
||||
case inMenuBar:
|
||||
f = mac_window_to_frame (front_emacs_window ());
|
||||
f = mac_focus_frame (dpyinfo);
|
||||
saved_menu_event_location = er.where;
|
||||
inev.kind = MENU_BAR_ACTIVATE_EVENT;
|
||||
XSETFRAME (inev.frame_or_window, f);
|
||||
break;
|
||||
|
||||
case inContent:
|
||||
if (window_ptr != front_emacs_window ())
|
||||
if (window_ptr != FRAME_MAC_WINDOW (mac_focus_frame (dpyinfo)))
|
||||
SelectWindow (window_ptr);
|
||||
else
|
||||
{
|
||||
|
|
@ -8857,7 +8866,61 @@ XTread_socket (sd, expected, hold_quit)
|
|||
help_echo_string = help_echo_object = help_echo_window = Qnil;
|
||||
help_echo_pos = -1;
|
||||
|
||||
do_mouse_moved (er.where, &f);
|
||||
if (dpyinfo->grabbed && last_mouse_frame
|
||||
&& FRAME_LIVE_P (last_mouse_frame))
|
||||
f = last_mouse_frame;
|
||||
else
|
||||
f = dpyinfo->x_focus_frame;
|
||||
|
||||
if (dpyinfo->mouse_face_hidden)
|
||||
{
|
||||
dpyinfo->mouse_face_hidden = 0;
|
||||
clear_mouse_face (dpyinfo);
|
||||
}
|
||||
|
||||
if (f)
|
||||
{
|
||||
WindowPtr wp = FRAME_MAC_WINDOW (f);
|
||||
Point mouse_pos = er.where;
|
||||
|
||||
SetPortWindowPort (wp);
|
||||
|
||||
GlobalToLocal (&mouse_pos);
|
||||
|
||||
if (dpyinfo->grabbed && tracked_scroll_bar)
|
||||
x_scroll_bar_note_movement (tracked_scroll_bar,
|
||||
mouse_pos.v
|
||||
- XINT (tracked_scroll_bar->top),
|
||||
TickCount() * (1000 / 60));
|
||||
else
|
||||
{
|
||||
/* Generate SELECT_WINDOW_EVENTs when needed. */
|
||||
if (mouse_autoselect_window)
|
||||
{
|
||||
Lisp_Object window;
|
||||
|
||||
window = window_from_coordinates (f,
|
||||
mouse_pos.h,
|
||||
mouse_pos.v,
|
||||
0, 0, 0, 0);
|
||||
|
||||
/* Window will be selected only when it is
|
||||
not selected now and last mouse movement
|
||||
event was not in it. Minibuffer window
|
||||
will be selected iff it is active. */
|
||||
if (WINDOWP (window)
|
||||
&& !EQ (window, last_window)
|
||||
&& !EQ (window, selected_window))
|
||||
{
|
||||
inev.kind = SELECT_WINDOW_EVENT;
|
||||
inev.frame_or_window = window;
|
||||
}
|
||||
|
||||
last_window=window;
|
||||
}
|
||||
note_mouse_movement (f, &mouse_pos);
|
||||
}
|
||||
}
|
||||
|
||||
/* If the contents of the global variable
|
||||
help_echo_string has changed, generate a
|
||||
|
|
@ -8871,7 +8934,6 @@ XTread_socket (sd, expected, hold_quit)
|
|||
case activateEvt:
|
||||
{
|
||||
WindowPtr window_ptr = (WindowPtr) er.message;
|
||||
ControlRef root_control;
|
||||
|
||||
#if USE_CARBON_EVENTS
|
||||
if (SendEventToEventTarget (eventRef, toolbox_dispatcher)
|
||||
|
|
@ -8887,16 +8949,12 @@ XTread_socket (sd, expected, hold_quit)
|
|||
if (!is_emacs_window (window_ptr))
|
||||
break;
|
||||
|
||||
f = mac_window_to_frame (window_ptr);
|
||||
GetRootControl (window_ptr, &root_control);
|
||||
|
||||
if ((er.modifiers & activeFlag) != 0)
|
||||
{
|
||||
/* A window has been activated */
|
||||
Point mouse_loc = er.where;
|
||||
|
||||
x_new_focus_frame (dpyinfo, f);
|
||||
ActivateControl (root_control);
|
||||
x_detect_focus_change (dpyinfo, &er, &inev);
|
||||
|
||||
SetPortWindowPort (window_ptr);
|
||||
GlobalToLocal (&mouse_loc);
|
||||
|
|
@ -8910,13 +8968,9 @@ XTread_socket (sd, expected, hold_quit)
|
|||
/* A window has been deactivated */
|
||||
dpyinfo->grabbed = 0;
|
||||
|
||||
if (f == dpyinfo->x_focus_frame)
|
||||
{
|
||||
x_new_focus_frame (dpyinfo, 0);
|
||||
DeactivateControl (root_control);
|
||||
}
|
||||
|
||||
x_detect_focus_change (dpyinfo, &er, &inev);
|
||||
|
||||
f = mac_window_to_frame (window_ptr);
|
||||
if (f == dpyinfo->mouse_face_mouse_frame)
|
||||
{
|
||||
/* If we move outside the frame, then we're
|
||||
|
|
@ -8957,13 +9011,31 @@ XTread_socket (sd, expected, hold_quit)
|
|||
break;
|
||||
#endif
|
||||
|
||||
#if TARGET_API_MAC_CARBON
|
||||
if (!IsValidWindowPtr (front_emacs_window ()))
|
||||
if (dpyinfo->x_focus_frame == NULL)
|
||||
{
|
||||
/* Beep if keyboard input occurs when all the frames
|
||||
are invisible. */
|
||||
SysBeep (1);
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
|
||||
{
|
||||
static SInt16 last_key_script = -1;
|
||||
SInt16 current_key_script = GetScriptManagerVariable (smKeyScript);
|
||||
|
||||
if (last_key_script != current_key_script)
|
||||
{
|
||||
struct input_event event;
|
||||
|
||||
EVENT_INIT (event);
|
||||
event.kind = LANGUAGE_CHANGE_EVENT;
|
||||
event.arg = Qnil;
|
||||
event.code = current_key_script;
|
||||
kbd_buffer_store_event (&event);
|
||||
count++;
|
||||
}
|
||||
last_key_script = current_key_script;
|
||||
}
|
||||
|
||||
ObscureCursor ();
|
||||
|
||||
|
|
@ -8998,95 +9070,32 @@ XTread_socket (sd, expected, hold_quit)
|
|||
unsigned long some_state = 0;
|
||||
inev.code = KeyTranslate (kchr_ptr, new_keycode,
|
||||
&some_state) & 0xff;
|
||||
} else if (!NILP(Vmac_option_modifier) && (er.modifiers & optionKey))
|
||||
{
|
||||
/* When using the option key as an emacs modifier, convert
|
||||
the pressed key code back to one without the Mac option
|
||||
modifier applied. */
|
||||
int new_modifiers = er.modifiers & ~optionKey;
|
||||
int new_keycode = keycode | new_modifiers;
|
||||
Ptr kchr_ptr = (Ptr) GetScriptManagerVariable (smKCHRCache);
|
||||
unsigned long some_state = 0;
|
||||
inev.code = KeyTranslate (kchr_ptr, new_keycode,
|
||||
&some_state) & 0xff;
|
||||
}
|
||||
}
|
||||
else if (!NILP (Vmac_option_modifier)
|
||||
&& (er.modifiers & optionKey))
|
||||
{
|
||||
/* When using the option key as an emacs modifier,
|
||||
convert the pressed key code back to one
|
||||
without the Mac option modifier applied. */
|
||||
int new_modifiers = er.modifiers & ~optionKey;
|
||||
int new_keycode = keycode | new_modifiers;
|
||||
Ptr kchr_ptr = (Ptr) GetScriptManagerVariable (smKCHRCache);
|
||||
unsigned long some_state = 0;
|
||||
inev.code = KeyTranslate (kchr_ptr, new_keycode,
|
||||
&some_state) & 0xff;
|
||||
}
|
||||
else
|
||||
inev.code = er.message & charCodeMask;
|
||||
inev.kind = ASCII_KEYSTROKE_EVENT;
|
||||
}
|
||||
}
|
||||
|
||||
/* If variable mac-convert-keyboard-input-to-latin-1 is
|
||||
non-nil, convert non-ASCII characters typed at the Mac
|
||||
keyboard (presumed to be in the Mac Roman encoding) to
|
||||
iso-latin-1 encoding before they are passed to Emacs.
|
||||
This enables the Mac keyboard to be used to enter
|
||||
non-ASCII iso-latin-1 characters directly. */
|
||||
if (mac_keyboard_text_encoding != kTextEncodingMacRoman
|
||||
&& inev.kind == ASCII_KEYSTROKE_EVENT && inev.code >= 128)
|
||||
{
|
||||
static TECObjectRef converter = NULL;
|
||||
OSStatus the_err = noErr;
|
||||
OSStatus convert_status = noErr;
|
||||
|
||||
if (converter == NULL)
|
||||
{
|
||||
the_err = TECCreateConverter (&converter,
|
||||
kTextEncodingMacRoman,
|
||||
mac_keyboard_text_encoding);
|
||||
current_mac_keyboard_text_encoding
|
||||
= mac_keyboard_text_encoding;
|
||||
}
|
||||
else if (mac_keyboard_text_encoding
|
||||
!= current_mac_keyboard_text_encoding)
|
||||
{
|
||||
/* Free the converter for the current encoding
|
||||
before creating a new one. */
|
||||
TECDisposeConverter (converter);
|
||||
the_err = TECCreateConverter (&converter,
|
||||
kTextEncodingMacRoman,
|
||||
mac_keyboard_text_encoding);
|
||||
current_mac_keyboard_text_encoding
|
||||
= mac_keyboard_text_encoding;
|
||||
}
|
||||
|
||||
if (the_err == noErr)
|
||||
{
|
||||
unsigned char ch = inev.code;
|
||||
ByteCount actual_input_length, actual_output_length;
|
||||
unsigned char outbuf[32];
|
||||
|
||||
convert_status = TECConvertText (converter, &ch, 1,
|
||||
&actual_input_length,
|
||||
outbuf, 1,
|
||||
&actual_output_length);
|
||||
if (convert_status == noErr
|
||||
&& actual_input_length == 1
|
||||
&& actual_output_length == 1)
|
||||
inev.code = *outbuf;
|
||||
|
||||
/* Reset internal states of the converter object.
|
||||
If it fails, create another one. */
|
||||
convert_status = TECFlushText (converter, outbuf,
|
||||
sizeof (outbuf),
|
||||
&actual_output_length);
|
||||
if (convert_status != noErr)
|
||||
{
|
||||
TECDisposeConverter (converter);
|
||||
TECCreateConverter (&converter,
|
||||
kTextEncodingMacRoman,
|
||||
mac_keyboard_text_encoding);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#if USE_CARBON_EVENTS
|
||||
inev.modifiers = mac_event_to_emacs_modifiers (eventRef);
|
||||
#else
|
||||
inev.modifiers = mac_to_emacs_modifiers (er.modifiers);
|
||||
#endif
|
||||
XSETFRAME (inev.frame_or_window,
|
||||
mac_window_to_frame (front_emacs_window ()));
|
||||
XSETFRAME (inev.frame_or_window, mac_focus_frame (dpyinfo));
|
||||
inev.timestamp = er.when * (1000 / 60); /* ticks to milliseconds */
|
||||
break;
|
||||
|
||||
|
|
@ -9099,22 +9108,10 @@ XTread_socket (sd, expected, hold_quit)
|
|||
constuct_drag_n_drop in w32term.c. */
|
||||
if (!NILP (drag_and_drop_file_list))
|
||||
{
|
||||
struct frame *f = NULL;
|
||||
struct frame *f = mac_focus_frame (dpyinfo);
|
||||
WindowPtr wp;
|
||||
Lisp_Object frame;
|
||||
|
||||
wp = front_emacs_window ();
|
||||
|
||||
if (!wp)
|
||||
{
|
||||
struct frame *f = XFRAME (XCAR (Vframe_list));
|
||||
CollapseWindow (FRAME_MAC_WINDOW (f), false);
|
||||
wp = front_emacs_window ();
|
||||
}
|
||||
|
||||
if (wp)
|
||||
f = mac_window_to_frame (wp);
|
||||
|
||||
inev.kind = DRAG_N_DROP_EVENT;
|
||||
inev.code = 0;
|
||||
inev.timestamp = er.when * (1000 / 60);
|
||||
|
|
@ -9131,10 +9128,12 @@ XTread_socket (sd, expected, hold_quit)
|
|||
XSETFRAME (frame, f);
|
||||
inev.frame_or_window = Fcons (frame, drag_and_drop_file_list);
|
||||
|
||||
#if 0
|
||||
/* Regardless of whether Emacs was suspended or in the
|
||||
foreground, ask it to redraw its entire screen.
|
||||
Otherwise parts of the screen can be left in an
|
||||
inconsistent state. */
|
||||
wp = FRAME_MAC_WINDOW (f);
|
||||
if (wp)
|
||||
#if TARGET_API_MAC_CARBON
|
||||
{
|
||||
|
|
@ -9146,6 +9145,7 @@ XTread_socket (sd, expected, hold_quit)
|
|||
#else /* not TARGET_API_MAC_CARBON */
|
||||
InvalRect (&(wp->portRect));
|
||||
#endif /* not TARGET_API_MAC_CARBON */
|
||||
#endif
|
||||
}
|
||||
default:
|
||||
break;
|
||||
|
|
@ -9625,7 +9625,7 @@ mac_check_for_quit_char ()
|
|||
e.arg = Qnil;
|
||||
e.modifiers = NULL;
|
||||
e.timestamp = EventTimeToTicks (GetEventTime (event)) * (1000/60);
|
||||
XSETFRAME (e.frame_or_window, mac_window_to_frame (front_emacs_window ()));
|
||||
XSETFRAME (e.frame_or_window, mac_focus_frame (&one_mac_display_info));
|
||||
/* Remove event from queue to prevent looping. */
|
||||
RemoveEventFromQueue (GetMainEventQueue (), event);
|
||||
ReleaseEvent (event);
|
||||
|
|
@ -9819,10 +9819,6 @@ syms_of_macterm ()
|
|||
Qeuc_kr = intern ("euc-kr");
|
||||
staticpro (&Qeuc_kr);
|
||||
|
||||
DEFVAR_BOOL ("x-autoselect-window", &x_autoselect_window_p,
|
||||
doc: /* *Non-nil means autoselect window with mouse pointer. */);
|
||||
x_autoselect_window_p = 0;
|
||||
|
||||
DEFVAR_LISP ("x-toolkit-scroll-bars", &Vx_toolkit_scroll_bars,
|
||||
doc: /* If not nil, Emacs uses toolkit scroll bars. */);
|
||||
Vx_toolkit_scroll_bars = Qt;
|
||||
|
|
@ -9882,10 +9878,6 @@ Toolbox for processing before Emacs sees it. */);
|
|||
Toolbox for processing before Emacs sees it. */);
|
||||
Vmac_pass_control_to_system = Qt;
|
||||
|
||||
DEFVAR_LISP ("mac-pass-control-to-system", &Vmac_pass_control_to_system,
|
||||
doc: /* If non-nil, the Mac \"Control\" key is passed on to the Mac
|
||||
Toolbox for processing before Emacs sees it. */);
|
||||
Vmac_pass_control_to_system = Qt;
|
||||
#endif
|
||||
|
||||
DEFVAR_LISP ("mac-allow-anti-aliasing", &Vmac_use_core_graphics,
|
||||
|
|
@ -9893,21 +9885,6 @@ Toolbox for processing before Emacs sees it. */);
|
|||
The text will be rendered using Core Graphics text rendering which
|
||||
may anti-alias the text. */);
|
||||
Vmac_use_core_graphics = Qnil;
|
||||
|
||||
DEFVAR_INT ("mac-keyboard-text-encoding", &mac_keyboard_text_encoding,
|
||||
doc: /* One of the Text Encoding Base constant values defined in the
|
||||
Basic Text Constants section of Inside Macintosh - Text Encoding
|
||||
Conversion Manager. Its value determines the encoding characters
|
||||
typed at the Mac keyboard (presumed to be in the MacRoman encoding)
|
||||
will convert into. E.g., if it is set to kTextEncodingMacRoman (0),
|
||||
its default value, no conversion takes place. If it is set to
|
||||
kTextEncodingISOLatin1 (0x201) or kTextEncodingISOLatin2 (0x202),
|
||||
characters typed on Mac keyboard are first converted into the
|
||||
ISO Latin-1 or ISO Latin-2 encoding, respectively before being
|
||||
passed to Emacs. Together with Emacs's set-keyboard-coding-system
|
||||
command, this enables the Mac keyboard to be used to enter non-ASCII
|
||||
characters directly. */);
|
||||
mac_keyboard_text_encoding = kTextEncodingMacRoman;
|
||||
}
|
||||
|
||||
/* arch-tag: f2259165-4454-4c04-a029-a133c8af7b5b
|
||||
|
|
|
|||
|
|
@ -195,14 +195,14 @@ struct mac_display_info
|
|||
int bitmaps_last;
|
||||
|
||||
/* The frame (if any) which has the window that has keyboard focus.
|
||||
Zero if none. This is examined by Ffocus_frame in w32fns.c. Note
|
||||
Zero if none. This is examined by Ffocus_frame in macfns.c. Note
|
||||
that a mere EnterNotify event can set this; if you need to know the
|
||||
last frame specified in a FocusIn or FocusOut event, use
|
||||
w32_focus_event_frame. */
|
||||
x_focus_event_frame. */
|
||||
struct frame *x_focus_frame;
|
||||
|
||||
/* The last frame mentioned in a FocusIn or FocusOut event. This is
|
||||
separate from w32_focus_frame, because whether or not LeaveNotify
|
||||
separate from x_focus_frame, because whether or not LeaveNotify
|
||||
events cause us to lose focus depends on whether or not we have
|
||||
received a FocusIn event for it. */
|
||||
struct frame *x_focus_event_frame;
|
||||
|
|
@ -210,7 +210,7 @@ struct mac_display_info
|
|||
/* The frame which currently has the visual highlight, and should get
|
||||
keyboard input (other sorts of input have the frame encoded in the
|
||||
event). It points to the focus frame's selected window's
|
||||
frame. It differs from w32_focus_frame when we're using a global
|
||||
frame. It differs from x_focus_frame when we're using a global
|
||||
minibuffer. */
|
||||
struct frame *x_highlight_frame;
|
||||
|
||||
|
|
@ -418,7 +418,7 @@ typedef struct mac_output mac_output;
|
|||
|
||||
#define FRAME_SIZE_HINTS(f) ((f)->output_data.mac->size_hints)
|
||||
|
||||
/* This gives the w32_display_info structure for the display F is on. */
|
||||
/* This gives the mac_display_info structure for the display F is on. */
|
||||
#define FRAME_MAC_DISPLAY_INFO(f) (&one_mac_display_info)
|
||||
#define FRAME_X_DISPLAY_INFO(f) (&one_mac_display_info)
|
||||
|
||||
|
|
@ -624,6 +624,7 @@ extern OSErr fsspec_to_posix_pathname P_ ((const FSSpec *, char *, int));
|
|||
extern void mac_clear_font_name_table P_ ((void));
|
||||
#if TARGET_API_MAC_CARBON
|
||||
extern CFStringRef cfstring_create_with_utf8_cstring P_ ((const char *));
|
||||
extern CFStringRef cfstring_create_with_string P_ ((Lisp_Object));
|
||||
extern Lisp_Object cfdata_to_lisp P_ ((CFDataRef));
|
||||
extern Lisp_Object cfstring_to_lisp P_ ((CFStringRef));
|
||||
extern Lisp_Object cfnumber_to_lisp P_ ((CFNumberRef));
|
||||
|
|
|
|||
21
src/term.c
21
src/term.c
|
|
@ -1289,7 +1289,26 @@ static struct fkey_table keys[] =
|
|||
{"k6", "f6"},
|
||||
{"k7", "f7"},
|
||||
{"k8", "f8"},
|
||||
{"k9", "f9"}
|
||||
{"k9", "f9"},
|
||||
|
||||
{"&0", "S-cancel"}, /*shifted cancel key*/
|
||||
{"&9", "S-begin"}, /*shifted begin key*/
|
||||
{"*0", "S-find"}, /*shifted find key*/
|
||||
{"*1", "S-execute"}, /*shifted execute? actually shifted command key*/
|
||||
{"*4", "S-delete"}, /*shifted delete-character key*/
|
||||
{"*7", "S-end"}, /*shifted end key*/
|
||||
{"*8", "S-clearline"}, /*shifted clear-to end-of-line key*/
|
||||
{"#1", "S-help"}, /*shifted help key*/
|
||||
{"#2", "S-home"}, /*shifted home key*/
|
||||
{"#3", "S-insert"}, /*shifted insert-character key*/
|
||||
{"#4", "S-left"}, /*shifted left-arrow key*/
|
||||
{"%d", "S-menu"}, /*shifted menu? actually shifted options key*/
|
||||
{"%c", "S-next"}, /*shifted next key*/
|
||||
{"%e", "S-prior"}, /*shifted previous key*/
|
||||
{"%f", "S-print"}, /*shifted print key*/
|
||||
{"%g", "S-redo"}, /*shifted redo key*/
|
||||
{"%i", "S-right"}, /*shifted right-arrow key*/
|
||||
{"!3", "S-undo"} /*shifted undo key*/
|
||||
};
|
||||
|
||||
static char **term_get_fkeys_arg;
|
||||
|
|
|
|||
|
|
@ -103,10 +103,11 @@ enum event_kind
|
|||
the wheel event occurred in.
|
||||
.timestamp gives a timestamp (in
|
||||
milliseconds) for the event. */
|
||||
#ifdef WINDOWSNT
|
||||
LANGUAGE_CHANGE_EVENT, /* A LANGUAGE_CHANGE_EVENT is generated
|
||||
on WINDOWSNT when the keyboard layout
|
||||
or input language is changed by the
|
||||
#if defined (WINDOWSNT) || defined (MAC_OS)
|
||||
LANGUAGE_CHANGE_EVENT, /* A LANGUAGE_CHANGE_EVENT is
|
||||
generated on WINDOWSNT or Mac OS
|
||||
when the keyboard layout or input
|
||||
language is changed by the
|
||||
user. */
|
||||
#endif
|
||||
SCROLL_BAR_CLICK_EVENT, /* .code gives the number of the mouse button
|
||||
|
|
|
|||
19
src/window.c
19
src/window.c
|
|
@ -1,7 +1,7 @@
|
|||
/* Window creation, deletion and examination for GNU Emacs.
|
||||
Does not include redisplay.
|
||||
Copyright (C) 1985,86,87, 1993,94,95,96,97,98, 2000,01,02,03,04
|
||||
Free Software Foundation, Inc.
|
||||
Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997, 1998, 2000,
|
||||
2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GNU Emacs.
|
||||
|
||||
|
|
@ -5596,7 +5596,20 @@ the return value is nil. Otherwise the value is t. */)
|
|||
if (XBUFFER (new_current_buffer) == current_buffer)
|
||||
old_point = PT;
|
||||
else
|
||||
old_point = BUF_PT (XBUFFER (new_current_buffer));
|
||||
/* BUF_PT (XBUFFER (new_current_buffer)) gives us the position of
|
||||
point in new_current_buffer as of the last time this buffer was
|
||||
used. This can be non-deterministic since it can be changed by
|
||||
things like jit-lock by mere temporary selection of some random
|
||||
window that happens to show this buffer.
|
||||
So if possible we want this arbitrary choice of "which point" to
|
||||
be the one from the to-be-selected-window so as to prevent this
|
||||
window's cursor from being copied from another window. */
|
||||
if (EQ (XWINDOW (data->current_window)->buffer, new_current_buffer)
|
||||
/* If current_window = selected_window, its point is in BUF_PT. */
|
||||
&& !EQ (selected_window, data->current_window))
|
||||
old_point = XMARKER (XWINDOW (data->current_window)->pointm)->charpos;
|
||||
else
|
||||
old_point = BUF_PT (XBUFFER (new_current_buffer));
|
||||
}
|
||||
|
||||
frame = XWINDOW (SAVED_WINDOW_N (saved_windows, 0)->window)->frame;
|
||||
|
|
|
|||
37
src/xdisp.c
37
src/xdisp.c
|
|
@ -567,12 +567,21 @@ Lisp_Object Vmessage_log_max;
|
|||
|
||||
static Lisp_Object Vmessages_buffer_name;
|
||||
|
||||
/* Current, index 0, and last displayed echo area message. Either
|
||||
buffers from echo_buffers, or nil to indicate no message. */
|
||||
/* Index 0 is the buffer that holds the current (desired) echo area message,
|
||||
or nil if none is desired right now.
|
||||
|
||||
Index 1 is the buffer that holds the previously displayed echo area message,
|
||||
or nil to indicate no message. This is normally what's on the screen now.
|
||||
|
||||
These two can point to the same buffer. That happens when the last
|
||||
message output by the user (or made by echoing) has been displayed. */
|
||||
|
||||
Lisp_Object echo_area_buffer[2];
|
||||
|
||||
/* The buffers referenced from echo_area_buffer. */
|
||||
/* Permanent pointers to the two buffers that are used for echo area
|
||||
purposes. Once the two buffers are made, and their pointers are
|
||||
placed here, these two slots remain unchanged unless those buffers
|
||||
need to be created afresh. */
|
||||
|
||||
static Lisp_Object echo_buffer[2];
|
||||
|
||||
|
|
@ -7213,10 +7222,6 @@ ensure_echo_area_buffers ()
|
|||
WHICH > 0 means use echo_area_buffer[1]. If that is nil, choose a
|
||||
suitable buffer from echo_buffer[] and clear it.
|
||||
|
||||
If WHICH < 0, set echo_area_buffer[1] to echo_area_buffer[0], so
|
||||
that the current message becomes the last displayed one, make
|
||||
choose a suitable buffer for echo_area_buffer[0], and clear it.
|
||||
|
||||
Value is what FN returns. */
|
||||
|
||||
static int
|
||||
|
|
@ -7241,17 +7246,6 @@ with_echo_area_buffer (w, which, fn, a1, a2, a3, a4)
|
|||
this_one = 0, the_other = 1;
|
||||
else if (which > 0)
|
||||
this_one = 1, the_other = 0;
|
||||
else
|
||||
{
|
||||
this_one = 0, the_other = 1;
|
||||
clear_buffer_p = 1;
|
||||
|
||||
/* We need a fresh one in case the current echo buffer equals
|
||||
the one containing the last displayed echo area message. */
|
||||
if (!NILP (echo_area_buffer[this_one])
|
||||
&& EQ (echo_area_buffer[this_one], echo_area_buffer[the_other]))
|
||||
echo_area_buffer[this_one] = Qnil;
|
||||
}
|
||||
|
||||
/* Choose a suitable buffer from echo_buffer[] is we don't
|
||||
have one. */
|
||||
|
|
@ -7871,7 +7865,7 @@ set_message (s, string, nbytes, multibyte_p)
|
|||
= ((s && multibyte_p)
|
||||
|| (STRINGP (string) && STRING_MULTIBYTE (string)));
|
||||
|
||||
with_echo_area_buffer (0, -1, set_message_1,
|
||||
with_echo_area_buffer (0, 0, set_message_1,
|
||||
(EMACS_INT) s, string, nbytes, multibyte_p);
|
||||
message_buf_print = 0;
|
||||
help_echo_showing_p = 0;
|
||||
|
|
@ -7903,6 +7897,7 @@ set_message_1 (a1, a2, nbytes, multibyte_p)
|
|||
|
||||
/* Insert new message at BEG. */
|
||||
TEMP_SET_PT_BOTH (BEG, BEG_BYTE);
|
||||
Ferase_buffer ();
|
||||
|
||||
if (STRINGP (string))
|
||||
{
|
||||
|
|
@ -8118,10 +8113,8 @@ echo_area_display (update_frame_p)
|
|||
else if (!EQ (mini_window, selected_window))
|
||||
windows_or_buffers_changed++;
|
||||
|
||||
/* Last displayed message is now the current message. */
|
||||
/* The current message is now also the last one displayed. */
|
||||
echo_area_buffer[1] = echo_area_buffer[0];
|
||||
/* Inform read_char that we're not echoing. */
|
||||
echo_message_buffer = Qnil;
|
||||
|
||||
/* Prevent redisplay optimization in redisplay_internal by resetting
|
||||
this_line_start_pos. This is done because the mini-buffer now
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue