aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard M. Stallman1998-04-29 01:00:01 +0000
committerRichard M. Stallman1998-04-29 01:00:01 +0000
commitc86212b98bbe9ecd358899cb4b136b3133dbcc5b (patch)
tree9043b7981520137fa276aff0539c9b3f279afaae /src
parenteb4b1c0532841994f680d74c8b59359c7cf2ed88 (diff)
downloademacs-c86212b98bbe9ecd358899cb4b136b3133dbcc5b.tar.gz
emacs-c86212b98bbe9ecd358899cb4b136b3133dbcc5b.zip
(Fgap_position, Fgap_size): New functions.
(syms_of_editfns): defsubr them.
Diffstat (limited to 'src')
-rw-r--r--src/editfns.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/editfns.c b/src/editfns.c
index 32224866a5c..b3e744b3477 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -469,6 +469,26 @@ is in effect, in which case it is less.")
469 return buildmark (ZV, ZV_BYTE); 469 return buildmark (ZV, ZV_BYTE);
470} 470}
471 471
472DEFUN ("gap-position", Fgap_position, Sgap_position, 0, 0, 0,
473 "Return the position of the gap, in the current buffer.\n\
474See also `gap-size'.")
475 ()
476{
477 Lisp_Object temp;
478 XSETFASTINT (temp, GPT);
479 return temp;
480}
481
482DEFUN ("gap-size", Fgap_size, Sgap_size, 0, 0, 0,
483 "Return the size of the current buffer's gap.\n\
484See also `gap-position'.")
485 ()
486{
487 Lisp_Object temp;
488 XSETFASTINT (temp, GAP_SIZE);
489 return temp;
490}
491
472DEFUN ("position-bytes", Fposition_bytes, Sposition_bytes, 1, 1, 0, 492DEFUN ("position-bytes", Fposition_bytes, Sposition_bytes, 1, 1, 0,
473 "Return the byte position for character position POSITION.") 493 "Return the byte position for character position POSITION.")
474 (position) 494 (position)
@@ -3074,6 +3094,8 @@ functions if all the text being accessed has this property.");
3074 defsubr (&Spoint_min); 3094 defsubr (&Spoint_min);
3075 defsubr (&Spoint_min_marker); 3095 defsubr (&Spoint_min_marker);
3076 defsubr (&Spoint_max_marker); 3096 defsubr (&Spoint_max_marker);
3097 defsubr (&Sgap_position);
3098 defsubr (&Sgap_size);
3077 defsubr (&Sposition_bytes); 3099 defsubr (&Sposition_bytes);
3078 3100
3079 defsubr (&Sbobp); 3101 defsubr (&Sbobp);