comparison src/abbrev.c @ 89483:2f877ed80fa6

*** empty log message ***
author Kenichi Handa <handa@m17n.org>
date Mon, 08 Sep 2003 12:53:41 +0000
parents 375f2633d815 98dcb14bf34c
children 68c22ea6027c
comparison
equal deleted inserted replaced
88123:375f2633d815 89483:2f877ed80fa6
25 25
26 #include "lisp.h" 26 #include "lisp.h"
27 #include "commands.h" 27 #include "commands.h"
28 #include "buffer.h" 28 #include "buffer.h"
29 #include "window.h" 29 #include "window.h"
30 #include "charset.h" 30 #include "character.h"
31 #include "syntax.h" 31 #include "syntax.h"
32 32
33 /* An abbrev table is an obarray. 33 /* An abbrev table is an obarray.
34 Each defined abbrev is represented by a symbol in that obarray 34 Each defined abbrev is represented by a symbol in that obarray
35 whose print name is the abbreviation. 35 whose print name is the abbreviation.
383 { 383 {
384 /* Abbrev included some caps. Cap first initial of expansion */ 384 /* Abbrev included some caps. Cap first initial of expansion */
385 int pos = wordstart_byte; 385 int pos = wordstart_byte;
386 386
387 /* Find the initial. */ 387 /* Find the initial. */
388 while (pos < PT_BYTE 388 if (multibyte)
389 && SYNTAX (*BUF_BYTE_ADDRESS (current_buffer, pos)) != Sword) 389 while (pos < PT_BYTE
390 pos++; 390 && SYNTAX (FETCH_MULTIBYTE_CHAR (pos)) != Sword)
391 INC_POS (pos);
392 else
393 while (pos < PT_BYTE
394 && (SYNTAX (*BUF_BYTE_ADDRESS (current_buffer, pos))
395 != Sword))
396 pos++;
391 397
392 /* Change just that. */ 398 /* Change just that. */
393 pos = BYTE_TO_CHAR (pos); 399 pos = BYTE_TO_CHAR (pos);
394 Fupcase_initials_region (make_number (pos), make_number (pos + 1)); 400 Fupcase_initials_region (make_number (pos), make_number (pos + 1));
395 } 401 }