428
+ − 1 /* Simple built-in editing commands.
+ − 2 Copyright (C) 1985, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
826
+ − 3 Copyright (C) 2002 Ben Wing.
428
+ − 4
+ − 5 This file is part of XEmacs.
+ − 6
+ − 7 XEmacs is free software; you can redistribute it and/or modify it
+ − 8 under the terms of the GNU General Public License as published by the
+ − 9 Free Software Foundation; either version 2, or (at your option) any
+ − 10 later version.
+ − 11
+ − 12 XEmacs is distributed in the hope that it will be useful, but WITHOUT
+ − 13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ − 14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ − 15 for more details.
+ − 16
+ − 17 You should have received a copy of the GNU General Public License
+ − 18 along with XEmacs; see the file COPYING. If not, write to
+ − 19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ − 20 Boston, MA 02111-1307, USA. */
+ − 21
+ − 22 /* Synched up with: Mule 2.0, FSF 19.30. */
+ − 23
+ − 24 #include <config.h>
+ − 25 #include "lisp.h"
+ − 26 #include "commands.h"
+ − 27 #include "buffer.h"
872
+ − 28 #include "extents.h"
428
+ − 29 #include "syntax.h"
+ − 30 #include "insdel.h"
+ − 31
+ − 32 Lisp_Object Qkill_forward_chars;
+ − 33 Lisp_Object Qself_insert_command;
+ − 34 Lisp_Object Qno_self_insert;
+ − 35
+ − 36 Lisp_Object Vblink_paren_function;
+ − 37
+ − 38 /* A possible value for a buffer's overwrite-mode variable. */
+ − 39 Lisp_Object Qoverwrite_mode_binary;
+ − 40
+ − 41 /* Non-nil means put this face on the next self-inserting character. */
+ − 42 Lisp_Object Vself_insert_face;
+ − 43
+ − 44 /* This is the command that set up Vself_insert_face. */
+ − 45 Lisp_Object Vself_insert_face_command;
442
+ − 46
+ − 47 /* A char-table for characters which may invoke auto-filling. */
+ − 48 Lisp_Object Vauto_fill_chars;
428
+ − 49
+ − 50 DEFUN ("forward-char", Fforward_char, 0, 2, "_p", /*
444
+ − 51 Move point right COUNT characters (left if COUNT is negative).
428
+ − 52 On attempt to pass end of buffer, stop and signal `end-of-buffer'.
+ − 53 On attempt to pass beginning of buffer, stop and signal `beginning-of-buffer'.
+ − 54 On reaching end of buffer, stop and signal error.
462
+ − 55
+ − 56 The characters that are moved over may be added to the current selection
+ − 57 \(i.e. active region) if the Shift key is held down, a motion key is used
+ − 58 to invoke this command, and `shifted-motion-keys-select-region' is t; see
+ − 59 the documentation for this variable for more details.
428
+ − 60 */
444
+ − 61 (count, buffer))
428
+ − 62 {
+ − 63 struct buffer *buf = decode_buffer (buffer, 1);
444
+ − 64 EMACS_INT n;
428
+ − 65
444
+ − 66 if (NILP (count))
+ − 67 n = 1;
428
+ − 68 else
+ − 69 {
444
+ − 70 CHECK_INT (count);
+ − 71 n = XINT (count);
428
+ − 72 }
+ − 73
444
+ − 74 /* This used to just set point to point + XINT (count), and then check
428
+ − 75 to see if it was within boundaries. But now that SET_PT can
+ − 76 potentially do a lot of stuff (calling entering and exiting
+ − 77 hooks, etcetera), that's not a good approach. So we validate the
+ − 78 proposed position, then set point. */
+ − 79 {
665
+ − 80 Charbpos new_point = BUF_PT (buf) + n;
428
+ − 81
+ − 82 if (new_point < BUF_BEGV (buf))
+ − 83 {
+ − 84 BUF_SET_PT (buf, BUF_BEGV (buf));
+ − 85 Fsignal (Qbeginning_of_buffer, Qnil);
+ − 86 return Qnil;
+ − 87 }
+ − 88 if (new_point > BUF_ZV (buf))
+ − 89 {
+ − 90 BUF_SET_PT (buf, BUF_ZV (buf));
+ − 91 Fsignal (Qend_of_buffer, Qnil);
+ − 92 return Qnil;
+ − 93 }
+ − 94
+ − 95 BUF_SET_PT (buf, new_point);
+ − 96 }
+ − 97
+ − 98 return Qnil;
+ − 99 }
+ − 100
+ − 101 DEFUN ("backward-char", Fbackward_char, 0, 2, "_p", /*
444
+ − 102 Move point left COUNT characters (right if COUNT is negative).
428
+ − 103 On attempt to pass end of buffer, stop and signal `end-of-buffer'.
+ − 104 On attempt to pass beginning of buffer, stop and signal `beginning-of-buffer'.
462
+ − 105
+ − 106 The characters that are moved over may be added to the current selection
+ − 107 \(i.e. active region) if the Shift key is held down, a motion key is used
+ − 108 to invoke this command, and `shifted-motion-keys-select-region' is t; see
+ − 109 the documentation for this variable for more details.
428
+ − 110 */
444
+ − 111 (count, buffer))
428
+ − 112 {
444
+ − 113 if (NILP (count))
+ − 114 count = make_int (-1);
428
+ − 115 else
+ − 116 {
444
+ − 117 CHECK_INT (count);
+ − 118 count = make_int (- XINT (count));
428
+ − 119 }
444
+ − 120 return Fforward_char (count, buffer);
428
+ − 121 }
+ − 122
+ − 123 DEFUN ("forward-line", Fforward_line, 0, 2, "_p", /*
444
+ − 124 Move COUNT lines forward (backward if COUNT is negative).
+ − 125 Precisely, if point is on line I, move to the start of line I + COUNT.
428
+ − 126 If there isn't room, go as far as possible (no error).
+ − 127 Returns the count of lines left to move. If moving forward,
444
+ − 128 that is COUNT - number of lines moved; if backward, COUNT + number moved.
+ − 129 With positive COUNT, a non-empty line at the end counts as one line
428
+ − 130 successfully moved (for the return value).
+ − 131 If BUFFER is nil, the current buffer is assumed.
462
+ − 132
+ − 133 The characters that are moved over may be added to the current selection
+ − 134 \(i.e. active region) if the Shift key is held down, a motion key is used
+ − 135 to invoke this command, and `shifted-motion-keys-select-region' is t; see
+ − 136 the documentation for this variable for more details.
428
+ − 137 */
444
+ − 138 (count, buffer))
428
+ − 139 {
+ − 140 struct buffer *buf = decode_buffer (buffer, 1);
665
+ − 141 Charbpos pos2 = BUF_PT (buf);
+ − 142 Charbpos pos;
444
+ − 143 EMACS_INT n, shortage, negp;
428
+ − 144
444
+ − 145 if (NILP (count))
+ − 146 n = 1;
428
+ − 147 else
+ − 148 {
444
+ − 149 CHECK_INT (count);
+ − 150 n = XINT (count);
428
+ − 151 }
+ − 152
444
+ − 153 negp = n <= 0;
+ − 154 pos = scan_buffer (buf, '\n', pos2, 0, n - negp, &shortage, 1);
428
+ − 155 if (shortage > 0
+ − 156 && (negp
+ − 157 || (BUF_ZV (buf) > BUF_BEGV (buf)
+ − 158 && pos != pos2
+ − 159 && BUF_FETCH_CHAR (buf, pos - 1) != '\n')))
+ − 160 shortage--;
+ − 161 BUF_SET_PT (buf, pos);
+ − 162 return make_int (negp ? - shortage : shortage);
+ − 163 }
+ − 164
+ − 165 DEFUN ("point-at-bol", Fpoint_at_bol, 0, 2, 0, /*
+ − 166 Return the character position of the first character on the current line.
444
+ − 167 With argument COUNT not nil or 1, move forward COUNT - 1 lines first.
428
+ − 168 If scan reaches end of buffer, return that position.
+ − 169 This function does not move point.
+ − 170 */
444
+ − 171 (count, buffer))
428
+ − 172 {
+ − 173 struct buffer *b = decode_buffer (buffer, 1);
+ − 174 REGISTER int orig, end;
+ − 175
793
+ − 176 buffer = wrap_buffer (b);
444
+ − 177 if (NILP (count))
+ − 178 count = make_int (0);
428
+ − 179 else
+ − 180 {
444
+ − 181 CHECK_INT (count);
+ − 182 count = make_int (XINT (count) - 1);
428
+ − 183 }
+ − 184
+ − 185 orig = BUF_PT (b);
444
+ − 186 Fforward_line (count, buffer);
428
+ − 187 end = BUF_PT (b);
+ − 188 BUF_SET_PT (b, orig);
+ − 189
+ − 190 return make_int (end);
+ − 191 }
+ − 192
+ − 193 DEFUN ("beginning-of-line", Fbeginning_of_line, 0, 2, "_p", /*
+ − 194 Move point to beginning of current line.
444
+ − 195 With argument COUNT not nil or 1, move forward COUNT - 1 lines first.
428
+ − 196 If scan reaches end of buffer, stop there without error.
+ − 197 If BUFFER is nil, the current buffer is assumed.
462
+ − 198
+ − 199 The characters that are moved over may be added to the current selection
+ − 200 \(i.e. active region) if the Shift key is held down, a motion key is used
+ − 201 to invoke this command, and `shifted-motion-keys-select-region' is t; see
+ − 202 the documentation for this variable for more details.
428
+ − 203 */
444
+ − 204 (count, buffer))
428
+ − 205 {
+ − 206 struct buffer *b = decode_buffer (buffer, 1);
+ − 207
444
+ − 208 BUF_SET_PT (b, XINT (Fpoint_at_bol (count, buffer)));
428
+ − 209 return Qnil;
+ − 210 }
+ − 211
+ − 212 DEFUN ("point-at-eol", Fpoint_at_eol, 0, 2, 0, /*
+ − 213 Return the character position of the last character on the current line.
444
+ − 214 With argument COUNT not nil or 1, move forward COUNT - 1 lines first.
428
+ − 215 If scan reaches end of buffer, return that position.
+ − 216 This function does not move point.
+ − 217 */
444
+ − 218 (count, buffer))
428
+ − 219 {
+ − 220 struct buffer *buf = decode_buffer (buffer, 1);
446
+ − 221 EMACS_INT n;
428
+ − 222
444
+ − 223 if (NILP (count))
+ − 224 n = 1;
428
+ − 225 else
+ − 226 {
444
+ − 227 CHECK_INT (count);
+ − 228 n = XINT (count);
428
+ − 229 }
+ − 230
+ − 231 return make_int (find_before_next_newline (buf, BUF_PT (buf), 0,
444
+ − 232 n - (n <= 0)));
428
+ − 233 }
+ − 234
+ − 235 DEFUN ("end-of-line", Fend_of_line, 0, 2, "_p", /*
+ − 236 Move point to end of current line.
444
+ − 237 With argument COUNT not nil or 1, move forward COUNT - 1 lines first.
428
+ − 238 If scan reaches end of buffer, stop there without error.
+ − 239 If BUFFER is nil, the current buffer is assumed.
462
+ − 240
+ − 241 The characters that are moved over may be added to the current selection
+ − 242 \(i.e. active region) if the Shift key is held down, a motion key is used
+ − 243 to invoke this command, and `shifted-motion-keys-select-region' is t; see
+ − 244 the documentation for this variable for more details.
428
+ − 245 */
444
+ − 246 (count, buffer))
428
+ − 247 {
+ − 248 struct buffer *b = decode_buffer (buffer, 1);
+ − 249
444
+ − 250 BUF_SET_PT (b, XINT (Fpoint_at_eol (count, buffer)));
428
+ − 251 return Qnil;
+ − 252 }
+ − 253
446
+ − 254 DEFUN ("delete-char", Fdelete_char, 0, 2, "*p\nP", /*
444
+ − 255 Delete the following COUNT characters (previous, with negative COUNT).
+ − 256 Optional second arg KILLP non-nil means kill instead (save in kill ring).
+ − 257 Interactively, COUNT is the prefix arg, and KILLP is set if
+ − 258 COUNT was explicitly specified.
428
+ − 259 */
444
+ − 260 (count, killp))
428
+ − 261 {
+ − 262 /* This function can GC */
665
+ − 263 Charbpos pos;
428
+ − 264 struct buffer *buf = current_buffer;
446
+ − 265 EMACS_INT n;
428
+ − 266
446
+ − 267 if (NILP (count))
+ − 268 n = 1;
+ − 269 else
+ − 270 {
+ − 271 CHECK_INT (count);
+ − 272 n = XINT (count);
+ − 273 }
428
+ − 274
444
+ − 275 pos = BUF_PT (buf) + n;
+ − 276 if (NILP (killp))
428
+ − 277 {
444
+ − 278 if (n < 0)
428
+ − 279 {
+ − 280 if (pos < BUF_BEGV (buf))
563
+ − 281 signal_error (Qbeginning_of_buffer, 0, Qunbound);
428
+ − 282 else
+ − 283 buffer_delete_range (buf, pos, BUF_PT (buf), 0);
+ − 284 }
+ − 285 else
+ − 286 {
+ − 287 if (pos > BUF_ZV (buf))
563
+ − 288 signal_error (Qend_of_buffer, 0, Qunbound);
428
+ − 289 else
+ − 290 buffer_delete_range (buf, BUF_PT (buf), pos, 0);
+ − 291 }
+ − 292 }
+ − 293 else
+ − 294 {
444
+ − 295 call1 (Qkill_forward_chars, count);
428
+ − 296 }
+ − 297 return Qnil;
+ − 298 }
+ − 299
446
+ − 300 DEFUN ("delete-backward-char", Fdelete_backward_char, 0, 2, "*p\nP", /*
444
+ − 301 Delete the previous COUNT characters (following, with negative COUNT).
+ − 302 Optional second arg KILLP non-nil means kill instead (save in kill ring).
+ − 303 Interactively, COUNT is the prefix arg, and KILLP is set if
+ − 304 COUNT was explicitly specified.
428
+ − 305 */
444
+ − 306 (count, killp))
428
+ − 307 {
+ − 308 /* This function can GC */
446
+ − 309 EMACS_INT n;
+ − 310
+ − 311 if (NILP (count))
+ − 312 n = 1;
+ − 313 else
+ − 314 {
+ − 315 CHECK_INT (count);
+ − 316 n = XINT (count);
+ − 317 }
+ − 318
+ − 319 return Fdelete_char (make_int (- n), killp);
428
+ − 320 }
+ − 321
867
+ − 322 static void internal_self_insert (Ichar ch, int noautofill);
428
+ − 323
+ − 324 DEFUN ("self-insert-command", Fself_insert_command, 1, 1, "*p", /*
+ − 325 Insert the character you type.
+ − 326 Whichever character you type to run this command is inserted.
444
+ − 327 If a prefix arg COUNT is specified, the character is inserted COUNT times.
428
+ − 328 */
444
+ − 329 (count))
428
+ − 330 {
+ − 331 /* This function can GC */
867
+ − 332 Ichar ch;
428
+ − 333 Lisp_Object c;
446
+ − 334 EMACS_INT n;
428
+ − 335
444
+ − 336 CHECK_NATNUM (count);
+ − 337 n = XINT (count);
428
+ − 338
+ − 339 if (CHAR_OR_CHAR_INTP (Vlast_command_char))
+ − 340 c = Vlast_command_char;
+ − 341 else
+ − 342 c = Fevent_to_character (Vlast_command_event, Qnil, Qnil, Qt);
+ − 343
+ − 344 if (NILP (c))
563
+ − 345 invalid_operation ("Last typed character has no ASCII equivalent",
+ − 346 Fcopy_event (Vlast_command_event, Qnil));
428
+ − 347
+ − 348 CHECK_CHAR_COERCE_INT (c);
+ − 349
+ − 350 ch = XCHAR (c);
+ − 351
444
+ − 352 while (n--)
+ − 353 internal_self_insert (ch, (n != 0));
428
+ − 354
+ − 355 return Qnil;
+ − 356 }
+ − 357
+ − 358 /* Insert character C1. If NOAUTOFILL is nonzero, don't do autofill
+ − 359 even if it is enabled.
+ − 360
+ − 361 FSF:
+ − 362
+ − 363 If this insertion is suitable for direct output (completely simple),
+ − 364 return 0. A value of 1 indicates this *might* not have been simple.
+ − 365 A value of 2 means this did things that call for an undo boundary. */
+ − 366
+ − 367 static void
867
+ − 368 internal_self_insert (Ichar c1, int noautofill)
428
+ − 369 {
+ − 370 /* This function can GC */
+ − 371 /* int hairy = 0; -- unused */
+ − 372 REGISTER enum syntaxcode synt;
867
+ − 373 REGISTER Ichar c2;
428
+ − 374 Lisp_Object overwrite;
826
+ − 375 Lisp_Object syntax_table;
428
+ − 376 struct buffer *buf = current_buffer;
+ − 377 int tab_width;
+ − 378
+ − 379 overwrite = buf->overwrite_mode;
826
+ − 380 syntax_table = buf->mirror_syntax_table;
428
+ − 381
+ − 382 #if 0
+ − 383 /* No, this is very bad, it makes undo *always* undo a character at a time
+ − 384 instead of grouping consecutive self-inserts together. Nasty nasty.
+ − 385 */
+ − 386 if (!NILP (Vbefore_change_functions) || !NILP (Vafter_change_functions)
+ − 387 || !NILP (Vbefore_change_function) || !NILP (Vafter_change_function))
+ − 388 hairy = 1;
+ − 389 #endif
+ − 390
+ − 391 if (!NILP (overwrite)
+ − 392 && BUF_PT (buf) < BUF_ZV (buf)
+ − 393 && (EQ (overwrite, Qoverwrite_mode_binary)
+ − 394 || (c1 != '\n' && BUF_FETCH_CHAR (buf, BUF_PT (buf)) != '\n'))
+ − 395 && (EQ (overwrite, Qoverwrite_mode_binary)
+ − 396 || BUF_FETCH_CHAR (buf, BUF_PT (buf)) != '\t'
+ − 397 || ((tab_width = XINT (buf->tab_width), tab_width <= 0)
+ − 398 || tab_width > 20
+ − 399 || !((current_column (buf) + 1) % tab_width))))
+ − 400 {
+ − 401 buffer_delete_range (buf, BUF_PT (buf), BUF_PT (buf) + 1, 0);
+ − 402 /* hairy = 2; */
+ − 403 }
+ − 404
+ − 405 if (!NILP (buf->abbrev_mode)
+ − 406 && !WORD_SYNTAX_P (syntax_table, c1)
+ − 407 && NILP (buf->read_only)
+ − 408 && BUF_PT (buf) > BUF_BEGV (buf))
+ − 409 {
+ − 410 c2 = BUF_FETCH_CHAR (buf, BUF_PT (buf) - 1);
+ − 411
+ − 412 if (WORD_SYNTAX_P (syntax_table, c2))
+ − 413 {
+ − 414 #if 1
+ − 415 Fexpand_abbrev ();
+ − 416 #else /* FSFmacs */
+ − 417 Lisp_Object sym = Fexpand_abbrev ();
+ − 418
+ − 419 /* I think this is too bogus to add. The function should
+ − 420 have a way of examining the character to be inserted, so
+ − 421 it can decide whether to insert it or not. We should
+ − 422 design it better than that. */
+ − 423
+ − 424 /* Here FSFmacs remembers MODIFF, compares it after
+ − 425 Fexpand_abbrev() finishes, and updates HAIRY. */
+ − 426
+ − 427 /* NOTE: we cannot simply check for Vlast_abbrev, because
+ − 428 Fexpand_abbrev() can bail out before setting it to
+ − 429 anything meaningful, leaving us stuck with an old value.
+ − 430 Thus Fexpand_abbrev() was extended to return the actual
+ − 431 abbrev symbol. */
+ − 432 if (!NILP (sym)
+ − 433 && !NILP (symbol_function (XSYMBOL (sym)))
+ − 434 && SYMBOLP (symbol_function (XSYMBOL (sym))))
+ − 435 {
+ − 436 Lisp_Object prop = Fget (symbol_function (XSYMBOL (sym)),
+ − 437 Qno_self_insert, Qnil);
+ − 438 if (!NILP (prop))
+ − 439 return;
+ − 440 }
+ − 441 #endif /* FSFmacs */
+ − 442 }
+ − 443 }
442
+ − 444 if ((CHAR_TABLEP (Vauto_fill_chars)
826
+ − 445 ? !NILP (get_char_table (c1, Vauto_fill_chars))
442
+ − 446 : (c1 == ' ' || c1 == '\n'))
428
+ − 447 && !noautofill
+ − 448 && !NILP (buf->auto_fill_function))
+ − 449 {
+ − 450 buffer_insert_emacs_char (buf, c1);
+ − 451 if (c1 == '\n')
+ − 452 /* After inserting a newline, move to previous line and fill */
+ − 453 /* that. Must have the newline in place already so filling and */
+ − 454 /* justification, if any, know where the end is going to be. */
+ − 455 BUF_SET_PT (buf, BUF_PT (buf) - 1);
+ − 456 call0 (buf->auto_fill_function);
+ − 457 if (c1 == '\n')
+ − 458 BUF_SET_PT (buf, BUF_PT (buf) + 1);
+ − 459 /* hairy = 2; */
+ − 460 }
+ − 461 else
+ − 462 buffer_insert_emacs_char (buf, c1);
+ − 463
+ − 464 /* If previous command specified a face to use, use it. */
+ − 465 if (!NILP (Vself_insert_face)
+ − 466 && EQ (Vlast_command, Vself_insert_face_command))
+ − 467 {
+ − 468 Lisp_Object before = make_int (BUF_PT (buf) - 1);
+ − 469 Lisp_Object after = make_int (BUF_PT (buf));
+ − 470 Fput_text_property (before, after, Qface, Vself_insert_face, Qnil);
+ − 471 Fput_text_property (before, after, Qstart_open, Qt, Qnil);
+ − 472 Fput_text_property (before, after, Qend_open, Qnil, Qnil);
+ − 473 /* #### FSFmacs properties are normally closed ("sticky") on the
+ − 474 end but not the beginning. It's the opposite for us. */
+ − 475 Vself_insert_face = Qnil;
+ − 476 }
+ − 477 synt = SYNTAX (syntax_table, c1);
+ − 478 if ((synt == Sclose || synt == Smath)
+ − 479 && !NILP (Vblink_paren_function) && INTERACTIVE
+ − 480 && !noautofill)
+ − 481 {
+ − 482 call0 (Vblink_paren_function);
+ − 483 /* hairy = 2; */
+ − 484 }
+ − 485
+ − 486 /* return hairy; */
+ − 487 }
+ − 488
+ − 489 /* (this comes from Mule but is a generally good idea) */
+ − 490
+ − 491 DEFUN ("self-insert-internal", Fself_insert_internal, 1, 1, 0, /*
444
+ − 492 Invoke `self-insert-command' as if CHARACTER is entered from keyboard.
428
+ − 493 */
444
+ − 494 (character))
428
+ − 495 {
+ − 496 /* This function can GC */
444
+ − 497 CHECK_CHAR_COERCE_INT (character);
+ − 498 internal_self_insert (XCHAR (character), 0);
428
+ − 499 return Qnil;
+ − 500 }
+ − 501
+ − 502 /* module initialization */
+ − 503
+ − 504 void
+ − 505 syms_of_cmds (void)
+ − 506 {
563
+ − 507 DEFSYMBOL (Qkill_forward_chars);
+ − 508 DEFSYMBOL (Qself_insert_command);
+ − 509 DEFSYMBOL (Qoverwrite_mode_binary);
+ − 510 DEFSYMBOL (Qno_self_insert);
428
+ − 511
+ − 512 DEFSUBR (Fforward_char);
+ − 513 DEFSUBR (Fbackward_char);
+ − 514 DEFSUBR (Fforward_line);
+ − 515 DEFSUBR (Fbeginning_of_line);
+ − 516 DEFSUBR (Fend_of_line);
+ − 517
+ − 518 DEFSUBR (Fpoint_at_bol);
+ − 519 DEFSUBR (Fpoint_at_eol);
+ − 520
+ − 521 DEFSUBR (Fdelete_char);
+ − 522 DEFSUBR (Fdelete_backward_char);
+ − 523
+ − 524 DEFSUBR (Fself_insert_command);
+ − 525 DEFSUBR (Fself_insert_internal);
+ − 526 }
+ − 527
+ − 528 void
+ − 529 vars_of_cmds (void)
+ − 530 {
+ − 531 DEFVAR_LISP ("self-insert-face", &Vself_insert_face /*
+ − 532 If non-nil, set the face of the next self-inserting character to this.
+ − 533 See also `self-insert-face-command'.
+ − 534 */ );
+ − 535 Vself_insert_face = Qnil;
+ − 536
+ − 537 DEFVAR_LISP ("self-insert-face-command", &Vself_insert_face_command /*
+ − 538 This is the command that set up `self-insert-face'.
+ − 539 If `last-command' does not equal this value, we ignore `self-insert-face'.
+ − 540 */ );
+ − 541 Vself_insert_face_command = Qnil;
+ − 542
+ − 543 DEFVAR_LISP ("blink-paren-function", &Vblink_paren_function /*
+ − 544 Function called, if non-nil, whenever a close parenthesis is inserted.
+ − 545 More precisely, a char with closeparen syntax is self-inserted.
+ − 546 */ );
+ − 547 Vblink_paren_function = Qnil;
442
+ − 548
+ − 549 DEFVAR_LISP ("auto-fill-chars", &Vauto_fill_chars /*
+ − 550 A char-table for characters which invoke auto-filling.
444
+ − 551 Such characters have value t in this table.
442
+ − 552 */);
+ − 553 Vauto_fill_chars = Fmake_char_table (Qgeneric);
+ − 554 XCHAR_TABLE (Vauto_fill_chars)->ascii[' '] = Qt;
+ − 555 XCHAR_TABLE (Vauto_fill_chars)->ascii['\n'] = Qt;
428
+ − 556 }