Tategaki (japanese vertical writing) in iOS apps - ios

Is there a user control (standard or third-party) for iOS that allows to display vertical text of East Asian languages? I also need to display a ruby characters (furigana/reading aid) near the text. Result should look like this http://img23.imageshack.us/img23/3262/img0088xa.jpg (japanese iBooks screenshot)

At this time you will need Core Text or a view using Core Text.
Github search fails but googling in Japanese wins.
http://cocoadays-info.blogspot.jp/2012/01/coretexttextview-lccoretext.html
Blog article in Japanese on this
https://github.com/novi/LTCoreText
Should do the trick.
Too bad github search doesn't find it.
Google translate may or may not help. I've forked it just now and will translate the read me soon.
Also found https://github.com/hokuron/CTRVerticalTextView
Though it seems fairly unfinished and it's owner's blog seems down.
A Japanese site has this nifty page of bookmarks on the topic.
http://b.hatena.ne.jp/Watson/iOS/CoreText/

Related

Phonetic translation from Latin (English, German) to Arabic

I read a few papers about machine translation but did not understand them well.
The language models (in Google translate) use phonetics and machine learning as best as I can tell.
My question then becomes is it possible to convert an Arabic word that is phonetically spelled in English to translate the users intended Arabic word?
For instance the word 'Hadith' is an English phonetic of the Arabic word 'حديث'. Can I programmatically go from 'Hadith' to Arabic?
Thanks the Wiki article, there's an entire field of work in the area of Transliteration. There was a Google API for this that was deprecated in 2011 and moved to the Google Input Tools service.
The simplest answer is Buck Walter Transliteration but at first glace a 1:1 mapping doesn't seem like a good enough idea.
I am going to try to see if there's a way to hack the Google Input tools and call it even at CLI level because their online demo works very well

design from ltr to rtl automatically

I have a French website that is in LFR (Left to Right)
And the client is wanting to translate the site in hebrew thus transforming it to RTL (Right to Left). In all Hebrew Website the design is reversed
https://he.wikipedia.org/wiki/
https://www.google.co.il/
Is there a way to do this automatically ? Again I am not talking about the text direction. I want to flip it horizontally the design, like a mirror effect.
Your mileage may vary. Some web page generation tools support RTL with easy switch, while with others the WYSIWYG breaks completely when you specify <html dir="rtl">. Browser fragmentation may also be an issue: some browser simply don't support RTL bulleted lists correctly.
There are quite a few good tutorials on the Web; I would recommend https://hacks.mozilla.org/2015/09/building-rtl-aware-web-apps-and-websites-part-1/ and https://hacks.mozilla.org/2015/10/building-rtl-aware-web-apps-websites-part-2/. If you look up Google to search for more articles, please remember that this field is quickly changing, and some recipes of few years ago may be obsolete.
You may find the automation with css-flip or rtlcss useful.
Note that localization is generally not easy, and invariably requires a manual touch. You must understand the target culture very well to recognize tiny glitches that may look awful to the end-user. For example, on Hebrew Website you need different image for the "back" button. On Arabic sites, some numbers should be represented by indic digits, but other numbers are expected to use the usual digits.
Issues of first day of week, etc. are common for LTR localizations, too.

How to make Protege 4.3 display chinese character correctly?

I am using Protege 4.3 to create and organize an Ontology which contains Chinese characters.
As you can see, some Chinese characters are displayed properly, but others are displayed in little squares. The little squares do not always occur, for example: if I click on the []-[]-[]-cheatsheet-[]-[]-[]-[]-[], I can the same Chinese characters are displayed without problem.
Do you know what I can do to make Protege 4.3 display chinese characters correctly and consistently?
I guess I could have done further homework for this question. It's a post close to the final solution. (I have to post this as an answer for the length doesn't fit comment box)
To be specific, I found from Protege Mailing List Archive the following feedback post
[p4-feedback] Protege 4.2.0 Chinese Display Problem:
https://mailman.stanford.edu/pipermail/p4-feedback/2012-June/004721.html
I know this problem and have even fixed it on one occasion. But I don't truly understand it or know what to do about it. I am sorry that I don't have good information on this problem but I will give you my best current understanding.
In my experience, when this happens the character information is correctly encoded in the OWL file. The problem is exclusively a display problem. This is consistent with your description of the problem - in some of the screens the individuals are displaying correctly.
I believe that the problem has to do with the configuration of fonts in the java virtual machine. If you change the instance of java that Protege is using the problem will manifest in different ways or it will go away. When I worked on this problem before (it has happened
a couple of times) I gathered some web pages. Unfortunately only one of them is still valid, but perhaps it is part of the solution.
I will post my own investigation results after trying the suggested approach above.
PS: A useful owl example is provided here - some unicode characters do not display correctly in Protege

How to store math equation/symbol and display them on the web?

I want to build a website where people can create tests with questions and answers . I want people can type in math equation/symbol and equations in a textbox or something like that, and they will be store in database, it'also displayed on the web like image.
My idea is i will store the text user input in latex syntax and store it, then display it using MathJax, i don't know it's possible or will have better way to do this.
And a problem is in user input will have normal text with "math text" (latex), so how can i separate them and only save the latex text? Please give me some idea or suggest the way to solve it, thanks.
p/s: i'm building this site in ruby on rails, i found the gem mathjax-rails but it seem not working.
Consider building off Gollum. It is the backend for the wiki system Github uses and works fairly well with LaTex equations (currently their is a very irritating bug with less/greater than symbols, but is documented and likely will be fixed in the next release). I start using it this summer to take notes in a math classes, an example of a full page of rendered LaTex equations notes is here here.
Note: You must be logged into Github in order for the equation to render.

Displaying right-to-left text in Team Explorer

We've started using TFS at work, and I'm migrating my bugs from the previous issue tracking software to TFS. All of them are written in Hebrew, a right-to-left language, but mixed with English words.
All the text fields in the TFS client are left-to-right, so I have to manually go and press Ctrl-Right-Shift in all the fields in order to read them properly.
Is there any way to change the default text orientation in TFS client?
I looked into customizing the work item form elements, for example here:
http://msdn.microsoft.com/en-us/library/ms194963.aspx
but I couldn't find any attribute for changing the text orientation.
As far as I understand it there is not a way of changing the text orientation in the work item definition. I've passed your question along to some guys on the team in Microsoft to see if they know of anything.
is there an answer? Since then I continued searching for a way to do this, but I couldn't find any.
This is a serious usability issue for me, especially with the titles, which have mixed Hebrew-English. When displaying the issue titles I have to read "backwards". When scanning a lot of issues, this is a serious pain.
And I do not have the spare time to translate 500+ issues from Hebrew to English.

Resources