Support character-spacing in span tag 16/272016/6
authorssabah <s.sabah@samsung.com>
Sun, 6 Mar 2022 11:04:49 +0000 (14:04 +0300)
committerssabah <s.sabah@samsung.com>
Sun, 27 Mar 2022 11:01:47 +0000 (14:01 +0300)
commitc49e595f12e9e56cd7c35262eb52ae1f2d9b685b
tree7073c9b6d7d7df8293ad0c6dce1d16dcb3f825c7
parent1d6351bc6c29b125b71b266f4a8d0f25413e099d
Support character-spacing in span tag

Add Character-Spacing value attribute "char-space-value" to span tag.

How to apply it in TextEditor:

   textEditor.SetProperty(Dali::Toolkit::TextEditor::Property::TEXT,
                           "<span font-size='20' font-family='DejaVu Sans' font-width='condensed' font-slant='italic' text-color='blue' >ABC EF\n</span>"
                           "<span font-size='20' font-family='DejaVu Sans' font-width='condensed' font-slant='italic' text-color='red' char-space-value='-5.0f'>ABC EF\n</span>"
                           "<span font-size='20' font-family='DejaVu Sans' font-width='condensed' font-slant='italic' text-color='green' char-space-value='10.0f'>ABC EF\n</span>");
   textEditor.SetProperty(Dali::Toolkit::TextEditor::Property::ENABLE_MARKUP, true);

This patch should be preceded by the patch below:
https://review.tizen.org/gerrit/c/platform/core/uifw/dali-toolkit/+/271789

Change-Id: I203c6e1f3a116ae557ffbc84859a121739e6b6c6
automated-tests/src/dali-toolkit-internal/utc-Dali-TextEditor-internal.cpp
automated-tests/src/dali-toolkit-internal/utc-Dali-TextField-internal.cpp
automated-tests/src/dali-toolkit-internal/utc-Dali-TextLabel-internal.cpp
dali-toolkit/internal/text/markup-processor-span.cpp
dali-toolkit/internal/text/markup-processor-span.h
dali-toolkit/internal/text/markup-processor.cpp