right-to-left

Android: RTL support - digits embedded in a right to left sentence (Hebrew)

别等时光非礼了梦想. 提交于 2020-01-02 03:45:28
问题 My application displays Hebrew text which comes from a Web Service. When a sentence contains digits (in the middle of it), the digits appear in a mirror view: 29 appears as 92, 21:45 appears as 54:12 and 2,000 appears as 000,2. Also, when a sentence starts with digits or English characters, they get thrown to the end of the sentence messing it all up... Does anyone have an idea how can this be solved? Is RTL support in Android still immature? 回答1: Is RTL support in Android still immature? If

right-to-left (RTL) support in SASS project

a 夏天 提交于 2020-01-02 03:27:05
问题 I'm wondering if it's possible to make a mixin that handles multiple arguments as properties that should be converted to rtl. I want to do something like .css-selector { width: 300px; height: 200px; @include rtl { padding: 10px 5px 3px 4px; margin: 3px 8px 2px 5px; } } with a mixin: $rtl = false !default; @mixin rtl() { @if $rtl { dir: rtl; @each $property in @content { //check property if it's padding or margin or something else rtl-related... if hit use rtl mixin } } @else { @content; } } I

How to use jQuery Isotope in Right-to-Left?

人盡茶涼 提交于 2020-01-01 19:31:16
问题 How can I override to automatic left-alignment in the beautiful-beautiful jQuery Isotope (Source on GitHub)? Thanks! 回答1: You have two options: Re-engineer Isotope's layout logic, or build your own layout mode. Isotope's layout logic is progressively enhanced to use CSS transforms when available, but fall back to top/left positioning. So if you pass in coordinates x, y to the getPositionStyles method it will either return with { translate: [ x, y ] } or { left: x; top: y } . The problem with

Android TextView right alignment on a right-to-left device

末鹿安然 提交于 2020-01-01 12:04:08
问题 I am writing an app that displays in the Hebrew language and for that I am right aligning TextView's text. While developing on a Nexus device all works great and texts are displayed as it should, using the android:gravity="right" for TextView. When I am running the same app on a local mobile carrier device (Israel) which is running a custom ROM all TextView widgets that were set with gravity="right" are appearing as if they were set as gravity="left". If I go and change the gravity to left

How to specify RTL specific drawables

点点圈 提交于 2019-12-31 09:10:56
问题 I have few images that looks different on right-to-left. Is it possible to create rtl specific drawable directory or some rtl post-fix for file names to auto-load relevant images? Looks like ldrtl post-fix, added from 17 lvl, is good only for layouts directory. 回答1: It's pretty late to answer this question, but I want to share a method that I just found out. I will first recap what is mentioned by the others. Let's start with a specification . We need to build something like: login --> take

Right to Left UI in iPhone (Hebrew)

我的梦境 提交于 2019-12-30 08:33:29
问题 I'm struggling in creating a RTL UI in iPhone application. The framework doesn't seem to have any support for RTL languages. The only thing is the alignment inside labels, which is nice, but it conflicts with other controls behaviour. The question is: Is there a working code for a RTL TableView? Something that would handle the disclosure buttons to be on the left, section titles to be right aligned, index view to be left aligned? As far as I understand I cannot move the index view of the

How do I position the cursor on the right in EditText

只谈情不闲聊 提交于 2019-12-30 02:45:13
问题 My application uses RTL language (right to left). When the EditText field gets focus, the cursor appears on the left and only when the user starts to type, the cursor (and the RTL text) moves right. When the user clicks "enter" to start a new line, the cursor moves to the left again. When I use android:gravity="right" , the cursor is OK (on the right) but as the user starts to type the text always moves to the the other side (RTL text moves left). Any ideas how I can align text to the right

set RTL Orientation of scrollbar inside JFileChooser?

走远了吗. 提交于 2019-12-29 08:10:16
问题 I have a JFileChooser and I want to make it oriented from right-to-left, and to do so I use: applyComponentOrientation(ComponentOrientation.RIGHT_TO_LEFT); but an issue shows up. The horizontal scrollbar is still set to the left despite the JFileChooser dialog is oriented RTL correctly. Look at this image: How can I fix it? Here is an SSCCE: import javax.swing.JOptionPane; import javax.swing.UIManager; import javax.swing.JFileChooser; import javax.swing.filechooser.FileNameExtensionFilter;

How to detect that text typed in text-area is RTL

二次信任 提交于 2019-12-29 07:29:19
问题 I have a textarea in which the user can enter text in english (or any other left-to-right language) or in a language that is RTL. When the user writes in RTL, the user must press Right-shift + ctrl in order to make the text be aligned to the right and be rtl. However, in windows (and probably other modern OSes) the user can set any key combination to switch language and text direction. I know how to display text as RTL, but how will I know which direction to display? Is there a way to detect

RTL not working in pdf generation with itext 5.5 for Arabic text

筅森魡賤 提交于 2019-12-28 04:32:26
问题 I have java code that writes arabic characters with the help of itext 5.5 and xmlworker jars, but its writing left to right even after writer.setRunDirection(PdfWriter.RUN_DIRECTION_RTL) is used. Code used is: public class CreateArabic extends DefaultHandler { /** Paths to and encodings of fonts we're going to use in this example */ public static String[][] FONTS = { {"C:/arialuni.ttf", BaseFont.IDENTITY_H}, {"C:/abserif4_5.ttf", BaseFont.IDENTITY_H}, {"C:/damase.ttf", BaseFont.IDENTITY_H}, {