summaryrefslogtreecommitdiffstats
path: root/generic/tkTextDisp.c
diff options
context:
space:
mode:
authorfvogelnew1@free.fr <fvogel>2014-12-05 21:32:03 (GMT)
committerfvogelnew1@free.fr <fvogel>2014-12-05 21:32:03 (GMT)
commitcce3fb8c6a4620e773674b6e05b3e7f77fd0e80d (patch)
tree00aa8c6be462e757e654c3963e875878d2345efd /generic/tkTextDisp.c
parent36f4e252427bd066068c162fd7951f10840968bb (diff)
downloadtk-cce3fb8c6a4620e773674b6e05b3e7f77fd0e80d.zip
tk-cce3fb8c6a4620e773674b6e05b3e7f77fd0e80d.tar.gz
tk-cce3fb8c6a4620e773674b6e05b3e7f77fd0e80d.tar.bz2
indexPtr->byteIndex == 0 is the beginning of a display line only if indexPtr is not elided
Diffstat (limited to 'generic/tkTextDisp.c')
-rw-r--r--generic/tkTextDisp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/generic/tkTextDisp.c b/generic/tkTextDisp.c
index 851ee3e..dd4aa31 100644
--- a/generic/tkTextDisp.c
+++ b/generic/tkTextDisp.c
@@ -5033,7 +5033,8 @@ TkTextSetYView(
*/
textPtr->topIndex = *indexPtr;
- if (indexPtr->byteIndex != 0) {
+ if (!(indexPtr->byteIndex == 0
+ && !TkTextIsElided(textPtr, indexPtr, NULL))) {
TkTextFindDisplayLineEnd(textPtr, &textPtr->topIndex, 0, NULL);
}
dInfoPtr->newTopPixelOffset = pickPlace;