Page MenuHomePhabricator

efl_ui_format: fix to display %% and unknown format element

Authored by Jaehyun_Cho on Jan 31 2019, 10:40 PM.



This fixes 2 things as follows.

  1. Displays format string "%%" as "%". Like printf does, "%%" is displayed as "%".
  1. Displays unknown format element as it is. In format string "(50%)", ")" is an unknown format element. Although format string has unknown format element, the format string is displayed like printf does.

The cause of the issue displaying "0%" which was mentioned on
a96933f964b1757b9d9f8a4cce14d883f35a6665 is as follows.

The default format string of progressbar is set as "%.0f%%".
Therefore, if progressbar's format string is not set, then "%" postfix
is always displayed.

This commit reverts commit a96933f964b1757b9d9f8a4cce14d883f35a6665.
This commit restores commit b4112b9735ce75bce95974a257aa1880fa52a6bf.
This commit restores commit be770d37fb05b8486907796dd16f4635bceb4ce1.

Test Plan
  1. Run elementary_test -to progressbar.
  2. Check format string "50 percent (50%)" on the left progressbar.

Diff Detail

rEFL core/efl
No Linters Available
No Unit Test Coverage
Build Status
Buildable 9313
Build 7924: arc lint + arc unit
Jaehyun_Cho created this revision.Jan 31 2019, 10:40 PM
Jaehyun_Cho requested review of this revision.Jan 31 2019, 10:40 PM

fix to display value correctly

cedric accepted this revision.Feb 11 2019, 3:40 PM

This fix the problem, doesn't seems to break anything I can see and make sense.

This revision is now accepted and ready to land.Feb 11 2019, 3:40 PM
This revision was automatically updated to reflect the committed changes.