|
Last change
on this file was 6569, checked in by Gary Byers, 18 years ago |
|
Move more (currently unused, often unlikely to ever be used) stuff to an
archive directory.
|
-
Property svn:eol-style
set to
native
-
Property svn:keywords
set to
Author Date Id Revision
|
|
File size:
1.4 KB
|
| Line | |
|---|
| 1 | ;;; -*- Log: hemlock.log; Package: Hemlock -*-
|
|---|
| 2 | ;;;
|
|---|
| 3 | ;;; **********************************************************************
|
|---|
| 4 | ;;; This code was written as part of the CMU Common Lisp project at
|
|---|
| 5 | ;;; Carnegie Mellon University, and has been placed in the public domain.
|
|---|
| 6 | ;;;
|
|---|
| 7 | #+CMU (ext:file-comment
|
|---|
| 8 | "$Header$")
|
|---|
| 9 | ;;;
|
|---|
| 10 | ;;; **********************************************************************
|
|---|
| 11 | ;;;
|
|---|
| 12 | ;;; This file contains commands and support specifically for X related features.
|
|---|
| 13 | ;;;
|
|---|
| 14 | ;;; Written by Bill Chiles.
|
|---|
| 15 | ;;;
|
|---|
| 16 |
|
|---|
| 17 | (in-package :hemlock)
|
|---|
| 18 |
|
|---|
| 19 |
|
|---|
| 20 | (defcommand "Region to Cut Buffer" (p)
|
|---|
| 21 | "Place the current region into the X cut buffer."
|
|---|
| 22 | "Place the current region into the X cut buffer."
|
|---|
| 23 | (declare (ignore p))
|
|---|
| 24 | (store-cut-string (hi::bitmap-device-display
|
|---|
| 25 | (hi::device-hunk-device (hi::window-hunk (current-window))))
|
|---|
| 26 | (region-to-string (current-region))))
|
|---|
| 27 |
|
|---|
| 28 | (defcommand "Insert Cut Buffer" (p)
|
|---|
| 29 | "Insert the X cut buffer at current point."
|
|---|
| 30 | "Insert the X cut buffer at current point. Returns nil when it is empty."
|
|---|
| 31 | (declare (ignore p))
|
|---|
| 32 | (let ((str (fetch-cut-string (hi::bitmap-device-display
|
|---|
| 33 | (hi::device-hunk-device
|
|---|
| 34 | (hi::window-hunk (current-window)))))))
|
|---|
| 35 | (if str
|
|---|
| 36 | (let ((point (current-point)))
|
|---|
| 37 | (push-buffer-mark (copy-mark point))
|
|---|
| 38 | (insert-string (current-point) str))
|
|---|
| 39 | (editor-error "X cut buffer empty.")))
|
|---|
| 40 | (setf (last-command-type) :ephemerally-active))
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.