From c9f951344fa04781f7129da844d09d17b23da21d Mon Sep 17 00:00:00 2001 From: fvogel Date: Wed, 3 Dec 2014 06:44:13 +0000 Subject: Fixed indentation and typos in comments --- generic/tkTextDisp.c | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/generic/tkTextDisp.c b/generic/tkTextDisp.c index e6991da..c3ea9e0 100644 --- a/generic/tkTextDisp.c +++ b/generic/tkTextDisp.c @@ -6446,8 +6446,6 @@ FindDLine( < TkBTreeLinesTo(NULL, dlPtr->index.linePtr)) { /* * The first display line is already past the desired line. - * FV: Some concern here as to whether we should rather return - * NULL here. */ return dlPtr; @@ -6456,7 +6454,7 @@ FindDLine( /* * The display line containing the desired index is such that the index * of the first character of this display line is at or before the - * desired index, and the index onf the first character of the next + * desired index, and the index of the first character of the next * display line is after the desired index. */ @@ -6464,24 +6462,24 @@ FindDLine( dlPtrPrev = dlPtr; dlPtr = dlPtr->nextPtr; if (dlPtr == NULL) { - /* - * We're past the last display line, either because the desired - * index lies past the visible text, or because the desired index - * is on the last display line showing the last logical line. - */ - indexPtr2 = dlPtrPrev->index; - TkTextFindDisplayLineEnd(textPtr, &indexPtr2, 1, NULL); - if (TkTextIndexCmp(&indexPtr2,indexPtr) >= 0) { - dlPtr = dlPtrPrev; - break; - } else { - return NULL; - } - } + /* + * We're past the last display line, either because the desired + * index lies past the visible text, or because the desired index + * is on the last display line showing the last logical line. + */ + indexPtr2 = dlPtrPrev->index; + TkTextFindDisplayLineEnd(textPtr, &indexPtr2, 1, NULL); + if (TkTextIndexCmp(&indexPtr2,indexPtr) >= 0) { + dlPtr = dlPtrPrev; + break; + } else { + return NULL; + } + } if (TkTextIndexCmp(&dlPtr->index,indexPtr) > 0) { dlPtr = dlPtrPrev; break; - } + } } return dlPtr; -- cgit v0.12