X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/a9faac5c6333bcbfb30a00debf3de7a44e430e49..69481eb82d6b79eebb3c7283060fe8156089c381:/lisp/term/pc-win.el diff --git a/lisp/term/pc-win.el b/lisp/term/pc-win.el index d84d0fe9b2..b460e3b8a1 100644 --- a/lisp/term/pc-win.el +++ b/lisp/term/pc-win.el @@ -1,7 +1,7 @@ ;;; pc-win.el --- setup support for `PC windows' (whatever that is) -;; Copyright (C) 1994, 1996, 1997, 1999, 2001, 2002, 2003, 2004, 2005, -;; 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. +;; Copyright (C) 1994, 1996-1997, 1999, 2001-2012 +;; Free Software Foundation, Inc. ;; Author: Morten Welinder ;; Maintainer: FSF @@ -134,7 +134,7 @@ ;; terminal-initialization function. Also, our handling of reverse ;; video is slightly different. (defun msdos-create-frame-with-faces (&optional parameters) - "Create an frame on MS-DOS display. + "Create a frame on MS-DOS display. Optional frame parameters PARAMETERS specify the frame parameters. Parameters not specified by PARAMETERS are taken from `default-frame-alist'. If either PARAMETERS or `default-frame-alist' @@ -159,6 +159,12 @@ created." ;; returned value matters. Also, by the way, recall that `ignore' is ;; a useful function for returning 'nil regardless of argument. +;; Note: Any re-definition in this file of a function that is defined +;; in C on other platforms, should either have no doc-string, or one +;; that is identical to the C version, but with the arglist signature +;; at the end. Otherwise help-split-fundoc gets confused on other +;; platforms. (Bug#10783) + ;; From src/xfns.c (defun x-list-fonts (pattern &optional face frame maximum width) (if (or (null width) (and (numberp width) (= width 1))) @@ -218,11 +224,12 @@ On X, if `x-select-enable-clipboard' is non-nil, copy TEXT to the clipboard. If `x-select-enable-primary' is non-nil, put TEXT in the primary selection. -On Windows, make TEXT the current selection. If +On MS-Windows, make TEXT the current selection. If `x-select-enable-clipboard' is non-nil, copy the text to the clipboard as well. -On Nextstep, put TEXT in the pasteboard." +On Nextstep, put TEXT in the pasteboard (`x-select-enable-clipboard' +is not used)." (if x-select-enable-clipboard (w16-set-clipboard-data text)) (setq x-last-selected-text text)) @@ -248,13 +255,21 @@ On Nextstep, put TEXT in the pasteboard." (setq x-last-selected-text text)))))) ;; x-selection-owner-p is used in simple.el. -(defun x-selection-owner-p (&optional type) +(defun x-selection-owner-p (&optional selection terminal) "Whether the current Emacs process owns the given X Selection. The arg should be the name of the selection in question, typically one of the symbols `PRIMARY', `SECONDARY', or `CLIPBOARD'. \(Those are literal upper-case symbol names, since that's what X expects.) For convenience, the symbol nil is the same as `PRIMARY', -and t is the same as `SECONDARY'." +and t is the same as `SECONDARY'. + +TERMINAL should be a terminal object or a frame specifying the X +server to query. If omitted or nil, that stands for the selected +frame's display, or the first available X display. + +On Nextstep, TERMINAL is unused. + +\(fn &optional SELECTION TERMINAL)" (if x-select-enable-clipboard (let (text) ;; Don't die if w16-get-clipboard-data signals an error. @@ -272,30 +287,58 @@ and t is the same as `SECONDARY'." ;; x-own-selection-internal and x-disown-selection-internal are used ;; in select.el:x-set-selection. -(defun x-own-selection-internal (type value) - "Assert an X selection of the given TYPE with the given VALUE. -TYPE is a symbol, typically `PRIMARY', `SECONDARY', or `CLIPBOARD'. +(defun x-own-selection-internal (selection value &optional frame) + "Assert an X selection of the type SELECTION with and value VALUE. +SELECTION is a symbol, typically `PRIMARY', `SECONDARY', or `CLIPBOARD'. \(Those are literal upper-case symbol names, since that's what X expects.) VALUE is typically a string, or a cons of two markers, but may be -anything that the functions on `selection-converter-alist' know about." +anything that the functions on `selection-converter-alist' know about. + +FRAME should be a frame that should own the selection. If omitted or +nil, it defaults to the selected frame. + +On Nextstep, FRAME is unused. + +\(fn SELECTION VALUE &optional FRAME)" (ignore-errors (x-select-text value)) value) -(defun x-disown-selection-internal (selection &optional time) +(defun x-disown-selection-internal (selection &optional time-object terminal) "If we own the selection SELECTION, disown it. -Disowning it means there is no such selection." +Disowning it means there is no such selection. + +Sets the last-change time for the selection to TIME-OBJECT (by default +the time of the last event). + +TERMINAL should be a terminal object or a frame specifying the X +server to query. If omitted or nil, that stands for the selected +frame's display, or the first available X display. + +On Nextstep, the TIME-OBJECT and TERMINAL arguments are unused. +On MS-DOS, all this does is return non-nil if we own the selection. + +\(fn SELECTION &optional TIME-OBJECT TERMINAL)" (if (x-selection-owner-p selection) t)) ;; x-get-selection-internal is used in select.el -(defun x-get-selection-internal (selection type &optional time_stamp) +(defun x-get-selection-internal (selection-symbol target-type &optional time-stamp terminal) "Return text selected from some X window. -SELECTION is a symbol, typically `PRIMARY', `SECONDARY', or `CLIPBOARD'. +SELECTION-SYMBOL is typically `PRIMARY', `SECONDARY', or `CLIPBOARD'. \(Those are literal upper-case symbol names, since that's what X expects.) -TYPE is the type of data desired, typically `STRING'. -TIME_STAMP is the time to use in the XConvertSelection call for foreign -selections. If omitted, defaults to the time for the last event." +TARGET-TYPE is the type of data desired, typically `STRING'. + +TIME-STAMP is the time to use in the XConvertSelection call for foreign +selections. If omitted, defaults to the time for the last event. + +TERMINAL should be a terminal object or a frame specifying the X +server to query. If omitted or nil, that stands for the selected +frame's display, or the first available X display. + +On Nextstep, TIME-STAMP and TERMINAL are unused. + +\(fn SELECTION-SYMBOL TARGET-TYPE &optional TIME-STAMP TERMINAL)" (x-get-selection-value)) ;; From src/fontset.c: