id = x_allocate_bitmap_record (f);
dpyinfo->bitmaps[id - 1].pixmap = bitmap;
dpyinfo->bitmaps[id - 1].refcount = 1;
- dpyinfo->bitmaps[id - 1].file = (char *) xmalloc (XSTRING (file)->size + 1);
+ dpyinfo->bitmaps[id - 1].file
+ = (char *) xmalloc (XSTRING (file)->size_byte + 1);
dpyinfo->bitmaps[id - 1].depth = 1;
dpyinfo->bitmaps[id - 1].height = height;
dpyinfo->bitmaps[id - 1].width = width;
make_number (i));
}
\f
-/* Change the parameters of FRAME as specified by ALIST.
+/* Change the parameters of frame F as specified by ALIST.
If a parameter is not specially recognized, do nothing;
otherwise call the `x_set_...' function for that parameter. */
text.value = XSTRING (name)->data;
text.encoding = XA_STRING;
text.format = 8;
- text.nitems = XSTRING (name)->size;
+ text.nitems = XSTRING (name)->size_byte;
icon_name = (!NILP (f->icon_name) ? f->icon_name : name);
icon.value = XSTRING (icon_name)->data;
icon.encoding = XA_STRING;
icon.format = 8;
- icon.nitems = XSTRING (icon_name)->size;
+ icon.nitems = XSTRING (icon_name)->size_byte;
#ifdef USE_X_TOOLKIT
XSetWMName (FRAME_X_DISPLAY (f),
XtWindow (f->output_data.x->widget), &text);
text.value = XSTRING (name)->data;
text.encoding = XA_STRING;
text.format = 8;
- text.nitems = XSTRING (name)->size;
+ text.nitems = XSTRING (name)->size_byte;
icon_name = (!NILP (f->icon_name) ? f->icon_name : name);
icon.value = XSTRING (icon_name)->data;
icon.encoding = XA_STRING;
icon.format = 8;
- icon.nitems = XSTRING (icon_name)->size;
+ icon.nitems = XSTRING (icon_name)->size_byte;
#ifdef USE_X_TOOLKIT
XSetWMName (FRAME_X_DISPLAY (f),
XtWindow (f->output_data.x->widget), &text);
unsigned char *p = XSTRING (Vx_resource_name)->data;
int i;
- len = XSTRING (Vx_resource_name)->size;
+ len = XSTRING (Vx_resource_name)->size_byte;
/* Only letters, digits, - and _ are valid in resource names.
Count the valid characters and count the invalid ones. */
/* Allocate space for the components, the dots which separate them,
and the final '\0'. Make them big enough for the worst case. */
- name_key = (char *) alloca (XSTRING (Vx_resource_name)->size
+ name_key = (char *) alloca (XSTRING (Vx_resource_name)->size_byte
+ (STRINGP (component)
- ? XSTRING (component)->size : 0)
- + XSTRING (attribute)->size
+ ? XSTRING (component)->size_byte : 0)
+ + XSTRING (attribute)->size_byte
+ 3);
- class_key = (char *) alloca (XSTRING (Vx_resource_class)->size
- + XSTRING (class)->size
+ class_key = (char *) alloca (XSTRING (Vx_resource_class)->size_byte
+ + XSTRING (class)->size_byte
+ (STRINGP (subclass)
- ? XSTRING (subclass)->size : 0)
+ ? XSTRING (subclass)->size_byte : 0)
+ 3);
/* Start with emacs.FRAMENAME for the name (the specific one)
/* Allocate space for the components, the dots which separate them,
and the final '\0'. Make them big enough for the worst case. */
- name_key = (char *) alloca (XSTRING (Vx_resource_name)->size
+ name_key = (char *) alloca (XSTRING (Vx_resource_name)->size_byte
+ (STRINGP (component)
- ? XSTRING (component)->size : 0)
- + XSTRING (attribute)->size
+ ? XSTRING (component)->size_byte : 0)
+ + XSTRING (attribute)->size_byte
+ 3);
- class_key = (char *) alloca (XSTRING (Vx_resource_class)->size
- + XSTRING (class)->size
+ class_key = (char *) alloca (XSTRING (Vx_resource_class)->size_byte
+ + XSTRING (class)->size_byte
+ (STRINGP (subclass)
- ? XSTRING (subclass)->size : 0)
+ ? XSTRING (subclass)->size_byte : 0)
+ 3);
/* Start with emacs.FRAMENAME for the name (the specific one)
/* Allocate space for the components, the dots which separate them,
and the final '\0'. */
- name_key = (char *) alloca (XSTRING (Vinvocation_name)->size
+ name_key = (char *) alloca (XSTRING (Vinvocation_name)->size_byte
+ strlen (attribute) + 2);
class_key = (char *) alloca ((sizeof (EMACS_CLASS) - 1)
+ strlen (class) + 2);
}
/* Record in frame F the specified or default value according to ALIST
- of the parameter named PARAM (a Lisp symbol).
- If no value is specified for PARAM, look for an X default for XPROP
+ of the parameter named PROP (a Lisp symbol).
+ If no value is specified for PROP, look for an X default for XPROP
on the frame named NAME.
If that is not found either, use the value DEFLT. */
}
int
-x_screen_planes (frame)
- Lisp_Object frame;
+x_screen_planes (f)
+ register struct frame *f;
{
- return FRAME_X_DISPLAY_INFO (XFRAME (frame))->n_planes;
+ return FRAME_X_DISPLAY_INFO (f)->n_planes;
}
\f
#if 0 /* These no longer seem like the right way to do things. */
if (NILP (modifiers))
XRebindKeysym (x_current_display, keysym, modifier_list, 0,
- XSTRING (newstring)->data, XSTRING (newstring)->size);
+ XSTRING (newstring)->data, XSTRING (newstring)->size_byte);
else
{
register Lisp_Object rest, mod;
}
XRebindKeysym (x_current_display, keysym, modifier_list, i,
- XSTRING (newstring)->data, XSTRING (newstring)->size);
+ XSTRING (newstring)->data, XSTRING (newstring)->size_byte);
}
return Qnil;
if (!NILP (item))
{
CHECK_STRING (item, 2);
- strsize = XSTRING (item)->size;
+ strsize = XSTRING (item)->size_byte;
rawstring = (unsigned char *) xmalloc (strsize);
bcopy (XSTRING (item)->data, rawstring, strsize);
modifier[1] = 1 << i;