all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* 23.0.60; format-time-string, post-command-hook and mark
@ 2008-02-12  0:02 Stephen Berman
  2008-02-14 10:30 ` Johan Bockgård
  0 siblings, 1 reply; 4+ messages in thread
From: Stephen Berman @ 2008-02-12  0:02 UTC (permalink / raw)
  To: emacs-devel

1. Start Emacs with these arguments:
      -Q --eval "(add-hook 'post-command-hook (lambda () (format-time-string \"%Y\")))"

2. Load a file into a buffer or type some text in a buffer.

3. If you select a region of the buffer with the mouse and try to delete
the region with C-w, Emacs beeps and says "The mark is not active now"
and the region is not deleted.

4. Type C-SPC and see the message "Mark activated"; type C-SPC again and
see the message "Transient-mark-mode temporarily enabled".  However,
moving point does not show a highlighted expanding or contracting
region.

5. If you load an elisp file and select an uncommented region with the
mouse or by temporarily enabling transient-mark-mode, then typing M-;
does not comment out the region, but puts a comment string at the end of
the region.

Repeat the above with Emacs 23.0.50: doing C-w at step 3 deletes the
region, moving point in step 4 shows the highlighted region, typing M-;
in step 5 comments out the region.

I can reproduce the above observations for 23.0.60 with any nonempty
format string as argument to format-time-string, e.g. with "test" but
not with "" (with the latter 23.0.60 behaves like 23.0,50 with nonempty
format strings).  I cannot reproduce the observations for 23.0.60 if
format-time-string is not added to post-command-hook.

In GNU Emacs 23.0.60.2 (i686-pc-linux-gnu, GTK+ Version 2.12.0) of
2008-02-11 on escher

Steve Berman





^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: 23.0.60; format-time-string, post-command-hook and mark
  2008-02-12  0:02 23.0.60; format-time-string, post-command-hook and mark Stephen Berman
@ 2008-02-14 10:30 ` Johan Bockgård
  2008-02-14 12:24   ` Kenichi Handa
  0 siblings, 1 reply; 4+ messages in thread
From: Johan Bockgård @ 2008-02-14 10:30 UTC (permalink / raw)
  To: emacs-devel

Stephen Berman <Stephen.Berman@gmx.net> writes:

> 1. Start Emacs with these arguments:
>       -Q --eval "(add-hook 'post-command-hook (lambda () (format-time-string \"%Y\")))"
>
> 2. Load a file into a buffer or type some text in a buffer.
>
> 3. If you select a region of the buffer with the mouse and try to delete
> the region with C-w, Emacs beeps and says "The mark is not active now"
> and the region is not deleted.

There used to be code in coding.c to save and restore Vdeactivate_mark.
In 23.0.60 it doesn't refer to Vdeactivate_mark at all.  Handa-san?


#0  prepare_to_modify_buffer (start=1, end=88, preserve_ptr=0x7fffcc9a8fec)
    at insdel.c:2077
#1  0x00000000005064f0 in del_range_1 (from=1, to=87,
    prepare=<value optimized out>, ret_string=0) at insdel.c:1846
#2  0x00000000004fdf65 in Ferase_buffer () at buffer.c:2142
#3  0x000000000047908b in code_conversion_save (
    with_work_buf=<value optimized out>, multibyte=1) at coding.c:6696
#4  0x0000000000479c75 in decode_coding_object (coding=0x7fffcc9a90f0,
    src_object=11662467, from=0, from_byte=0, to=<value optimized out>,
    to_byte=<value optimized out>, dst_object=10795505) at coding.c:6913
#5  0x000000000047a1ae in code_convert_string (string=11662467,
    coding_system=20861169, dst_object=10795505, encodep=0,
    nocopy=<value optimized out>, norecord=1) at coding.c:8152
#6  0x0000000000544a9d in Fformat_time_string (
    format_string=<value optimized out>, time=<value optimized out>,
    universal=<value optimized out>) at editfns.c:1716

-- 
Johan Bockgård





^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: 23.0.60; format-time-string, post-command-hook and mark
  2008-02-14 10:30 ` Johan Bockgård
@ 2008-02-14 12:24   ` Kenichi Handa
  2008-02-14 13:38     ` Stephen Berman
  0 siblings, 1 reply; 4+ messages in thread
From: Kenichi Handa @ 2008-02-14 12:24 UTC (permalink / raw)
  To: Johan Bockgård; +Cc: emacs-devel

In article <yoijfxvvbzjw.fsf@remote2.student.chalmers.se>, bojohan+news@dd.chalmers.se (Johan Bockgård) writes:

> Stephen Berman <Stephen.Berman@gmx.net> writes:
> > 1. Start Emacs with these arguments:
> >       -Q --eval "(add-hook 'post-command-hook (lambda () (format-time-string \"%Y\")))"
> >
> > 2. Load a file into a buffer or type some text in a buffer.
> >
> > 3. If you select a region of the buffer with the mouse and try to delete
> > the region with C-w, Emacs beeps and says "The mark is not active now"
> > and the region is not deleted.

> There used to be code in coding.c to save and restore Vdeactivate_mark.
> In 23.0.60 it doesn't refer to Vdeactivate_mark at all.  Handa-san?

It seems that the change of handling Vdeactivate_mark in
codinc.c was lost while synchronizing emacs-unicode-2 with
the trunk.

I've just installed a fix.

---
Kenichi Handa
handa@ni.aist.go.jp




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: 23.0.60; format-time-string, post-command-hook and mark
  2008-02-14 12:24   ` Kenichi Handa
@ 2008-02-14 13:38     ` Stephen Berman
  0 siblings, 0 replies; 4+ messages in thread
From: Stephen Berman @ 2008-02-14 13:38 UTC (permalink / raw)
  To: emacs-devel

On Thu, 14 Feb 2008 21:24:32 +0900 Kenichi Handa <handa@m17n.org> wrote:

> In article <yoijfxvvbzjw.fsf@remote2.student.chalmers.se>, bojohan+news@dd.chalmers.se (Johan Bockgård) writes:
>
>> Stephen Berman <Stephen.Berman@gmx.net> writes:
>> > 1. Start Emacs with these arguments:
>> >       -Q --eval "(add-hook 'post-command-hook (lambda () (format-time-string \"%Y\")))"
>> >
>> > 2. Load a file into a buffer or type some text in a buffer.
>> >
>> > 3. If you select a region of the buffer with the mouse and try to delete
>> > the region with C-w, Emacs beeps and says "The mark is not active now"
>> > and the region is not deleted.
>
>> There used to be code in coding.c to save and restore Vdeactivate_mark.
>> In 23.0.60 it doesn't refer to Vdeactivate_mark at all.  Handa-san?
>
> It seems that the change of handling Vdeactivate_mark in
> codinc.c was lost while synchronizing emacs-unicode-2 with
> the trunk.
>
> I've just installed a fix.

I confirm the problem I reported is fixed; thanks to Johan Bockgård for
finding the source of the problem and to Kenichi Handa for fixing it.

Steve Berman





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-02-14 13:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-12  0:02 23.0.60; format-time-string, post-command-hook and mark Stephen Berman
2008-02-14 10:30 ` Johan Bockgård
2008-02-14 12:24   ` Kenichi Handa
2008-02-14 13:38     ` Stephen Berman

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.