[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[STUMP] window-send-string to certain apps
From: |
Dmitri Minaev |
Subject: |
[STUMP] window-send-string to certain apps |
Date: |
Tue, 24 Jul 2007 13:58:11 +0500 |
While enjoying the pleasures of working with a really scriptable
window manager, I've hit a problem. For an unknown reason (if any)
window-send-string does not insert text into some applications.
Namely, XTerm and Thunderbird composition window.
Here's what I do:
(define-stumpwm-command "insert-timestamp" ()
(window-send-string (current-window) (multiple-value-bind (s m h
date month year)
(get-decoded-time)
(format nil "~d-~2,'0d-~2,'0d
~2,'0d:~2,'0d:~d" year month date h m s))))
In Firefox the result is predictable: 2007-07-24 13:30:52. It also
works in OpenOffice, Konsole, gnome-terminal and most other
applications. I might think that there is something special in the way
XTerm and Thunderbird process X events, but the "insert" command
behaves as expected, as if there was a difference between the strings
typed by the user and the lisp strings.
--
With best regards,
Dmitri Minaev
Russian history blog: http://minaev.blogspot.com
- [STUMP] window-send-string to certain apps,
Dmitri Minaev <=