window.sl 913 B

1234567891011121314151617181920212223242526272829303132
  1. %
  2. % Window.SL - Individual Window Manipulation Functions
  3. %
  4. % Author: Alan Snyder
  5. % Hewlett-Packard/CRC
  6. % Date: 20 July 1982
  7. %
  8. % This file contains functions that manipulate individual windows.
  9. % It is intended that someday EMODE will be reorganized
  10. % so that all such functions will eventually be in this file.
  11. %
  12. % This file requires COMMON.
  13. %
  14. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  15. (fluid '(CurrentWindowDelta TopOfDisplayIndex))
  16. (de current-window-height ()
  17. % Return the number of rows in the current window.
  18. (+ (Row CurrentWindowDelta) 1)
  19. )
  20. (de current-window-top-line ()
  21. % Return the index of the buffer line at the top of the current window.
  22. TopOfDisplayIndex
  23. )
  24. (de current-window-set-top-line (new-top-line)
  25. % Change which buffer line displays at the top of the current window.
  26. (setf TopOfDisplayIndex new-top-line)
  27. )