Changeset 2fc8397
- Timestamp:
- Jul 11, 2009, 1:14:36 PM (15 years ago)
- Branches:
- master, release-1.10, release-1.4, release-1.5, release-1.6, release-1.7, release-1.8, release-1.9
- Children:
- 19a023f
- Parents:
- 77f605d
- git-author:
- Nelson Elhage <nelhage@mit.edu> (07/06/09 20:41:51)
- git-committer:
- Nelson Elhage <nelhage@mit.edu> (07/11/09 13:14:36)
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
commands.c
ra60edf2 r2fc8397 938 938 "runs 'editmulti:done'.\n"\ 939 939 "Otherwise runs 'edit:delete-next-char'\n"), 940 941 OWLCMD_VOID_CTX("editmulti:forward-paragraph", owl_editwin_forward_paragraph, 942 OWL_CTX_EDITMULTI, 943 "Move forward to end of paragraph.", 944 "", 945 "Move the point to the end of the current paragraph"), 946 947 OWLCMD_VOID_CTX("editmulti:backward-paragraph", owl_editwin_backward_paragraph, 948 OWL_CTX_EDITMULTI, 949 "Move backward to the start of paragraph.", 950 "", 951 "Move the point to the start of the current paragraph"), 940 952 941 953 /****************************************************************/ -
editwin.c
r77f605d r2fc8397 1050 1050 } 1051 1051 1052 void owl_editwin_backward_paragraph(owl_editwin *e) 1053 { 1054 owl_editwin_point_move(e, -1); 1055 for (; e->index >= e->lock; owl_editwin_point_move(e, -1)) { 1056 if (e->index <= e->lock || 1057 ((e->buff[e->index] == '\n') && (e->buff[e->index - 1]=='\n'))) 1058 break; 1059 } 1060 } 1061 1062 void owl_editwin_forward_paragraph(owl_editwin *e) 1063 { 1064 owl_editwin_point_move(e, 1); 1065 /* scan forward to the start of the next paragraph */ 1066 for(; e->index < e->bufflen; owl_editwin_point_move(e, 1)) { 1067 if (e->buff[e->index -1] == '\n' && e->buff[e->index] == '\n') 1068 break; 1069 } 1070 } 1071 1052 1072 static int oe_display_column(owl_editwin *e) 1053 1073 { -
keys.c
ra60edf2 r2fc8397 109 109 BIND_CMD("M-[ B", "editmulti:move-down-line", ""); 110 110 BIND_CMD("C-n", "editmulti:move-down-line", ""); 111 112 BIND_CMD("M-}", "editmulti:forward-paragraph", ""); 113 BIND_CMD("M-{", "editmulti:backward-paragraph", ""); 111 114 112 115 /* This would be nice, but interferes with C-c to cancel */
Note: See TracChangeset
for help on using the changeset viewer.