Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Peter Liljenberg
lyskom-elisp-client
Commits
0513d1f0
Commit
0513d1f0
authored
Sep 22, 1997
by
David Byers
Browse files
Fixade kom-next-kom mfl igen.
Kör lyskom-end-of-command i rätt buffert
parent
7cf19953
Changes
6
Hide whitespace changes
Inline
Side-by-side
src/ChangeLog
View file @
0513d1f0
1997-09-22 David Byers <davby@ida.liu.se>
* commands2.el (lyskom-next-kom): Ny funktion.
(kom-next-unread-kom): Anvnd lyskom-next-kom.
(kom-previous-kom): Anvnd lyskom-previous-kom.
(kom-next-kom): Anvnd lyskom-next-kom.
(lyskom-previous-kom): Ny funktion.
* command.el (lyskom-end-of-command): Stt inte buffert hr.
(def-kom-emacs-command): Kr lyskom-end-of-command i samma buffert
som lyskom-start-of-command.
(def-kom-command): Dito.
* swedish-strings.el (lyskom-command): Lade till
kom-next-unread-kom.
(lyskom-message): Lade till strngar fr kom-next-kom mfl
* vars.el.in (lyskom-commands): Lade till kom-next-unread-kom.
Sun Sep 21 10:25:51 1997 David Byers <davby@ida.liu.se>
* command.el (def-kom-emacs-command): Nytt makro.
...
...
src/command.el
View file @
0513d1f0
...
...
@@ -58,18 +58,23 @@
;;; ...)
(
defmacro
def-kom-command
(
cmd
args
doc
interactive-decl
&rest
forms
)
(
`
(
defun
(
,
cmd
)
(
,
args
)
(
,
doc
)
(
,
interactive-decl
)
(
lyskom-start-of-command
(
quote
(
,
cmd
)))
(
unwind-protect
(
condition-case
nil
(
progn
(
,@
forms
))
(
quit
(
ding
)
(
lyskom-insert-before-prompt
(
lyskom-get-string
'interrupted
))))
(
lyskom-end-of-command
)))))
(
let
((
bufsym
(
intern
(
format
"%S-start-buffer"
cmd
))))
(
`
(
defun
(
,
cmd
)
(
,
args
)
(
,
doc
)
(
,
interactive-decl
)
(
lyskom-start-of-command
(
quote
(
,
cmd
)))
(
let
(((
,
bufsym
)
(
current-buffer
)))
(
unwind-protect
(
condition-case
nil
(
progn
(
,@
forms
))
(
quit
(
ding
)
(
lyskom-insert-before-prompt
(
lyskom-get-string
'interrupted
))))
(
lyskom-save-excursion
(
when
(
buffer-live-p
(
,
bufsym
))
(
set-buffer
(
,
bufsym
)))
(
lyskom-end-of-command
))))))))
...
...
@@ -104,7 +109,8 @@
(
defmacro
def-kom-emacs-command
(
cmd
args
doc
interactive-decl
&rest
forms
)
(
let
((
rsym
(
intern
(
concat
(
format
"%S-running-as-kom-command"
cmd
)))))
cmd
))))
(
bufsym
(
intern
(
format
"%S-start-buffer"
cmd
))))
(
`
(
defun
(
,
cmd
)
(
,
args
)
(
,
doc
)
...
...
@@ -114,13 +120,18 @@
(
progn
(
lyskom-start-of-command
(
quote
(
,
cmd
)))
(
setq
(
,
rsym
)
t
))
(
error
nil
))
(
unwind-protect
(
condition-case
nil
(
progn
(
,@
forms
))
(
quit
(
ding
)
(
lyskom-insert-before-prompt
(
lyskom-get-string
'interrupted
))))
(
and
(
,
rsym
)
(
lyskom-end-of-command
))))))))
(
let
(((
,
bufsym
)
(
current-buffer
)))
(
unwind-protect
(
condition-case
nil
(
progn
(
,@
forms
))
(
quit
(
ding
)
(
lyskom-insert-before-prompt
(
lyskom-get-string
'interrupted
))))
(
and
(
,
rsym
)
(
lyskom-save-excursion
(
when
(
buffer-live-p
(
,
bufsym
))
(
set-buffer
(
,
bufsym
)))
(
lyskom-end-of-command
))))))))))
...
...
@@ -285,9 +296,6 @@ chosen according to this"
(
defun
lyskom-end-of-command
()
"Print prompt, maybe scroll, prefetch info."
(
lyskom-save-excursion
(
when
(
and
(
boundp
'lyskom-buffer
)
(
buffer-live-p
lyskom-buffer
))
(
set-buffer
lyskom-buffer
))
(
message
""
)
(
while
(
and
lyskom-to-be-printed-before-prompt
(
lyskom-queue->first
lyskom-to-be-printed-before-prompt
))
...
...
src/commands2.el
View file @
0513d1f0
...
...
@@ -1495,11 +1495,8 @@ membership info."
(def-kom-emacs-command kom-next-kom ()
"
Pop
up
the
next
lyskom-session.
"
(interactive)
(if (lyskom-buffer-p (current-buffer))
(lyskom-tell-internat 'kom-tell-next-lyskom))
(defun lyskom-next-kom ()
"
Internal
version
of
kom-next-kom
"
(if lyskom-buffer-list
(progn
(if (lyskom-buffer-p (car lyskom-buffer-list))
...
...
@@ -1527,15 +1524,12 @@ membership info."
;; Don't switch to dead sessions.
(if (lyskom-buffer-p (car lyskom-buffer-list))
(switch-to-buffer (car lyskom-buffer-list))
(kom-next-kom)))
(
lys
kom-next-kom)))
(error "
No
active
LysKOM
buffers
")))
(def-kom-emacs-command kom-previous-kom ()
"
Pop
up
the
previous
lyskom-session.
"
(interactive)
(if (lyskom-buffer-p (current-buffer))
(lyskom-tell-internat 'kom-tell-next-lyskom))
(defun lyskom-previous-kom ()
"
Internal
version
of
kom-previous-kom
"
(if (> (length lyskom-buffer-list) 1)
(let (lastbuf
(last-but-one lyskom-buffer-list))
...
...
@@ -1565,21 +1559,55 @@ membership info."
(rplacd last-but-one nil))
(if (lyskom-buffer-p (car last-but-one))
(switch-to-buffer lastbuf)
(kom-previous-kom)))
(
lys
kom-previous-kom)))
(if (null lyskom-buffer-list)
(error "
No
active
LysKOM
buffers
"))))
(error
(lyskom-get-string 'no-lyskom-session)))))
(def-kom-emacs-command kom-next-kom ()
"
Pop
up
the
next
lyskom-session.
"
(interactive)
(let ((start-buffer (current-buffer)))
(if (lyskom-buffer-p (current-buffer))
(lyskom-tell-internat 'kom-tell-next-lyskom))
(lyskom-next-kom)
(when (eq (current-buffer) start-buffer)
(if kom-next-kom-running-as-kom-command
(lyskom-insert-before-prompt (lyskom-get-string 'no-other-lyskom-r))
(error (lyskom-get-string 'no-lyskom-session))))))
(def-kom-emacs-command kom-previous-kom ()
"
Pop
up
the
previous
lyskom-session.
"
(interactive)
(let ((start-buffer (current-buffer)))
(if (lyskom-buffer-p (current-buffer))
(lyskom-tell-internat 'kom-tell-next-lyskom))
(lyskom-previous-kom)
(when (eq (current-buffer) start-buffer)
(if kom-previous-kom-running-as-kom-command
(lyskom-insert-before-prompt (lyskom-get-string 'no-other-lyskom-r))
(error 'no-lyskom-session)))))
(def
un
kom-next-unread-kom ()
(def
-kom-emacs-command
kom-next-unread-kom ()
"
Pop
up
the
next
LysKOM
session
with
unread
texts
in.
"
(interactive)
(if (not (lyskom-buffer-p (current-buffer)))
(kom-next-kom))
(let ((thisbuf (current-buffer)))
(kom-next-kom)
(while (and (not (eq thisbuf (current-buffer)))
(not (memq lyskom-buffer lyskom-sessions-with-unread)))
(kom-next-kom))))
(let ((start-buffer (current-buffer)))
(if (not (lyskom-buffer-p (current-buffer)))
(lyskom-next-kom))
(let ((thisbuf (current-buffer)))
(lyskom-next-kom)
(while (and (not (eq thisbuf (current-buffer)))
(not (memq lyskom-buffer lyskom-sessions-with-unread)))
(lyskom-next-kom)))
(when (eq start-buffer (current-buffer))
(if kom-next-unread-kom-running-as-kom-command
(lyskom-insert-before-prompt
(lyskom-get-string 'no-unread-lyskom-r))
(error (lyskom-get-string 'no-unread-lyskom))))))
;;;============================================================
...
...
src/english-strings.el
View file @
0513d1f0
...
...
@@ -411,6 +411,12 @@ Read all about it at http://www.lysator.liu.se/history/")
(
showing-invisibles
.
"Showing invisible sessions.\n"
)
(
null-who-info
.
"No one (active) is logged on.\n"
)
(
no-other-lyskom-r
.
"There are not other active LysKOM sessions.\n"
)
(
no-lyskom-session
.
"There are no active LysKOM-sessions."
)
(
no-unread-lyskom-r
.
"There is no active LysKOM session with unread texts.\n"
)
(
no-unread-lyskom
.
"There is no active LysKOM session with unread texts."
)
; From commands2.el:
(
your-memberships
.
"Your LysKOM conference memberships:\n"
)
...
...
@@ -1163,6 +1169,7 @@ On since %#8s%#9s")
(kom-status-session . "
Status
(
of
a
)
session
")
(kom-next-kom . "
Next
LysKOM
")
(kom-previous-kom . "
Previous
LysKOM
")
(kom-next-unread-kom . "
Next
unread
LysKOM
")
(kom-customize . "
Customize
LysKOM
")
(kom-change-language . "
Change
language
")
(kom-calculate . "
Calculate
")
...
...
src/swedish-strings.el
View file @
0513d1f0
No preview for this file type
src/vars.el.in
View file @
0513d1f0
...
...
@@ -1026,6 +1026,7 @@ Users are encouraged to use their best sense of humor."
kom-next-kom
kom-previous-kom
kom-next-unread-kom
))
;(defconst lyskom-elisp-variables
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment