Mercurial > emacs
comparison lisp/term/w32-win.el @ 16889:8de32e992e4d
Change uses of win32 to w32.
author | Geoff Voelker <voelker@cs.washington.edu> |
---|---|
date | Mon, 20 Jan 1997 01:07:48 +0000 |
parents | 0f917c0edc53 |
children | 337f5643498e |
comparison
equal
deleted
inserted
replaced
16888:380c7e461c14 | 16889:8de32e992e4d |
---|---|
1 ;;; win32-win.el --- parse switches controlling interface with win32 | 1 ;;; w32-win.el --- parse switches controlling interface with W32 window system. |
2 | 2 |
3 ;; Copyright (C) 1993, 1994 Free Software Foundation, Inc. | 3 ;; Copyright (C) 1993, 1994 Free Software Foundation, Inc. |
4 | 4 |
5 ;; Author: Kevin Gallo | 5 ;; Author: Kevin Gallo |
6 ;; Keywords: terminals | 6 ;; Keywords: terminals |
22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
23 ;; Boston, MA 02111-1307, USA. | 23 ;; Boston, MA 02111-1307, USA. |
24 | 24 |
25 ;;; Commentary: | 25 ;;; Commentary: |
26 | 26 |
27 ;; win32-win.el: this file is loaded from ../lisp/startup.el when it recognizes | 27 ;; w32-win.el: this file is loaded from ../lisp/startup.el when it recognizes |
28 ;; that win32 windows are to be used. Command line switches are parsed and those | 28 ;; that W32 windows are to be used. Command line switches are parsed and those |
29 ;; pertaining to win32 are processed and removed from the command line. The | 29 ;; pertaining to W32 are processed and removed from the command line. The |
30 ;; win32 display is opened and hooks are set for popping up the initial window. | 30 ;; W32 display is opened and hooks are set for popping up the initial window. |
31 | 31 |
32 ;; startup.el will then examine startup files, and eventually call the hooks | 32 ;; startup.el will then examine startup files, and eventually call the hooks |
33 ;; which create the first window (s). | 33 ;; which create the first window (s). |
34 | 34 |
35 ;;; Code: | 35 ;;; Code: |
65 ;; -xrm | 65 ;; -xrm |
66 | 66 |
67 ;; An alist of X options and the function which handles them. See | 67 ;; An alist of X options and the function which handles them. See |
68 ;; ../startup.el. | 68 ;; ../startup.el. |
69 | 69 |
70 (if (not (eq window-system 'win32)) | 70 (if (not (eq window-system 'w32)) |
71 (error "%s: Loading win32-win.el but not compiled for win32" (invocation-name))) | 71 (error "%s: Loading w32-win.el but not compiled for w32" (invocation-name))) |
72 | 72 |
73 (require 'frame) | 73 (require 'frame) |
74 (require 'mouse) | 74 (require 'mouse) |
75 (require 'scroll-bar) | 75 (require 'scroll-bar) |
76 (require 'faces) | 76 (require 'faces) |
80 ;; Because Windows scrollbars look and act quite differently compared | 80 ;; Because Windows scrollbars look and act quite differently compared |
81 ;; with the standard X scroll-bars, we don't try to use the normal | 81 ;; with the standard X scroll-bars, we don't try to use the normal |
82 ;; scroll bar routines. | 82 ;; scroll bar routines. |
83 | 83 |
84 (defun w32-handle-scroll-bar-event (event) | 84 (defun w32-handle-scroll-bar-event (event) |
85 "Handle Win32 scroll bar events to do normal Window style scrolling." | 85 "Handle W32 scroll bar events to do normal Window style scrolling." |
86 (interactive "e") | 86 (interactive "e") |
87 (let ((old-window (selected-window))) | 87 (let ((old-window (selected-window))) |
88 (unwind-protect | 88 (unwind-protect |
89 (let* ((position (event-start event)) | 89 (let* ((position (event-start event)) |
90 (window (nth 0 position)) | 90 (window (nth 0 position)) |
621 (setq x-selection-timeout 20000) | 621 (setq x-selection-timeout 20000) |
622 (if res-selection-timeout | 622 (if res-selection-timeout |
623 (setq x-selection-timeout (string-to-number res-selection-timeout)))) | 623 (setq x-selection-timeout (string-to-number res-selection-timeout)))) |
624 | 624 |
625 (defun x-win-suspend-error () | 625 (defun x-win-suspend-error () |
626 (error "Suspending an emacs running under Win32 makes no sense")) | 626 (error "Suspending an emacs running under W32 makes no sense")) |
627 (add-hook 'suspend-hook 'x-win-suspend-error) | 627 (add-hook 'suspend-hook 'x-win-suspend-error) |
628 | 628 |
629 ;;; Arrange for the kill and yank functions to set and check the clipboard. | 629 ;;; Arrange for the kill and yank functions to set and check the clipboard. |
630 (setq interprogram-cut-function 'x-select-text) | 630 (setq interprogram-cut-function 'x-select-text) |
631 (setq interprogram-paste-function 'x-get-selection-value) | 631 (setq interprogram-paste-function 'x-get-selection-value) |
658 " be " bool "? ")) | 658 " be " bool "? ")) |
659 (read-string (concat prompt " " (symbol-name face) " to: ") | 659 (read-string (concat prompt " " (symbol-name face) " to: ") |
660 default))))) | 660 default))))) |
661 (list face (if (equal value "") nil value)))) | 661 (list face (if (equal value "") nil value)))) |
662 | 662 |
663 ;; Redefine the font selection to use the standard Win32 dialog | 663 ;; Redefine the font selection to use the standard W32 dialog |
664 | 664 |
665 (defun mouse-set-font (&rest fonts) | 665 (defun mouse-set-font (&rest fonts) |
666 (interactive) | 666 (interactive) |
667 (set-default-font (w32-select-font))) | 667 (set-default-font (w32-select-font))) |
668 | 668 |
669 ;;; win32-win.el ends here | 669 ;;; w32-win.el ends here |