Giter Site home page Giter Site logo

Comments (12)

Markman-B avatar Markman-B commented on July 24, 2024

I can confirm this issue on Android - Kodi 21 beta 2.

Screenshot_20240130_173653_Gallery

from xbmc.

scott967 avatar scott967 commented on July 24, 2024

"trailing" and "leading" have different connotations if your UI is LTR/RTL

from xbmc.

scott967 avatar scott967 commented on July 24, 2024

screenshot00010

from xbmc.

CastagnaIT avatar CastagnaIT commented on July 24, 2024

i think could be a kind of "side effect" of a my old PR (#22691) to have trailing dots "..." on the left for the right aligned text
that is used for GUI settings that have double text labels (left-description + right-value)
i think that should be added a new parameter to label control to choose the truncation position and so the relative "..." dots position

from xbmc.

CrystalP avatar CrystalP commented on July 24, 2024

The new behavior seems more correct to me, the ellipsis is supposed to be a placeholder for the truncated text, which happens to be to the left, when right-aligning.

from xbmc.

MikeSiLVO avatar MikeSiLVO commented on July 24, 2024

I think it should remain as it always was (LTR).
When looking at a list, in most languages, I'd expect to be able to read the start of the item and not the tail end of it.

I don't want to be exclusionary so maybe there is some way to make the RTL/LTR of the language control this?

Default to (LTR)

Arabic / Aramaic / Azeri / Dhivehi / Maldivian / Hebrew / Kurdish / Persian / Urdu (RTL)
The list is shorter on the RTL side.

No idea if this is feasible or not but displaying the end of a sentence for the majority of languages seems like the opposite of what should be done.

from xbmc.

CastagnaIT avatar CastagnaIT commented on July 24, 2024

by check the source code i dont see there is a check for RTL/LTR used to establish the text truncate position (left/right)

example old kodi behaviour:
immagine

current master:
immagine

i can confirm that currenlty its not ideal in this situation
i think the best thing for now is restore the default LTR truncation
and add a new control setting like "reversedTruncate", where can be used e.g. for the specific GUI settings

add an automatic truncate position by checking RTL/LTR text i think its too much invasive at current development stage
i will try check if im able do the mentioned change

from xbmc.

CastagnaIT avatar CastagnaIT commented on July 24, 2024

if someone can give a feedback for the fix there are some test builds:
android ARM: http://mirrors.kodi.tv/test-builds/android/arm/kodi-20240202-a27b3d71-truncate_text_edit-armeabi-v7a.apk
android ARM64: http://mirrors.kodi.tv/test-builds/android/arm64-v8a/kodi-20240202-a27b3d71-truncate_text_edit-arm64-v8a.apk
Windows: http://mirrors.kodi.tv/test-builds/windows/win64/KodiSetup-20240202-a27b3d71-truncate_text_edit-x64.exe

from xbmc.

CrystalP avatar CrystalP commented on July 24, 2024

ok there was no "before" screenshot in the issue and the title was about the ellipsis, not the text truncation.
Sure if the expectation is the truncation of the end of the text then the ellipsis should be on the right as well.

from xbmc.

scott967 avatar scott967 commented on July 24, 2024

Again, in a bidi world "end of text" means "logical end" of string and "visual display" is different, and a problem when a neutral direction character like punctuation is at the logical beginning or end of string, as bidi algorithm specifies that a higher level direction variable determines if it is treated as LTR or RTL (assuming no explicit direction control unicode in the string). Right justified would be "normal" alignment in RTL script, so ellipsis visually to the left is expected.

from xbmc.

latts9923 avatar latts9923 commented on July 24, 2024

@CastagnaIT
I just installed your test build, and the truncated title is now displaying the "..." on the right side of the text.
Aeon_MQ_9_Omega_right_test

If it's determined that RTL text should display the "..." on the left side of the label, it would be nice to have the option to switch it by adding a new control setting like "reversedTruncate". Thanks for your time!

from xbmc.

CastagnaIT avatar CastagnaIT commented on July 24, 2024

@CrystalP the "before" screenshot appears like comment above here (so #24610 (comment))

@scott967 i think one of the problems to make it "automatic" (RTL/LTR) is that the ellipses "..." are injected while in rendering side, and so are not part of the text itself:
https://github.com/CastagnaIT/xbmc/blob/35893ece3cac34d1bcb30215ad34b11fdf7935a2/xbmc/guilib/GUIFontTTF.cpp#L487-L497

from xbmc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.