Mercurial > emacs
diff src/xselect.c @ 46370:40db0673e6f0
Most uses of XSTRING combined with STRING_BYTES or indirection changed to
SCHARS, SBYTES, STRING_INTERVALS, SREF, SDATA; explicit size_byte references
left unchanged for now.
author | Ken Raeburn <raeburn@raeburn.org> |
---|---|
date | Mon, 15 Jul 2002 00:00:41 +0000 |
parents | 1fb8f75062c6 |
children | 970ca194ce9a |
line wrap: on
line diff
--- a/src/xselect.c Sun Jul 14 23:54:05 2002 +0000 +++ b/src/xselect.c Mon Jul 15 00:00:41 2002 +0000 @@ -200,9 +200,9 @@ #endif if (!SYMBOLP (sym)) abort (); - TRACE1 (" XInternAtom %s", (char *) XSTRING (SYMBOL_NAME (sym))->data); + TRACE1 (" XInternAtom %s", (char *) SDATA (SYMBOL_NAME (sym))); BLOCK_INPUT; - val = XInternAtom (display, (char *) XSTRING (SYMBOL_NAME (sym))->data, False); + val = XInternAtom (display, (char *) SDATA (SYMBOL_NAME (sym)), False); UNBLOCK_INPUT; return val; } @@ -1272,7 +1272,7 @@ if (NILP (XCAR (reading_selection_reply))) error ("Timed out waiting for reply from selection owner"); if (EQ (XCAR (reading_selection_reply), Qlambda)) - error ("No `%s' selection", XSTRING (SYMBOL_NAME (selection_symbol))->data); + error ("No `%s' selection", SDATA (SYMBOL_NAME (selection_symbol))); /* Otherwise, the selection is waiting for us on the requested property. */ return @@ -1662,7 +1662,7 @@ str = run_pre_post_conversion_on_str (str, &coding, 0); Vlast_coding_system_used = coding.symbol; } - compose_chars_in_text (0, XSTRING (str)->size, str); + compose_chars_in_text (0, SCHARS (str), str); return str; } /* Convert a single atom to a Lisp_Symbol. Convert a set of atoms to @@ -1778,7 +1778,7 @@ Lisp_Object unibyte_string; unibyte_string = string_make_unibyte (obj); - *data_ret = XSTRING (unibyte_string)->data; + *data_ret = SDATA (unibyte_string); *nofree_ret = 1; *size_ret = SBYTES (unibyte_string); } @@ -1786,7 +1786,7 @@ { *data_ret = x_encode_text (obj, Vnext_selection_coding_system, 1, (int *) size_ret, &stringp); - *nofree_ret = (*data_ret == XSTRING (obj)->data); + *nofree_ret = (*data_ret == SDATA (obj)); } if (NILP (type)) type = (stringp ? QSTRING : QCOMPOUND_TEXT); @@ -2277,8 +2277,8 @@ CHECK_STRING (string); buffer_atom = symbol_to_x_atom (FRAME_X_DISPLAY_INFO (sf), display, buffer); - data = (unsigned char *) XSTRING (string)->data; - bytes = STRING_BYTES (XSTRING (string)); + data = (unsigned char *) SDATA (string); + bytes = SBYTES (string); bytes_remaining = bytes; if (! FRAME_X_DISPLAY_INFO (sf)->cut_buffers_initialized)