In Xcode, how to display text merging English+Arabic and beginning with Arabic?

后端 未结 3 365
深忆病人
深忆病人 2020-12-13 00:57

I want to set a label to string: \"خخخ just bought: Disguise Kit.\" but when I run the test, the label show \".just bought: Disguise Kit خخخ\"?

If the text is not be

3条回答
  •  离开以前
    2020-12-13 01:36

    Actually, \u{200E} (or any) symbol can be inserted into the string literal.

    1. Add "Unicode Hex Input" (System Preferences -> Keyboard -> Input Sources -> + -> Unicode Hex Input).
    2. In the text editor move the cursor to the place where you want to insert a symbol.
    3. Switch input source to the "Unicode Hex Input".
    4. Hold the Option key and type 200E.
    5. The symbol should be inserted and the string should look like you expect.

提交回复
热议问题