Thread View: gnu.emacs.bug
1 messages
1 total messages
Started by Stephen Gildea
Tue, 29 Dec 1992 22:48
want interface to upcase_initials_region
Author: Stephen Gildea
Date: Tue, 29 Dec 1992 22:48
Date: Tue, 29 Dec 1992 22:48
73 lines
2902 bytes
2902 bytes
I just discovered in the Emacs 18.59 sources a function I have
wanted before: upcase_initials_region, which changes the first
letter of each word to uppercase without disturbing the rest of the
word. Unfortunately, this function is not callable from lisp.
Please make upcase_initials_region available. I've appended diffs.
< Stephen
*** src/casefiddle.c-18.59 Fri Jan 4 19:13:58 1991
--- src/casefiddle.c Mon Dec 28 11:12:54 1992
***************
*** 164,171 ****
}
! /* Like Fcapitalize but change only the initials. */
!
! Lisp_Object
! upcase_initials_region (b, e)
Lisp_Object b, e;
{
--- 164,173 ----
}
! DEFUN ("upcase-initials-region", Fupcase_initials_region, Supcase_initials_region, 2, 2, "r",
! "Convert the first letter of every word in the region to upper case.\n\
! In programs, wants two arguments. These arguments specify the starting\n\
! and ending character numbers of the region to operate on. When used as\n\
! a command, the text between point and the mark is operated on.")
! (b, e)
Lisp_Object b, e;
{
***************
*** 237,240 ****
--- 239,243 ----
defsubr (&Sdowncase_region);
defsubr (&Scapitalize_region);
+ defsubr (&Supcase_initials_region);
defsubr (&Supcase_word);
defsubr (&Sdowncase_word);
*** src/abbrev.c-18.59 Mon Aug 12 21:30:41 1991
--- src/abbrev.c Mon Dec 28 11:13:32 1992
***************
*** 284,289 ****
if (scan_words (point, -1) > scan_words (wordstart, 1))
{
! upcase_initials_region (make_number (wordstart),
! make_number (point));
goto caped;
}
--- 284,289 ----
if (scan_words (point, -1) > scan_words (wordstart, 1))
{
! Fupcase_initials_region (make_number (wordstart),
! make_number (point));
goto caped;
}
*** src/search.c-18.59 Tue Oct 8 00:07:38 1991
--- src/search.c Mon Dec 28 11:07:25 1992
***************
*** 1078,1082 ****
Fupcase_region (make_number (point - inslen), make_number (point));
else if (case_action == cap_initial)
! upcase_initials_region (make_number (point - inslen), make_number (point));
return Qnil;
}
--- 1078,1082 ----
Fupcase_region (make_number (point - inslen), make_number (point));
else if (case_action == cap_initial)
! Fupcase_initials_region (make_number (point - inslen), make_number (point));
return Qnil;
}
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads