/[emacs]/emacs/src/charset.c
ViewVC logotype

Diff of /emacs/src/charset.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.133 by fx, Thu Nov 14 14:12:30 2002 UTC revision 1.134 by lektu, Tue Feb 4 14:03:12 2003 UTC
# Line 210  char_to_string_1 (c, str) Line 210  char_to_string_1 (c, str)
210        /* If C still has any modifier bits, just ignore it.  */        /* If C still has any modifier bits, just ignore it.  */
211        c &= ~CHAR_MODIFIER_MASK;        c &= ~CHAR_MODIFIER_MASK;
212      }      }
213      
214    if (SINGLE_BYTE_CHAR_P (c))    if (SINGLE_BYTE_CHAR_P (c))
215      {      {
216        if (ASCII_BYTE_P (c) || c >= 0xA0)        if (ASCII_BYTE_P (c) || c >= 0xA0)
# Line 345  char_printable_p (c) Line 345  char_printable_p (c)
345      return 0;      return 0;
346    else if (c >= MAX_CHAR)    else if (c >= MAX_CHAR)
347      return 0;      return 0;
348      
349    SPLIT_CHAR (c, charset, c1, c2);    SPLIT_CHAR (c, charset, c1, c2);
350    if (! CHARSET_DEFINED_P (charset))    if (! CHARSET_DEFINED_P (charset))
351      return 0;      return 0;
# Line 817  find_charset_in_text (ptr, nchars, nbyte Line 817  find_charset_in_text (ptr, nchars, nbyte
817              {              {
818                maskbits |= (*ptr < 0x80 ? 1 : *ptr < 0xA0 ? 2 : 4);                maskbits |= (*ptr < 0x80 ? 1 : *ptr < 0xA0 ? 2 : 4);
819                ptr++;                ptr++;
820              }                      }
821    
822            if (maskbits & 1)            if (maskbits & 1)
823              charsets[CHARSET_ASCII] = 1;              charsets[CHARSET_ASCII] = 1;
# Line 1548  str_as_multibyte (str, len, nbytes, ncha Line 1548  str_as_multibyte (str, len, nbytes, ncha
1548          {          {
1549            while (n--)            while (n--)
1550              *to++ = *p++;              *to++ = *p++;
1551          }                  }
1552        else        else
1553          {          {
1554            *to++ = LEADING_CODE_8_BIT_CONTROL;            *to++ = LEADING_CODE_8_BIT_CONTROL;
# Line 1600  str_to_multibyte (str, len, bytes) Line 1600  str_to_multibyte (str, len, bytes)
1600    endp = str + len;    endp = str + len;
1601    safe_bcopy (p, endp - bytes, bytes);    safe_bcopy (p, endp - bytes, bytes);
1602    p = endp - bytes;    p = endp - bytes;
1603    while (p < endp)          while (p < endp)
1604      {      {
1605        if (*p < 0x80 || *p >= 0xA0)        if (*p < 0x80 || *p >= 0xA0)
1606          *to++ = *p++;          *to++ = *p++;
# Line 1624  str_as_unibyte (str, bytes) Line 1624  str_as_unibyte (str, bytes)
1624    
1625    while (p < endp && *p != LEADING_CODE_8_BIT_CONTROL) p++;    while (p < endp && *p != LEADING_CODE_8_BIT_CONTROL) p++;
1626    to = p;    to = p;
1627    while (p < endp)          while (p < endp)
1628      {      {
1629        if (*p == LEADING_CODE_8_BIT_CONTROL)        if (*p == LEADING_CODE_8_BIT_CONTROL)
1630          *to++ = *(p + 1) - 0x20, p += 2;          *to++ = *(p + 1) - 0x20, p += 2;

Legend:
Removed from v.1.133  
changed lines
  Added in v.1.134

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26