newline for Arabic or urdu string

sms247
        string s = "";

        s += "پاکستان کے وزیراعظم نواز شریف نے یقین دہانی کرائی ہے کہ صحافی حامد میر پر قاتلانہ حملے :TV";

        s += "\n\r"+"بی بی سی اردو کا آفیشل ٹوئٹر اکاؤنٹ۔:BBC Urdu's";

        xrLabel1.Text = s;

but its show worried output like

 پاکستان کے وزیراعظم نواز شریف نے یقین دہانی کرائی ہے کہ صحافی حامد میر پر قاتلانہ حملے :GEOبی بی سی اردو کا آفیشل
ٹوئٹر اکاؤنٹ۔:BBC Urdu's

i want some thing like (same like my code)

پاکستان کے وزیراعظم نواز شریف نے یقین دہانی کرائی ہے کہ صحافی حامد میر پر قاتلانہ حملے :GEO
بی بی سی اردو کا آفیشل ٹوئٹر اکاؤنٹ۔:BBC Urdu's

i think its new line problem any suggestion or solution's ?

VahidN

You actually need a right to left embedding character (RLE) at the beginning of the line to show RTL and LTR words correctly.

  • U+202A:   LEFT-TO-RIGHT EMBEDDING (LRE)
  • U+202B:   RIGHT-TO-LEFT EMBEDDING (RLE)
  • U+202D:   LEFT-TO-RIGHT OVERRIDE (LRO)
  • U+202E:   RIGHT-TO-LEFT OVERRIDE (RLO)
  • U+202C:   POP DIRECTIONAL FORMATTING (PDF)

http://www.w3.org/International/questions/qa-bidi-controls

char rleChar = (char)0x202B;// RLE embedding 
text = rleChar + text;

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related