emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/src/xdisp.c


From: Gerd Moellmann
Subject: [Emacs-diffs] Changes to emacs/src/xdisp.c
Date: Fri, 08 Mar 2002 06:04:01 -0500

Index: emacs/src/xdisp.c
diff -c emacs/src/xdisp.c:1.735 emacs/src/xdisp.c:1.736
*** emacs/src/xdisp.c:1.735     Wed Mar  6 09:03:07 2002
--- emacs/src/xdisp.c   Fri Mar  8 06:03:53 2002
***************
*** 1169,1176 ****
  
    if (STRING_MULTIBYTE (string))
      {
!       int rest = STRING_BYTES (XSTRING (string)) - BYTEPOS (pos);
!       unsigned char *p = XSTRING (string)->data + BYTEPOS (pos);
        int len;
  
        while (nchars--)
--- 1169,1176 ----
  
    if (STRING_MULTIBYTE (string))
      {
!       int rest = SBYTES (string) - BYTEPOS (pos);
!       unsigned char *p = SDATA (string) + BYTEPOS (pos);
        int len;
  
        while (nchars--)
***************
*** 1864,1871 ****
  
    for (i = 0; i < it->n_overlay_strings; ++i)
      {
!       char *s = XSTRING (it->overlay_strings[i])->data;
!       char *e = s + STRING_BYTES (XSTRING (it->overlay_strings[i]));
        
        while (s < e && *s != '\n')
        ++s;
--- 1864,1871 ----
  
    for (i = 0; i < it->n_overlay_strings; ++i)
      {
!       char *s = SDATA (it->overlay_strings[i]);
!       char *e = s + SBYTES (it->overlay_strings[i]);
        
        while (s < e && *s != '\n')
        ++s;
***************
*** 2435,2441 ****
        /* No face change past the end of the string (for the case
         we are padding with spaces).  No face change before the
         string start.  */
!       if (IT_STRING_CHARPOS (*it) >= XSTRING (it->string)->size
          || (IT_STRING_CHARPOS (*it) == 0 && before_p))
        return it->face_id;
  
--- 2435,2441 ----
        /* No face change past the end of the string (for the case
         we are padding with spaces).  No face change before the
         string start.  */
!       if (IT_STRING_CHARPOS (*it) >= SCHARS (it->string)
          || (IT_STRING_CHARPOS (*it) == 0 && before_p))
        return it->face_id;
  
***************
*** 2471,2478 ****
         suitable for unibyte text if IT->string is unibyte.  */
        if (STRING_MULTIBYTE (it->string))
        {
!         unsigned char *p = XSTRING (it->string)->data + BYTEPOS (pos);
!         int rest = STRING_BYTES (XSTRING (it->string)) - BYTEPOS (pos);
          int c, len;
          struct face *face = FACE_FROM_ID (it->f, face_id);
        
--- 2471,2478 ----
         suitable for unibyte text if IT->string is unibyte.  */
        if (STRING_MULTIBYTE (it->string))
        {
!         unsigned char *p = SDATA (it->string) + BYTEPOS (pos);
!         int rest = SBYTES (it->string) - BYTEPOS (pos);
          int c, len;
          struct face *face = FACE_FROM_ID (it->f, face_id);
        
***************
*** 2558,2566 ****
             invisible text property can be found in IT->string.
             Value will be nil if the property value is the same for
             all the rest of IT->string.  */
!         XSETINT (limit, XSTRING (it->string)->size);
          end_charpos = Fnext_single_property_change (charpos, Qinvisible,
!                                                 it->string, limit);
          
          /* Text at current position is invisible.  The next
             change in the property is at position end_charpos.
--- 2558,2566 ----
             invisible text property can be found in IT->string.
             Value will be nil if the property value is the same for
             all the rest of IT->string.  */
!         XSETINT (limit, SCHARS (it->string));
          end_charpos = Fnext_single_property_change (charpos, Qinvisible,
!                                                     it->string, limit);
          
          /* Text at current position is invisible.  The next
             change in the property is at position end_charpos.
***************
*** 2587,2595 ****
                }
              else
                {
!                 struct Lisp_String *s = XSTRING (it->string);
!                 IT_STRING_CHARPOS (*it) = s->size;
!                 IT_STRING_BYTEPOS (*it) = STRING_BYTES (s);
                }
            }
        }
--- 2587,2594 ----
                }
              else
                {
!                 IT_STRING_CHARPOS (*it) = SCHARS (it->string);
!                 IT_STRING_BYTEPOS (*it) = SBYTES (it->string);
                }
            }
        }
***************
*** 3045,3052 ****
              it->multibyte_p = STRING_MULTIBYTE (it->string);
              it->current.overlay_string_index = -1;
              IT_STRING_CHARPOS (*it) = IT_STRING_BYTEPOS (*it) = 0;
!             it->end_charpos = it->string_nchars
!               = XSTRING (it->string)->size;
              it->method = next_element_from_string;
              it->stop_charpos = 0;
              it->string_from_display_prop_p = 1;
--- 3044,3050 ----
              it->multibyte_p = STRING_MULTIBYTE (it->string);
              it->current.overlay_string_index = -1;
              IT_STRING_CHARPOS (*it) = IT_STRING_BYTEPOS (*it) = 0;
!             it->end_charpos = it->string_nchars = SCHARS (it->string);
              it->method = next_element_from_string;
              it->stop_charpos = 0;
              it->string_from_display_prop_p = 1;
***************
*** 3574,3586 ****
        /* If overlay has a non-empty before-string, record it.  */
        if ((start == charpos || (end == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qbefore_string), STRINGP (str))
!         && XSTRING (str)->size)
        RECORD_OVERLAY_STRING (overlay, str, 0);
        
        /* If overlay has a non-empty after-string, record it.  */
        if ((end == charpos || (start == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qafter_string), STRINGP (str))
!         && XSTRING (str)->size)
        RECORD_OVERLAY_STRING (overlay, str, 1);
      }
        
--- 3572,3584 ----
        /* If overlay has a non-empty before-string, record it.  */
        if ((start == charpos || (end == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qbefore_string), STRINGP (str))
!         && SCHARS (str))
        RECORD_OVERLAY_STRING (overlay, str, 0);
        
        /* If overlay has a non-empty after-string, record it.  */
        if ((end == charpos || (start == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qafter_string), STRINGP (str))
!         && SCHARS (str))
        RECORD_OVERLAY_STRING (overlay, str, 1);
      }
        
***************
*** 3613,3625 ****
        /* If overlay has a non-empty before-string, record it.  */
        if ((start == charpos || (end == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qbefore_string), STRINGP (str))
!         && XSTRING (str)->size)
        RECORD_OVERLAY_STRING (overlay, str, 0);
                               
        /* If overlay has a non-empty after-string, record it.  */
        if ((end == charpos || (start == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qafter_string), STRINGP (str))
!         && XSTRING (str)->size)
        RECORD_OVERLAY_STRING (overlay, str, 1);
      }
  
--- 3611,3623 ----
        /* If overlay has a non-empty before-string, record it.  */
        if ((start == charpos || (end == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qbefore_string), STRINGP (str))
!         && SCHARS (str))
        RECORD_OVERLAY_STRING (overlay, str, 0);
                               
        /* If overlay has a non-empty after-string, record it.  */
        if ((end == charpos || (start == charpos && invis_p))
          && (str = Foverlay_get (overlay, Qafter_string), STRINGP (str))
!         && SCHARS (str))
        RECORD_OVERLAY_STRING (overlay, str, 1);
      }
  
***************
*** 3684,3692 ****
        IT_STRING_CHARPOS (*it) = IT_STRING_BYTEPOS (*it) = 0;
        it->string = it->overlay_strings[0];
        it->stop_charpos = 0;
-       it->end_charpos = XSTRING (it->string)->size;
-       it->multibyte_p = STRING_MULTIBYTE (it->string);
        xassert (STRINGP (it->string));
        it->method = next_element_from_string;
      }
    else
--- 3682,3690 ----
        IT_STRING_CHARPOS (*it) = IT_STRING_BYTEPOS (*it) = 0;
        it->string = it->overlay_strings[0];
        it->stop_charpos = 0;
        xassert (STRINGP (it->string));
+       it->end_charpos = SCHARS (it->string);
+       it->multibyte_p = SMBP (it->string);
        it->method = next_element_from_string;
      }
    else
***************
*** 4112,4118 ****
        xassert (STRINGP (string));
        it->string = string;
        it->s = NULL;
!       it->end_charpos = it->string_nchars = XSTRING (string)->size;
        it->method = next_element_from_string;
        it->current.string_pos = string_pos (charpos, string);
      }
--- 4110,4116 ----
        xassert (STRINGP (string));
        it->string = string;
        it->s = NULL;
!       it->end_charpos = it->string_nchars = SCHARS (string);
        it->method = next_element_from_string;
        it->current.string_pos = string_pos (charpos, string);
      }
***************
*** 4465,4471 ****
        {
          /* IT->string is an overlay string.  Advance to the
             next, if there is one.  */
!         if (IT_STRING_CHARPOS (*it) >= XSTRING (it->string)->size)
            next_overlay_string (it);
        }
        else
--- 4463,4469 ----
        {
          /* IT->string is an overlay string.  Advance to the
             next, if there is one.  */
!         if (IT_STRING_CHARPOS (*it) >= SCHARS (it->string))
            next_overlay_string (it);
        }
        else
***************
*** 4474,4480 ****
             its end, and there is something on IT->stack, proceed
             with what is on the stack.  This can be either another
             string, this time an overlay string, or a buffer.  */
!         if (IT_STRING_CHARPOS (*it) == XSTRING (it->string)->size
              && it->sp > 0)
            {
              pop_it (it);
--- 4472,4478 ----
             its end, and there is something on IT->stack, proceed
             with what is on the stack.  This can be either another
             string, this time an overlay string, or a buffer.  */
!         if (IT_STRING_CHARPOS (*it) == SCHARS (it->string)
              && it->sp > 0)
            {
              pop_it (it);
***************
*** 4592,4613 ****
        /* Get the next character from an overlay string.  In overlay
         strings, There is no field width or padding with spaces to
         do.  */
!       if (IT_STRING_CHARPOS (*it) >= XSTRING (it->string)->size)
        {
          it->what = IT_EOB;
          return 0;
        }
        else if (STRING_MULTIBYTE (it->string))
        {
!         int remaining = (STRING_BYTES (XSTRING (it->string))
!                          - IT_STRING_BYTEPOS (*it));
!         unsigned char *s = (XSTRING (it->string)->data
!                             + IT_STRING_BYTEPOS (*it));
          it->c = string_char_and_length (s, remaining, &it->len);
        }
        else
        {
!         it->c = XSTRING (it->string)->data[IT_STRING_BYTEPOS (*it)];
          it->len = 1;
        }
      }
--- 4590,4609 ----
        /* Get the next character from an overlay string.  In overlay
         strings, There is no field width or padding with spaces to
         do.  */
!       if (IT_STRING_CHARPOS (*it) >= SCHARS (it->string))
        {
          it->what = IT_EOB;
          return 0;
        }
        else if (STRING_MULTIBYTE (it->string))
        {
!         int remaining = SBYTES (it->string) - IT_STRING_BYTEPOS (*it);
!         unsigned char *s = SDATA (it->string) + IT_STRING_BYTEPOS (*it);
          it->c = string_char_and_length (s, remaining, &it->len);
        }
        else
        {
!         it->c = SREF (it->string, IT_STRING_BYTEPOS (*it));
          it->len = 1;
        }
      }
***************
*** 4630,4644 ****
        }
        else if (STRING_MULTIBYTE (it->string))
        {
!         int maxlen = (STRING_BYTES (XSTRING (it->string))
!                       - IT_STRING_BYTEPOS (*it));
!         unsigned char *s = (XSTRING (it->string)->data
!                             + IT_STRING_BYTEPOS (*it));
          it->c = string_char_and_length (s, maxlen, &it->len);
        }
        else
        {
!         it->c = XSTRING (it->string)->data[IT_STRING_BYTEPOS (*it)];
          it->len = 1;
        }
      }
--- 4626,4638 ----
        }
        else if (STRING_MULTIBYTE (it->string))
        {
!         int maxlen = SBYTES (it->string) - IT_STRING_BYTEPOS (*it);
!         unsigned char *s = SDATA (it->string) + IT_STRING_BYTEPOS (*it);
          it->c = string_char_and_length (s, maxlen, &it->len);
        }
        else
        {
!         it->c = SREF (it->string, IT_STRING_BYTEPOS (*it));
          it->len = 1;
        }
      }
***************
*** 5603,5611 ****
    args[2] = arg2;
    msg = Fformat (3, args);
  
!   len = STRING_BYTES (XSTRING (msg)) + 1;
    buffer = (char *) alloca (len);
!   bcopy (XSTRING (msg)->data, buffer, len);
    
    message_dolog (buffer, len - 1, 1, 0);
    UNGCPRO;
--- 5597,5605 ----
    args[2] = arg2;
    msg = Fformat (3, args);
  
!   len = SBYTES (msg) + 1;
    buffer = (char *) alloca (len);
!   bcopy (SDATA (msg), buffer, len);
    
    message_dolog (buffer, len - 1, 1, 0);
    UNGCPRO;
***************
*** 5930,5936 ****
    /* First flush out any partial line written with print.  */
    message_log_maybe_newline ();
    if (STRINGP (m))
!     message_dolog (XSTRING (m)->data, nbytes, 1, multibyte);
    message3_nolog (m, nbytes, multibyte);
  
    UNGCPRO;
--- 5924,5930 ----
    /* First flush out any partial line written with print.  */
    message_log_maybe_newline ();
    if (STRINGP (m))
!     message_dolog (SDATA (m), nbytes, 1, multibyte);
    message3_nolog (m, nbytes, multibyte);
  
    UNGCPRO;
***************
*** 5953,5959 ****
        putc ('\n', stderr);
        noninteractive_need_newline = 0;
        if (STRINGP (m))
!       fwrite (XSTRING (m)->data, nbytes, 1, stderr);
        if (cursor_in_echo_area == 0)
        fprintf (stderr, "\n");
        fflush (stderr);
--- 5947,5953 ----
        putc ('\n', stderr);
        noninteractive_need_newline = 0;
        if (STRINGP (m))
!       fwrite (SDATA (m), nbytes, 1, stderr);
        if (cursor_in_echo_area == 0)
        fprintf (stderr, "\n");
        fflush (stderr);
***************
*** 5980,5986 ****
          && !FRAME_VISIBLE_P (f))
        Fmake_frame_visible (frame);
  
!       if (STRINGP (m) && XSTRING (m)->size)
        {
          set_message (NULL, m, nbytes, multibyte);
          if (minibuffer_auto_raise)
--- 5974,5980 ----
          && !FRAME_VISIBLE_P (f))
        Fmake_frame_visible (frame);
  
!       if (STRINGP (m) && SCHARS (m) > 0)
        {
          set_message (NULL, m, nbytes, multibyte);
          if (minibuffer_auto_raise)
***************
*** 6039,6045 ****
          if (noninteractive_need_newline)
            putc ('\n', stderr);
          noninteractive_need_newline = 0;
!         fprintf (stderr, m, XSTRING (string)->data);
          if (cursor_in_echo_area == 0)
            fprintf (stderr, "\n");
          fflush (stderr);
--- 6033,6039 ----
          if (noninteractive_need_newline)
            putc ('\n', stderr);
          noninteractive_need_newline = 0;
!         fprintf (stderr, m, SDATA (string));
          if (cursor_in_echo_area == 0)
            fprintf (stderr, "\n");
          fflush (stderr);
***************
*** 6074,6084 ****
          message = Fformat (2, args);
  
          if (log)
!           message3 (message, STRING_BYTES (XSTRING (message)),
!                     STRING_MULTIBYTE (message));
          else
!           message3_nolog (message, STRING_BYTES (XSTRING (message)),
!                           STRING_MULTIBYTE (message));
  
          UNGCPRO;
  
--- 6068,6076 ----
          message = Fformat (2, args);
  
          if (log)
!           message3 (message, SBYTES (message), SMBP (message));
          else
!           message3_nolog (message, SBYTES (message), SMBP (message));
  
          UNGCPRO;
  
***************
*** 6187,6193 ****
      {
        Lisp_Object string;
        string = Fcurrent_message ();
!       message3 (string, XSTRING (string)->size, 
                !NILP (current_buffer->enable_multibyte_characters));
      }
  }
--- 6179,6185 ----
      {
        Lisp_Object string;
        string = Fcurrent_message ();
!       message3 (string, SBYTES (string), 
                !NILP (current_buffer->enable_multibyte_characters));
      }
  }
***************
*** 6797,6803 ****
    xassert (CONSP (Vmessage_stack));
    msg = XCAR (Vmessage_stack);
    if (STRINGP (msg))
!     message3_nolog (msg, STRING_BYTES (XSTRING (msg)), STRING_MULTIBYTE 
(msg));
    else
      message3_nolog (msg, 0, 0);
  }
--- 6789,6795 ----
    xassert (CONSP (Vmessage_stack));
    msg = XCAR (Vmessage_stack);
    if (STRINGP (msg))
!     message3_nolog (msg, SBYTES (msg), SMBP (msg));
    else
      message3_nolog (msg, 0, 0);
  }
***************
*** 6923,6929 ****
        int nchars;
        
        if (nbytes == 0)
!       nbytes = XSTRING (string)->size_byte;
        nchars = string_byte_to_char (string, nbytes);
        
        /* This function takes care of single/multibyte conversion.  We
--- 6915,6921 ----
        int nchars;
        
        if (nbytes == 0)
!       nbytes = SBYTES (string);
        nchars = string_byte_to_char (string, nbytes);
        
        /* This function takes care of single/multibyte conversion.  We
***************
*** 7272,7279 ****
         display_mode_element, then we might need to optimize at a
         higher level than this.)  */
        if (! STRINGP (f->name) 
!         || STRING_BYTES (XSTRING (f->name)) != len
!         || bcmp (frame_title_buf, XSTRING (f->name)->data, len) != 0)
        x_implicitly_set_name (f, make_string (frame_title_buf, len), Qnil);
      }
  }
--- 7264,7271 ----
         display_mode_element, then we might need to optimize at a
         higher level than this.)  */
        if (! STRINGP (f->name) 
!         || SBYTES (f->name) != len
!         || bcmp (frame_title_buf, SDATA (f->name), len) != 0)
        x_implicitly_set_name (f, make_string (frame_title_buf, len), Qnil);
      }
  }
***************
*** 7592,7598 ****
    
    /* The size of the string we might be able to reuse.  */
    size = (STRINGP (f->desired_tool_bar_string)
!         ? XSTRING (f->desired_tool_bar_string)->size
          : 0);
  
    /* We need one space in the string for each image.  */
--- 7584,7590 ----
    
    /* The size of the string we might be able to reuse.  */
    size = (STRINGP (f->desired_tool_bar_string)
!         ? SCHARS (f->desired_tool_bar_string)
          : 0);
  
    /* We need one space in the string for each image.  */
***************
*** 7724,7730 ****
           string.  The string can be longer than needed when we reuse a
           previous string.  */
        if (i + 1 == f->n_tool_bar_items)
!       end = XSTRING (f->desired_tool_bar_string)->size;
        else
        end = i + 1;
        Fadd_text_properties (make_number (i), make_number (end),
--- 7716,7722 ----
           string.  The string can be longer than needed when we reuse a
           previous string.  */
        if (i + 1 == f->n_tool_bar_items)
!       end = SCHARS (f->desired_tool_bar_string);
        else
        end = i + 1;
        Fadd_text_properties (make_number (i), make_number (end),
***************
*** 7988,7994 ****
    /* This function can be called asynchronously, which means we must
       exclude any possibility that Fget_text_property signals an
       error.  */
!   charpos = min (XSTRING (f->current_tool_bar_string)->size, glyph->charpos);
    charpos = max (0, charpos);
    
    /* Get the text property `menu-item' at pos. The value of that
--- 7980,7986 ----
    /* This function can be called asynchronously, which means we must
       exclude any possibility that Fget_text_property signals an
       error.  */
!   charpos = min (SCHARS (f->current_tool_bar_string), glyph->charpos);
    charpos = max (0, charpos);
    
    /* Get the text property `menu-item' at pos. The value of that
***************
*** 8243,8249 ****
             w,
             ((BUFFERP (w->buffer)
               && STRINGP (XBUFFER (w->buffer)->name))
!             ? (char *) XSTRING (XBUFFER (w->buffer)->name)->data
              : "no buffer"),
             buffer);
  }
--- 8235,8241 ----
             w,
             ((BUFFERP (w->buffer)
               && STRINGP (XBUFFER (w->buffer)->name))
!             ? (char *) SDATA (XBUFFER (w->buffer)->name)
              : "no buffer"),
             buffer);
  }
***************
*** 12393,12399 ****
       Lisp_Object *args;
  {
    Lisp_Object s = Fformat (nargs, args);
!   fprintf (stderr, "%s", XSTRING (s)->data);
    return Qnil;
  }
        
--- 12385,12391 ----
       Lisp_Object *args;
  {
    Lisp_Object s = Fformat (nargs, args);
!   fprintf (stderr, "%s", SDATA (s));
    return Qnil;
  }
        
***************
*** 12415,12422 ****
    struct frame *f = XFRAME (WINDOW_FRAME (w));
    struct buffer *buffer = XBUFFER (w->buffer);
    struct buffer *old = current_buffer;
!   unsigned char *arrow_string = XSTRING (Voverlay_arrow_string)->data;
!   int arrow_len = XSTRING (Voverlay_arrow_string)->size;
    unsigned char *arrow_end = arrow_string + arrow_len;
    unsigned char *p;
    struct it it;
--- 12407,12414 ----
    struct frame *f = XFRAME (WINDOW_FRAME (w));
    struct buffer *buffer = XBUFFER (w->buffer);
    struct buffer *old = current_buffer;
!   unsigned char *arrow_string = SDATA (Voverlay_arrow_string);
!   int arrow_len = SCHARS (Voverlay_arrow_string);
    unsigned char *arrow_end = arrow_string + arrow_len;
    unsigned char *p;
    struct it it;
***************
*** 13388,13394 ****
        /* Display the item, pad with one space.  */
        if (it.current_x < it.last_visible_x)
        display_string (NULL, string, Qnil, 0, 0, &it,
!                       XSTRING (string)->size + 1, 0, 0, -1);
      }
  
    /* Fill out the line with spaces.  */
--- 13380,13386 ----
        /* Display the item, pad with one space.  */
        if (it.current_x < it.last_visible_x)
        display_string (NULL, string, Qnil, 0, 0, &it,
!                       SCHARS (string) + 1, 0, 0, -1);
      }
  
    /* Fill out the line with spaces.  */
***************
*** 13644,13657 ****
              }
          }
  
!       this = XSTRING (elt)->data;
        lisp_string = this;
  
        if (literal)
          {
            prec = precision - n;
            if (frame_title_ptr)
!             n += store_frame_title (XSTRING (elt)->data, -1, prec);
            else
              n += display_string (NULL, elt, Qnil, 0, 0, it,
                                   0, prec, 0, STRING_MULTIBYTE (elt));
--- 13636,13649 ----
              }
          }
  
!       this = SDATA (elt);
        lisp_string = this;
  
        if (literal)
          {
            prec = precision - n;
            if (frame_title_ptr)
!             n += store_frame_title (SDATA (elt), -1, prec);
            else
              n += display_string (NULL, elt, Qnil, 0, 0, it,
                                   0, prec, 0, STRING_MULTIBYTE (elt));
***************
*** 14016,14023 ****
        /* Mention the EOL conversion if it is not the usual one.  */
        if (STRINGP (eoltype))
        {
!         eol_str = XSTRING (eoltype)->data;
!         eol_str_len = XSTRING (eoltype)->size;
        }
        else if (INTEGERP (eoltype)
               && CHAR_VALID_P (XINT (eoltype), 0))
--- 14008,14015 ----
        /* Mention the EOL conversion if it is not the usual one.  */
        if (STRINGP (eoltype))
        {
!         eol_str = SDATA (eoltype);
!         eol_str_len = SBYTES (eoltype);
        }
        else if (INTEGERP (eoltype)
               && CHAR_VALID_P (XINT (eoltype), 0))
***************
*** 14146,14154 ****
      case 'F':
        /* %F displays the frame name.  */
        if (!NILP (f->title))
!       return (char *) XSTRING (f->title)->data;
        if (f->explicit_name || ! FRAME_WINDOW_P (f))
!       return (char *) XSTRING (f->name)->data;
        return "Emacs";
  
      case 'f': 
--- 14138,14146 ----
      case 'F':
        /* %F displays the frame name.  */
        if (!NILP (f->title))
!       return (char *) SDATA (f->title);
        if (f->explicit_name || ! FRAME_WINDOW_P (f))
!       return (char *) SDATA (f->name);
        return "Emacs";
  
      case 'f': 
***************
*** 14394,14400 ****
    if (STRINGP (obj))
      {
        *multibyte = STRING_MULTIBYTE (obj);
!       return (char *) XSTRING (obj)->data;
      }
    else
      return "";
--- 14386,14392 ----
    if (STRINGP (obj))
      {
        *multibyte = STRING_MULTIBYTE (obj);
!       return (char *) SDATA (obj);
      }
    else
      return "";



reply via email to

[Prev in Thread] Current Thread [Next in Thread]