Merge "fix incorrect selection highlight position with postive line spacing" into...
authorBowon Ryu <bowon.ryu@samsung.com>
Mon, 25 Apr 2022 05:56:04 +0000 (05:56 +0000)
committerGerrit Code Review <gerrit@review>
Mon, 25 Apr 2022 05:56:04 +0000 (05:56 +0000)
dali-toolkit/internal/text/text-selection-handle-controller.cpp

index 05d8ad5..e4bf91c 100644 (file)
@@ -286,12 +286,7 @@ void SelectionHandleController::Reposition(Controller::Impl& impl)
         selectionBoxInfo->maxX = MIN_FLOAT;
 
         // Update the line's vertical offset.
-        selectionBoxInfo->lineOffset = currentLineOffset + currentLineHeight;
-
-        if(currentLineSpacing < 0)
-        {
-          selectionBoxInfo->lineOffset += currentLineSpacing;
-        }
+        selectionBoxInfo->lineOffset = currentLineOffset + currentLineHeight + currentLineSpacing;
 
         // The line height is the addition of the line ascender and the line descender.
         // However, the line descender has a negative value, hence the subtraction also line spacing should not be included in selection height.