Location: lg@xxxxxxxxxxxxxx http://arch.xwem.org/2005/
Revision: xwem--main--2.2--patch-3
Archive: lg@xxxxxxxxxxxxxx
Creator: Zajcev Evgeny <lg@xxxxxxxx>
Date: Sat Apr 9 02:20:36 MSD 2005
Standard-date: 2005-04-08 22:20:36 GMT
Modified-files: extra/xwem-keytt.el extra/xwem-ratanot.el
extra/xwem-rooticon.el lisp/xwem-main.el
lisp/xwem-minibuffer.el lisp/xwem-misc.el
lisp/xwem-special.el
New-patches: dev@xxxxxxxxxxxxxxxx/xwem--dev--2.2--patch-3
lg@xxxxxxxxxxxxxx/xwem--main--2.2--patch-3
Summary: keytt major bug fix, and miscellaneous fixes/addons
Keywords: keytt, main, minibuffer
* extra/xwem-keytt.el (xwem-keytt-firefox-keymap): [typo fix] esc -> ESC
* extra/xwem-keytt.el (xwem-keytt-xpdf-keymap): Ditto.
* extra/xwem-ratanot.el: Continuing .. M-x xwem-ratanot RET already
available, but it will not work for you ;)
* extra/xwem-rooticon.el (xwem-rooticon-skip-spec): [new] MATCH-SPEC of
clients that should not have root icon. By default it has a value to
match xwem minibuffer.
* lisp/xwem-main.el (xwem-fini): [fix] Do all the things under
`ignore-errors' so xwem-fini won't generate any errors, even if it
fails to do something. Makes `C-x C-c' working if xwem was loaded, but
was not started.
* lisp/xwem-minibuffer.el (xwem-minib-apply-specifiers): [fix] Apply
specifiers under `ignore-errors', so for users who disabled toolbar or
scrollbar at (S)XEmacs compile time `xwem-minib-apply-specifiers' won't
fail.
* lisp/xwem-misc.el (xwem-messages-label-prefixes): [typo fix] Erorr ->
Error
* lisp/xwem-special.el (xwem-manage-emacs-special): [fix] Take into
account border width when calculating X position of special frame.
* added files
{arch}/xwem/xwem--dev/xwem--dev--2.2/dev@xxxxxxxxxxxxxxxx/patch-log/patch-3
{arch}/xwem/xwem--main/xwem--main--2.2/lg@xxxxxxxxxxxxxx/patch-log/patch-3
* modified files
--- orig/extra/xwem-keytt.el
+++ mod/extra/xwem-keytt.el
@@ -173,7 +173,7 @@
(define-key xwem-keytt-firefox-keymap (kbd "C-s") (kbd "<self-insert> /")) ;
search
(define-key xwem-keytt-firefox-keymap (kbd "M-C-s") (kbd "<self-insert>
<F3>")) ; next search
(define-key xwem-keytt-firefox-keymap (kbd "M-C-r") (kbd "<self-insert>
Sh-<F3>")) ; prev search
-(define-key xwem-keytt-firefox-keymap (kbd "C-g") (kbd "<self-insert> <esc>"))
; cancel search
+(define-key xwem-keytt-firefox-keymap (kbd "C-g") (kbd "<self-insert> <ESC>"))
; cancel search
(define-key xwem-keytt-firefox-keymap (kbd "C-x [") (kbd "<self-insert>
M-<left>")) ; back
(define-key xwem-keytt-firefox-keymap (kbd "C-x ]") (kbd "<self-insert>
M-<right>")) ; forward
;(define-key xwem-keytt-firefox-keymap (kbd "+") (kbd "<self-insert> C-+")) ;
zoom in
@@ -216,7 +216,7 @@
(define-key xwem-keytt-xpdf-keymap (kbd "C-x C-f") (kbd "<self-insert> o")) ;
open
(define-key xwem-keytt-xpdf-keymap (kbd "C-x C-c") (kbd "<self-insert> q")) ;
exit
(define-key xwem-keytt-xpdf-keymap (kbd "C-s") (kbd "<self-insert> f")) ; find
text
-(define-key xwem-keytt-xpdf-keymap (kbd "C-g") (kbd "<self-insert> <esc>")) ;
stop searching
+(define-key xwem-keytt-xpdf-keymap (kbd "C-g") (kbd "<self-insert> <ESC>")) ;
stop searching
(define-key xwem-keytt-xpdf-keymap (kbd "M-<") (kbd "<self-insert> <home>")) ;
goto first page
(define-key xwem-keytt-xpdf-keymap (kbd "M->") (kbd "<self-insert> <end>")) ;
goto last page
(define-key xwem-keytt-xpdf-keymap (kbd "C-n") (kbd "<self-insert> <down>")) ;
scroll down
--- orig/extra/xwem-ratanot.el
+++ mod/extra/xwem-ratanot.el
@@ -52,7 +52,7 @@
:group 'xwem-ratanot)
(defcustom xwem-ratanot-template
- '(date ":: " "[ " (name . 24) " ]" "\n\n"
+ '(date ":: " "[ " (name . 24) " ]" " (" application ") " "\n\n"
" * ")
"Template to insert on new RataNot entry."
:type 'list
@@ -67,6 +67,7 @@
(defvar xwem-ratanot-keymap
(let ((map (make-sparse-keymap)))
+ (define-key map (kbd "C-i <RET>") 'xwem-ratanot-insert-template)
(define-key map (kbd "C-i d") 'xwem-ratanot-insert-date)
(define-key map (kbd "C-i n") 'xwem-ratanot-insert-name)
(define-key map (kbd "C-i c") 'xwem-ratanot-insert-class)
@@ -114,11 +115,13 @@
(error 'xwem-error "Invalid RataNot field definition" field))
(insert (if (and (numberp limit)
(> (length rstr) limit))
- (substring rstr 0 limit)
+ (concat (substring rstr 0 (- limit 2)) "..")
rstr))))
-(defun xwem-ratanot-insert-template ()
+(defun xwem-ratanot-insert-template (limit)
"Insert the `xwem-ratanot-template'."
+ (interactive "P")
+
(mapc #'(lambda (ten)
(if (stringp ten)
(insert ten)
@@ -179,9 +182,27 @@
If prefix ARG is negative number - disable it.
Otherwise toggle."
(interactive "P")
- ;; TODO: write me
- )
-
+
+ (if (or (and (numberp arg)
+ (> arg 0))
+ (not xwem-ratanot-minor-mode))
+ (setq xwem-ratanot-minor-mode t)
+ (setq xwem-ratanot-minor-mode nil)))
+
+;;;###autoload(autoload 'xwem-ratanot "xwem-ratanot" nil t)
+(define-xwem-command xwem-ratanot ()
+ "Make a note."
+ (xwem-interactive)
+
+ (let ((xwem-special-default-strategy xwem-ratanot-special-display-strategy)
+ (buf (find-file-noselect (expand-file-name xwem-ratanot-file
xwem-dir))))
+ (set-symbol-value-in-buffer 'xwem-ratanot-minor-mode t buf)
+ (xwem-special-popup-frame buf)
+
+ (while (and (bufferp buf)
+ (symbol-value-in-buffer 'xwem-ratanot-minor-mode buf))
+ (dispatch-event (next-event)))))
+
(provide 'xwem-ratanot)
--- orig/extra/xwem-rooticon.el
+++ mod/extra/xwem-rooticon.el
@@ -73,6 +73,13 @@
:type 'sexp
:group 'xwem-rooticon)
+(defcustom xwem-rooticon-skip-spec
+ '((eval (eq (xwem-cl-manage-type cl) 'minibuffer)))
+ "*MATCH-SPEC for clients that does not have root icons.
+By default, xwem minibuffer does not have root icon."
+ :type 'sexp
+ :group 'xwem-rooticon)
+
;;; Internal variables
(defstruct xwem-rooticon
@@ -277,7 +284,8 @@
(let ((ri (xwem-cl-get-sys-prop cl 'xwem-rooticon)))
;; Create rooticon if not yet created
(when (and (eq new-state 'iconified)
- (not ri))
+ (not ri)
+ (not (xwem-cl-match-p cl xwem-rooticon-skip-spec)))
(setq ri (xwem-rooticon-create cl)))
(when ri
;; Set always on top rank (if any)
--- orig/lisp/xwem-main.el
+++ mod/lisp/xwem-main.el
@@ -330,27 +330,24 @@
(run-hooks 'xwem-config-read-hook)
(add-hook 'window-setup-hook 'xwem-after-window-setup)
- (add-hook 'kill-emacs-hook 'xwem-fini t)
- )
+ (add-hook 'kill-emacs-hook 'xwem-fini t))
;;;###autoload(autoload 'xwem-fini "xwem-main" nil t)
(define-xwem-command xwem-fini ()
"Fini all subsystems."
(xwem-interactive)
-; (xwem-kbd-quit)
-; (xwem-frames-fini)
-; (xwem-fini-clients)
- ;; Finally run exit hooks
- (run-hooks 'xwem-exit-hook)
+ (ignore-errors
+ ;; Finally run exit hooks
+ (run-hooks 'xwem-exit-hook))
;; Remove XWEM_RUNNING environment variable if it is set
(when (getenv "XWEM_RUNNING")
(setenv "XWEM_RUNNING" nil 'unset))
- ;; And close display
- (xwem-fini-root)
- )
+ (ignore-errors
+ ;; And close display
+ (xwem-fini-root)))
(provide 'xwem-main)
--- orig/lisp/xwem-minibuffer.el
+++ mod/lisp/xwem-minibuffer.el
@@ -286,8 +286,9 @@
(defun xwem-minib-apply-specifiers (frame)
"Apply `xwem-minib-specifiers' to FRAME."
(mapc #'(lambda (spc)
- (set-specifier (eval (car spc)) (eval (cdr spc))
- frame nil 'remove-locale))
+ (ignore-errors
+ (set-specifier (eval (car spc)) (eval (cdr spc))
+ frame nil 'remove-locale)))
xwem-minib-specifiers))
(defun xwem-minib-create ()
--- orig/lisp/xwem-misc.el
+++ mod/lisp/xwem-misc.el
@@ -219,7 +219,7 @@
(defcustom xwem-messages-label-prefixes
'((warning "Warning" (red))
- (error "Erorr" (red bold))
+ (error "Error" (red bold))
(alarm "Alarm" (red bold italic))
(note "Note" (yellow))
(info "Info" (default))
--- orig/lisp/xwem-special.el
+++ mod/lisp/xwem-special.el
@@ -253,7 +253,8 @@
(cond ((eq strategy 'half)
(setq fgeom
(make-X-Geom
- :x (X-Geom-x (xwem-minib-xgeom xwem-minibuffer))
+ :x (- (X-Geom-x (xwem-minib-xgeom xwem-minibuffer))
+ (X-Geom-border-width (xwem-minib-xgeom
xwem-minibuffer)))
:y (/ (X-Geom-y (xwem-minib-xgeom xwem-minibuffer)) 2)
:width (X-Geom-width-with-borders
(xwem-minib-cl-xgeom xwem-minibuffer))
|