Mercurial > emacs
comparison src/indent.c @ 83561:dc002877ce12
Merged from emacs@sv.gnu.org
Patches applied:
* emacs@sv.gnu.org/emacs--devo--0--patch-674
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-675
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-676
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-677
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-678
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-679
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-680
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-681
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-682
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-683
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-684
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-685
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-686
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-687
Release ERC 5.2.
* emacs@sv.gnu.org/emacs--devo--0--patch-688
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-689
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-690
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-691
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-692
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-693
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-694
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-695
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-696
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-697
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-698
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-699
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-700
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-701
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-209
Merge from emacs--devo--0
* emacs@sv.gnu.org/gnus--rel--5.10--patch-210
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-211
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-212
Merge from emacs--devo--0
* emacs@sv.gnu.org/gnus--rel--5.10--patch-213
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-214
Merge from emacs--devo--0
* emacs@sv.gnu.org/gnus--rel--5.10--patch-215
Update from CVS
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-601
author | Karoly Lorentey <karoly@lorentey.hu> |
---|---|
date | Sun, 22 Apr 2007 12:42:47 +0000 |
parents | 07774e5c3ff5 50bb3d12f1b1 |
children | 65663fcd2caa |
comparison
equal
deleted
inserted
replaced
83560:738ce3540ffb | 83561:dc002877ce12 |
---|---|
735 | 735 |
736 | 736 |
737 DEFUN ("indent-to", Findent_to, Sindent_to, 1, 2, "NIndent to column: ", | 737 DEFUN ("indent-to", Findent_to, Sindent_to, 1, 2, "NIndent to column: ", |
738 doc: /* Indent from point with tabs and spaces until COLUMN is reached. | 738 doc: /* Indent from point with tabs and spaces until COLUMN is reached. |
739 Optional second argument MINIMUM says always do at least MINIMUM spaces | 739 Optional second argument MINIMUM says always do at least MINIMUM spaces |
740 even if that goes past COLUMN; by default, MINIMUM is zero. */) | 740 even if that goes past COLUMN; by default, MINIMUM is zero. |
741 | |
742 The return value is COLUMN. */) | |
741 (column, minimum) | 743 (column, minimum) |
742 Lisp_Object column, minimum; | 744 Lisp_Object column, minimum; |
743 { | 745 { |
744 int mincol; | 746 int mincol; |
745 register int fromcol; | 747 register int fromcol; |
949 goal = XINT (column); | 951 goal = XINT (column); |
950 | 952 |
951 pos = PT; | 953 pos = PT; |
952 pos_byte = PT_BYTE; | 954 pos_byte = PT_BYTE; |
953 end = ZV; | 955 end = ZV; |
954 next_boundary = pos; | |
955 | 956 |
956 /* If we're starting past the desired column, | 957 /* If we're starting past the desired column, |
957 back up to beginning of line and scan from there. */ | 958 back up to beginning of line and scan from there. */ |
958 if (col > goal) | 959 if (col > goal) |
959 { | 960 { |
960 end = pos; | 961 end = pos; |
961 pos = current_column_bol_cache; | 962 pos = current_column_bol_cache; |
962 pos_byte = CHAR_TO_BYTE (pos); | 963 pos_byte = CHAR_TO_BYTE (pos); |
963 col = 0; | 964 col = 0; |
964 } | 965 } |
966 | |
967 next_boundary = pos; | |
965 | 968 |
966 while (pos < end) | 969 while (pos < end) |
967 { | 970 { |
968 while (pos == next_boundary) | 971 while (pos == next_boundary) |
969 { | 972 { |