Questions tagged [idle-timer]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
2 answers
285 views

run c-c c-k after edit text automatically

I would like to config emacs to run c-c c-k command after edit text happen and delay 3 secs. if edit happen within 3 secs, then no need to run the command. if edit happened then after 3 secs not edit ...
lucky1928's user avatar
  • 1,644
0 votes
2 answers
214 views

Is post-command-hook or idle timer better for doing something when the user becomes idle?

Let's say I want to write a mode which updates the display (e.g. adds some annotation) when the user edits the buffer or just moves around. What is the recommended way to implement this? Using post-...
Tom's user avatar
  • 1,190
0 votes
1 answer
102 views

Is there a general way to delay computing & displaying mode-line text?

Some things I'd like to show in the mode-line are quite expensive to compute, so I'd rather use an idle timer. Is there a general way to do this? or does this need to be added individually? (using a ...
ideasman42's user avatar
  • 8,556
1 vote
0 answers
120 views

Semantic Idle Service Error semantic-idle-summary-idle-function

Context Hey, I've discovered semantic and how useful it is when writing coding, it provides some handy features. I'm mostly using it for C/C++ programming, although there's a bug that kept on showing, ...
0x0584's user avatar
  • 121
1 vote
1 answer
241 views

How to temporarily disable/reset idle timers?

I have a package which uses mouse motion, currently the idle timers aren't reset on mouse motion - causing idle timers to run, even when from a user perspective - Emacs is not idle. How can I stop ...
ideasman42's user avatar
  • 8,556
1 vote
0 answers
58 views

Get time since last keystroke

I would like to know how many seconds have passed since the last keystroke (or character that showed up in the screen, whatever is easier). Is there a timer that is associated to self-insert-command? ...
scaramouche's user avatar
  • 1,732
1 vote
1 answer
93 views

How to block output of a command run with via `run-with-idle-timer`?

I use (run-with-idle-timer 45 t 'org-save-all-org-buffers) to automatically save all org-mode buffers when I am idling for 45 seconds. What I don't like about this is that it prints "All org-mode ...
CrabMan's user avatar
  • 275
0 votes
2 answers
270 views

Tracking time spent typing in a buffer

Say if I’ve a buffer, is there a package or hack to track time that’s spent typing/editing on this buffer (ignoring idle time)?
user69055's user avatar
1 vote
1 answer
1k views

Count down timer and org

count down timer This code starts a count down timer every time org file is opened , but asks for a permission to reset timer every time . Can it be automated, meaning it should start counting as soon ...
Vaibhav's user avatar
  • 573
0 votes
2 answers
139 views

Setting and clearing an "is-idle" variable when going in and out of idle mode?

I understand in general about idle timers in emacs, but I'm having trouble figuring out how to do the following ... I want to set an is-idle variable to t when emacs is in an idle state, and I want ...
HippoMan's user avatar
  • 594
0 votes
1 answer
38 views

pabbrev-mode idle timer error

I have installed again pabbrev and whenever I activate the mode I constantly get theses 2 errors. Error running timer ‘pabbrev-idle-timer-function’: (invalid-function pabbrev-debug-message) Error ...
DJJ's user avatar
  • 762
3 votes
1 answer
377 views

force-window-update vs redisplay

During idle time with run-with-idle-timer I parse text around a point and update header-line-format. Unfortunately I can't see update to header line unless I type any key. So I should trigger ...
gavenkoa's user avatar
  • 3,362
7 votes
2 answers
683 views

Looking for something like a `first-keypress-in-a-while-hook`

Suppose that I have an Emacs session running, and that I step away from my computer for, say, 20 minutes. Upon returning to my Emacs session, at some point I will press some key while the Emacs ...
kjo's user avatar
  • 3,207
1 vote
0 answers
58 views

mode-specific idle timer?

I have my idle timer which saves the current buffer automatically just once when idle for three seconds. It's handy but when I stop typing while in helm, it opens up a prompt that asks me where to ...
stacko's user avatar
  • 1,587
3 votes
1 answer
481 views

Effect of multiple idle timers

Suppose I set two idle timers (run-with-idle-timer 3 nil #'function1) (run-with-idle-timer 3 nil #'function2) What is the effect? After roughly 3 seconds will emacs run function1 and then wait 3 ...
Andrew Swann's user avatar
  • 3,456
1 vote
1 answer
1k views

Rebuilding Org Agenda Buffer With Timer

I am trying to rebuild my Org Agenda buffer with a timer. I am trying to do it like this: (defun renewOrgBuffer () (interactive) (dolist (buffer (buffer-list)) (with-current-buffer buffer ...
Jesse's user avatar
  • 267
7 votes
3 answers
748 views

Buffer local idle-timer

I would like to use an idle timer that is local to the current buffer in one of my packages. However, I can't seem to find out how. How can I create (or fake) the behavior of a buffer local idle ...
PythonNut's user avatar
  • 10.3k
4 votes
1 answer
373 views

How can I test an idle timer with ERT?

Say I have a function that is called on an idle timer: (defun tmp:create () (mkdir "test")) (run-with-idle-time 3 nil #'tmp:create) How can I test that this function works? Using something like (...
Sean Allred's user avatar
  • 6,871
12 votes
3 answers
657 views

Make use of an empty echo area to display information

The echo area is empty most of the time, which makes me think that I could use it to display some information. For example, org-clock displays the current task, the remaining time and the total ...
T. Verron's user avatar
  • 4,263