Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
ccd0664b
Commit
ccd0664b
authored
Jun 25, 1994
by
Richard M. Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(Fother_window_for_scrolling): New function.
(Fscroll_other_window): Use that. (syms_of_window): defsubr it.
parent
565101f4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
16 deletions
+31
-16
src/window.c
src/window.c
+31
-16
No files found.
src/window.c
View file @
ccd0664b
...
...
@@ -2341,24 +2341,15 @@ When calling from a program, supply a number as argument or nil.")
scroll_command
(
n
,
-
1
);
return
Qnil
;
}
DEFUN
(
"scroll-other-window"
,
Fscroll_other_window
,
Sscroll_other_window
,
0
,
1
,
"P"
,
"Scroll next window upward ARG lines; or near full screen if no ARG.
\n
\
The next window is the one below the current one; or the one at the top
\n
\
if the current one is at the bottom. Negative ARG means scroll downward.
\n
\
When calling from a program, supply a number as argument or nil.
\n
\
\n
\
DEFUN
(
"other-window-for-scrolling"
,
Fother_window_for_scrolling
,
Sother_window_for_scrolling
,
0
,
0
,
0
,
"Return the other window for
\"
other window scroll
\"
commands.
\n
\
If in the minibuffer, `minibuffer-scroll-window' if non-nil
\n
\
specifies the window to scroll.
\n
\
If `other-window-scroll-buffer' is non-nil, scroll the window
\n
\
showing that buffer, popping the buffer up if necessary."
)
(
n
)
register
Lisp_Object
n
;
specifies the window.
\n
\
If `other-window-scroll-buffer' is non-nil, a window
\n
\
showing that buffer is used."
)
{
register
Lisp_Object
window
;
register
int
ht
;
register
struct
window
*
w
;
register
int
count
=
specpdl_ptr
-
specpdl
;
Lisp_Object
window
;
if
(
MINI_WINDOW_P
(
XWINDOW
(
selected_window
))
&&
!
NILP
(
Vminibuf_scroll_window
))
...
...
@@ -2390,6 +2381,29 @@ showing that buffer, popping the buffer up if necessary.")
if
(
EQ
(
window
,
selected_window
))
error
(
"There is no other window"
);
return
window
;
}
DEFUN
(
"scroll-other-window"
,
Fscroll_other_window
,
Sscroll_other_window
,
0
,
1
,
"P"
,
"Scroll next window upward ARG lines; or near full screen if no ARG.
\n
\
The next window is the one below the current one; or the one at the top
\n
\
if the current one is at the bottom. Negative ARG means scroll downward.
\n
\
When calling from a program, supply a number as argument or nil.
\n
\
\n
\
If in the minibuffer, `minibuffer-scroll-window' if non-nil
\n
\
specifies the window to scroll.
\n
\
If `other-window-scroll-buffer' is non-nil, scroll the window
\n
\
showing that buffer, popping the buffer up if necessary."
)
(
n
)
register
Lisp_Object
n
;
{
register
Lisp_Object
window
;
register
int
ht
;
register
struct
window
*
w
;
register
int
count
=
specpdl_ptr
-
specpdl
;
window
=
Fother_window_for_scrolling
();
w
=
XWINDOW
(
window
);
ht
=
window_internal_height
(
w
);
...
...
@@ -3165,6 +3179,7 @@ If there is only one window, it is split regardless of this value.");
defsubr
(
&
Sscroll_down
);
defsubr
(
&
Sscroll_left
);
defsubr
(
&
Sscroll_right
);
defsubr
(
&
Sother_window_for_scrolling
);
defsubr
(
&
Sscroll_other_window
);
defsubr
(
&
Srecenter
);
defsubr
(
&
Smove_to_window_line
);
...
...
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