From: Luc Teirlinck <teirllm@dms.auburn.edu>
Subject: More about blink-cursor-mode
Date: Sat, 19 Feb 2005 19:55:43 -0600 (CST) [thread overview]
Message-ID: <200502200155.j1K1thb29289@raven.dms.auburn.edu> (raw)
The following patch contains two proposed changes to frame.el. I can
install either one or both changes.
The first change is, I believe, necessary. The docstring of
`blink-cursor-mode' has to tell that one should not try to set the
variable directly.
I do not know about the other change. If setting blink-cursor-mode
buffer locally would make any sense, the code in front of the
defcustom should use default-boundp and setq-default. But
`blink-cursor-mode' never should have a buffer local value. If we use
default-setq in front of the defcustom, then it would be consequent to
use it in the function `blink-cursor-mode' too, for consistency with
the code in startup.el. I do not know whether any of this really
matters anyway. It is a purely stylistic issue for this particular
variable. Maybe we could just keep the current code.
There still is the issue with the effect of the earlier `blink-cursor'
change on Custom, which I pointed out in a separate posting. That
problem is more general, however.
===File ~/frame.el-diff=====================================
*** frame.el 12 Feb 2005 11:14:04 -0600 1.216
--- frame.el 19 Feb 2005 19:33:14 -0600
***************
*** 1266,1278 ****
;; function. The correct evaluated standard value will be installed
;; in startup.el using exactly the same expression as in the defcustom.
(defvar blink-cursor-mode)
! (unless (boundp 'blink-cursor-mode) (setq blink-cursor-mode nil))
(defcustom blink-cursor-mode
(not (or noninteractive
emacs-quick-startup
(eq system-type 'ms-dos)
(not (memq window-system '(x w32)))))
! "*Non-nil means Blinking Cursor mode is active."
:group 'cursor
:tag "Blinking cursor"
:type 'boolean
--- 1266,1281 ----
;; function. The correct evaluated standard value will be installed
;; in startup.el using exactly the same expression as in the defcustom.
(defvar blink-cursor-mode)
! (unless (default-boundp 'blink-cursor-mode)
! (setq-default blink-cursor-mode nil))
(defcustom blink-cursor-mode
(not (or noninteractive
emacs-quick-startup
(eq system-type 'ms-dos)
(not (memq window-system '(x w32)))))
! "*Non-nil means Blinking Cursor mode is active.
! Do not set this variable directly. It would confuse Emacs.
! Either set it through Custom or use the command `blink-cursor-mode'."
:group 'cursor
:tag "Blinking cursor"
:type 'boolean
***************
*** 1302,1318 ****
(if blink-cursor-timer
(cancel-timer blink-cursor-timer))
(setq blink-cursor-idle-timer nil
! blink-cursor-timer nil
! blink-cursor-mode nil)
(if on-p
(progn
;; Hide the cursor.
! ;(internal-show-cursor nil nil)
(setq blink-cursor-idle-timer
(run-with-idle-timer blink-cursor-delay
blink-cursor-delay
'blink-cursor-start))
! (setq blink-cursor-mode t))
(internal-show-cursor nil t))))
(defun blink-cursor-start ()
--- 1305,1321 ----
(if blink-cursor-timer
(cancel-timer blink-cursor-timer))
(setq blink-cursor-idle-timer nil
! blink-cursor-timer nil)
! (setq-default blink-cursor-mode nil)
(if on-p
(progn
;; Hide the cursor.
! ;; (internal-show-cursor nil nil)
(setq blink-cursor-idle-timer
(run-with-idle-timer blink-cursor-delay
blink-cursor-delay
'blink-cursor-start))
! (setq-default blink-cursor-mode t))
(internal-show-cursor nil t))))
(defun blink-cursor-start ()
============================================================
next reply other threads:[~2005-02-20 1:55 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-20 1:55 Luc Teirlinck [this message]
2005-02-20 21:38 ` More about blink-cursor-mode Stefan
2005-02-21 3:27 ` Luc Teirlinck
2005-02-22 1:24 ` Luc Teirlinck
2005-02-22 13:52 ` Stefan Monnier
2005-02-23 2:53 ` Luc Teirlinck
2005-02-23 4:23 ` Stefan Monnier
2005-02-22 1:37 ` Luc Teirlinck
2005-02-22 13:54 ` Stefan Monnier
2005-02-22 8:42 ` Richard Stallman
2005-02-21 10:21 ` Richard Stallman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200502200155.j1K1thb29289@raven.dms.auburn.edu \
--to=teirllm@dms.auburn.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.