diff options
Diffstat (limited to 'src/w16select.c')
| -rw-r--r-- | src/w16select.c | 48 |
1 files changed, 36 insertions, 12 deletions
diff --git a/src/w16select.c b/src/w16select.c index 4d471e97911..994ad9e543f 100644 --- a/src/w16select.c +++ b/src/w16select.c | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | /* 16-bit Windows Selection processing for emacs on MS-Windows | 1 | /* 16-bit Windows Selection processing for emacs on MS-Windows |
| 2 | Copyright (C) 1996, 1997, 2001, 2002, 2003, 2004, | 2 | |
| 3 | 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. | 3 | Copyright (C) 1996, 1997, 2001, 2002, 2003, 2004, 2005, 2006, 2007, |
| 4 | 2008, 2009, 2010 Free Software Foundation, Inc. | ||
| 4 | 5 | ||
| 5 | This file is part of GNU Emacs. | 6 | This file is part of GNU Emacs. |
| 6 | 7 | ||
| @@ -693,18 +694,43 @@ syms_of_win16select (void) | |||
| 693 | defsubr (&Sx_selection_exists_p); | 694 | defsubr (&Sx_selection_exists_p); |
| 694 | 695 | ||
| 695 | DEFVAR_LISP ("selection-coding-system", &Vselection_coding_system, | 696 | DEFVAR_LISP ("selection-coding-system", &Vselection_coding_system, |
| 696 | doc: /* Coding system for communicating with other X clients. | 697 | doc: /* Coding system for communicating with other programs. |
| 697 | When sending or receiving text via cut_buffer, selection, and clipboard, | 698 | |
| 698 | the text is encoded or decoded by this coding system. | 699 | For MS-Windows and MS-DOS: |
| 699 | The default value is `iso-latin-1-dos'. */); | 700 | When sending or receiving text via selection and clipboard, the text |
| 701 | is encoded or decoded by this coding system. The default value is | ||
| 702 | the current system default encoding on 9x/Me, `utf-16le-dos' | ||
| 703 | \(Unicode) on NT/W2K/XP, and `iso-latin-1-dos' on MS-DOS. | ||
| 704 | |||
| 705 | For X Windows: | ||
| 706 | When sending text via selection and clipboard, if the target | ||
| 707 | data-type matches with the type of this coding system, it is used | ||
| 708 | for encoding the text. Otherwise (including the case that this | ||
| 709 | variable is nil), a proper coding system is used as below: | ||
| 710 | |||
| 711 | data-type coding system | ||
| 712 | --------- ------------- | ||
| 713 | UTF8_STRING utf-8 | ||
| 714 | COMPOUND_TEXT compound-text-with-extensions | ||
| 715 | STRING iso-latin-1 | ||
| 716 | C_STRING no-conversion | ||
| 717 | |||
| 718 | When receiving text, if this coding system is non-nil, it is used | ||
| 719 | for decoding regardless of the data-type. If this is nil, a | ||
| 720 | proper coding system is used according to the data-type as above. | ||
| 721 | |||
| 722 | See also the documentation of the variable `x-select-request-type' how | ||
| 723 | to control which data-type to request for receiving text. | ||
| 724 | |||
| 725 | The default value is nil. */); | ||
| 700 | Vselection_coding_system = intern ("iso-latin-1-dos"); | 726 | Vselection_coding_system = intern ("iso-latin-1-dos"); |
| 701 | 727 | ||
| 702 | DEFVAR_LISP ("next-selection-coding-system", &Vnext_selection_coding_system, | 728 | DEFVAR_LISP ("next-selection-coding-system", &Vnext_selection_coding_system, |
| 703 | doc: /* Coding system for the next communication with other X clients. | 729 | doc: /* Coding system for the next communication with other programs. |
| 704 | Usually, `selection-coding-system' is used for communicating with | 730 | Usually, `selection-coding-system' is used for communicating with |
| 705 | other X clients. But, if this variable is set, it is used for the | 731 | other programs (X Windows clients or MS Windows programs). But, if this |
| 706 | next communication only. After the communication, this variable is | 732 | variable is set, it is used for the next communication only. |
| 707 | set to nil. */); | 733 | After the communication, this variable is set to nil. */); |
| 708 | Vnext_selection_coding_system = Qnil; | 734 | Vnext_selection_coding_system = Qnil; |
| 709 | 735 | ||
| 710 | QPRIMARY = intern ("PRIMARY"); staticpro (&QPRIMARY); | 736 | QPRIMARY = intern ("PRIMARY"); staticpro (&QPRIMARY); |
| @@ -713,5 +739,3 @@ set to nil. */); | |||
| 713 | 739 | ||
| 714 | #endif /* MSDOS */ | 740 | #endif /* MSDOS */ |
| 715 | 741 | ||
| 716 | /* arch-tag: 085a22c8-7324-436e-a6da-102464ce95d8 | ||
| 717 | (do not change this comment) */ | ||