Page 1 of 1

GA_TEXTEDITOR_Flow

PostPosted: Fri Mar 30, 2018 3:09 am
by mritter0
When using that tag in texteditor.gadget

GA_TEXTEDITOR_Flow, GV_TEXTEDITOR_Flow_Right,

for right to left text, the horizontal scroll bar should be started all the way to the right, not the left, so it slides to the left by default.

I have tried to set SLIDER_Level to compensate for this but it will not change.

Re: GA_TEXTEDITOR_Flow

PostPosted: Fri Mar 30, 2018 6:21 pm
by broadblues
for right to left text,


I don't think right to left text is supported?

GA_TEXTEDITOR_Flow affects the alignment of text not the direction of it.

As such the scroller should continue to work left to right, same as for example it does in wordworth.

It's position at anyone time will depnd on the cursor anyway.

Re: GA_TEXTEDITOR_Flow

PostPosted: Fri Mar 30, 2018 8:05 pm
by mritter0
I am using it in read only mode. I have not seen right to left text since can't read it, but isn't it written right to left? So displaying it would be correct.

Yes, typing in text would be a whole 'nother thing.

Re: GA_TEXTEDITOR_Flow

PostPosted: Fri Mar 30, 2018 8:40 pm
by broadblues
mritter0 wrote:I am using it in read only mode. I have not seen right to left text since can't read it, but isn't it written right to left? So displaying it would be correct.


Again GA_TEXTEDITOR_Flow sets the alignment of text, not it's direction. The autodoc suggests in can be set on a per paragraph basis, but I'm not sure that works for the current implementation. Where I use it in the SketchBlock text tool the whole text gets realigned left right or centre.

I'm not convinced (but welcome correction from anyone who really knows about this) that right to left fonts will work, in general in AmigaOS or more specifically in the texteditor.gadget, but if they did the change of font would be what dictated the change of direction of the scroll bar rather than the above tag.

Re: GA_TEXTEDITOR_Flow

PostPosted: Fri Mar 30, 2018 10:40 pm
by tonyw
There is no support in graphics.library for right-to-left fonts.

Re: GA_TEXTEDITOR_Flow

PostPosted: Fri Mar 30, 2018 10:50 pm
by nbache
tonyw wrote:There is no support in graphics.library for right-to-left fonts.
How does Locale Prefs then display the localized version of "Hebrew" (seemingly) right-to-left? Is it constructed internally as an image or something?

Best regards,

Niels

Re: GA_TEXTEDITOR_Flow

PostPosted: Sat Mar 31, 2018 11:08 am
by tonyw
I have no idea, Niels. Suffice it to say that I have looked at the source of graphics/Text() to see what has to be done to enable right-left drawing and it's not easy.

Perhaps the Hebrew draws the characters in the normal left-right way, but the character glyphs and characters in the string are reversed?

Re: GA_TEXTEDITOR_Flow

PostPosted: Sat Mar 31, 2018 1:41 pm
by broadblues
@Niels

Bascically it cheats. It checks the languages charset and sets the browser nodes justification to right if it happens to be iso-8859-8 but otherwise the text is rendered left to right and I'd guess there the characters are in reverse order in the C string representing it.

I tested out of interest and when you enable Hebrew very few strings are localised (mainly the country names as far as I can tell) and those that are are still rendered left to right and left justified, the only place you see it right justified is in the locale prefs language chooser.

Re: GA_TEXTEDITOR_Flow

PostPosted: Sat Mar 31, 2018 8:12 pm
by nbache
@Tony & @Andy:

Thanks for explaining - I had a feeling it might be something like that.

Oh well, if at least we could get full Unicode working one day, even if only in left-to-right fashion, that would amount to somthing, I guess.

But I'm digressing from the thread's original matter, sorry.

Best regards,

Niels