unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: martin rudalics <rudalics@gmx.at>
To: Pierre Lorenzon <pollock.nageoire@wanadoo.fr>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Using widgets and timers simultaneously
Date: Wed, 02 May 2007 10:36:39 +0200	[thread overview]
Message-ID: <46384D97.2090207@gmx.at> (raw)
In-Reply-To: <20070501.153029.74739975.pollock.nageoire@wanadoo.fr>

 >>I recall that widgets may get screwed up when text is replaced at text
 >>boundaries.  In principle you should make sure yourself that mutable
 >>text is surrounded by immutable one.
 >
 >
 >   I suppose the point is here but I don't really understand !
 >   Can you give me more details ?
 >
 >   Indeed I implemented the refresh method slightly differently
 >   :
 >
 >   (defun refresh ()
 >   (widget-value-set my-widget (current-time-string)))
 >
 >   It avoids the setq my-widget mentioned above and which was
 >   not really good as you observed. But since the
 >   widget-defaul-value-set still require the
 >   widget-default-create method the problem with the
 >   delete-backward-char which is not executed is still there !

You would have to give me a precise recipe to reproduce the failure.
Note that debugging widgets is a real pain, that's why I usually try to
avoid it.  You could try to edebug `widget-default-value-set' (according
to Richard there's a bug) and see for yourself.  Be sure to cancel the
timer before and invoke `refresh' manually.  It might be worth to edebug
the `widget-field-...' functions as well.

Does the character of the problem change when you set
`widget-field-add-space' to a non-nil value?  Does setting
`widget-field-use-before-change' to nil affect the problem?

  reply	other threads:[~2007-05-02  8:36 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-01 12:14 Using widgets and timers simultaneously martin rudalics
2007-05-01 13:30 ` Pierre Lorenzon
2007-05-02  8:36   ` martin rudalics [this message]
2007-05-08 13:11     ` Pierre Lorenzon
     [not found] <mailman.12.1177964905.32220.help-gnu-emacs@gnu.org>
2007-05-01 16:26 ` Johan Bockgård
  -- strict thread matches above, loose matches on Subject: below --
2007-04-30 20:21 Pierre Lorenzon

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46384D97.2090207@gmx.at \
    --to=rudalics@gmx.at \
    --cc=help-gnu-emacs@gnu.org \
    --cc=pollock.nageoire@wanadoo.fr \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).