hebrew

Can't set RTL direction for Hebrew letters while converting from *.xhtml to *.pdf by using iText library

我只是一个虾纸丫 提交于 2019-12-02 13:55:36
问题 I'm trying to convert *.xhtml with Hebrew characters (UTF-8) to PDF by using iText library but I getting all letter in reverse order. As far I understand from this question I can set RTL only for ColumnText and PdfCell objects: Arabic (and Hebrew) can only be rendered correctly in the context of ColumnText and PdfPCell. So I doubt is it possible to convert whole *.xhtml page to PDF? This is an *.xhtml file which I try to import : <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"

Convert Unicode Escape to Hebrew text

匆匆过客 提交于 2019-12-02 08:57:55
问题 I have the following text in a json file: "\u00d7\u0090\u00d7\u0097\u00d7\u0095\u00d7\u0096\u00d7\u00aa \u00d7\u00a4\u00d7\u0095\u00d7\u009c\u00d7\u0092" which represents the text "אחוזת פולג" in Hebrew. no matter which encoding/decoding i use i don't seem to get it right with Python 3. if for example ill try: text = "\u00d7\u0090\u00d7\u0097\u00d7\u0095\u00d7\u0096\u00d7\u00aa \u00d7\u00a4\u00d7\u0095\u00d7\u009c\u00d7\u0092".encode('unicode-escape') print(text) i get that text is: b'\\xd7\

Split the first letter from variable

蹲街弑〆低调 提交于 2019-12-02 05:41:10
I need to split the first letter from variable $name. How I can to do it? $name = $userData['name']; How I can to get the first letter? and please check if it correct: if($userData['gender'] == 'male'){ if($firstletter=='i'){ $picture = ImageCreateFromPNG ($global['maleBackgroundImages'][1]); }else{ $picture = ImageCreateFromPNG ($global['maleBackgroundImages'][2]);} }else{ if($firstletter=='i'){ $picture = ImageCreateFromPNG ($global['maleBackgroundImages'][1]); }else{ $picture = ImageCreateFromPNG ($global['maleBackgroundImages'][2]);} } $userData['name'][0] Offsets in strings can be

Using Hebrew characters in string

允我心安 提交于 2019-12-02 05:40:30
问题 I would like to use Hebrew characters in string in R. I used the following: > a<-c("משה") > a [1] "îùä" > class (a) [1] "character" As can be seen I get Jibbrish when I output the content of the string or using any functions. How can I use Hebrew characters? 回答1: Thanks to all the comments here is the answer: If I use it as is, I get Jibbrish: > a<-"משה" > a [1] "îùä" However if I encode it to UTF8 I get the right result: > a<-enc2utf8( "משה") > a [1] "משה" I wish there was a way to do it

Convert Unicode Escape to Hebrew text

一个人想着一个人 提交于 2019-12-02 05:09:50
I have the following text in a json file: "\u00d7\u0090\u00d7\u0097\u00d7\u0095\u00d7\u0096\u00d7\u00aa \u00d7\u00a4\u00d7\u0095\u00d7\u009c\u00d7\u0092" which represents the text "אחוזת פולג" in Hebrew. no matter which encoding/decoding i use i don't seem to get it right with Python 3. if for example ill try: text = "\u00d7\u0090\u00d7\u0097\u00d7\u0095\u00d7\u0096\u00d7\u00aa \u00d7\u00a4\u00d7\u0095\u00d7\u009c\u00d7\u0092".encode('unicode-escape') print(text) i get that text is: b'\\xd7\\x90\\xd7\\x97\\xd7\\x95\\xd7\\x96\\xd7\\xaa \\xd7\\xa4\\xd7\\x95\\xd7\\x9c\\xd7\\x92' which in bytecode

How to fix a batch file with an Hebrew font?

﹥>﹥吖頭↗ 提交于 2019-12-02 04:10:41
问题 I created a batch file that contains characters in Hebrew. ECHO אאאאא The result is ╫É╫É╫É on running the batch file. How can I fix it? 回答1: It looks like you have encoded your batch file with UTF-8 saved without byte order mark (BOM) for Hebrew Letter Aleph with Unicode code value 05D0. The batch code below copied into a UTF-8 encoded file without BOM changes the code page to UTF-8 (65001) before the characters are written into the console window. @echo off chcp 65001 >nul ECHO אאאא Instead

Right to Left Alignment for UITableView

爷,独闯天下 提交于 2019-12-02 02:49:24
问题 I am working on an arabic app for iphone 3.0. i was wondering if there is a way that i can convert the UITableViewCell to be right-to-left. I want everything to be in the opposite direction. Any thoughts? 回答1: Creating your own UITableViewCell subclass is not that hard to do and is probably the first thing you'll want to do to get a custom look. All you'll need is a custom XIB file and a bit of modified code in your cellForRowAtIndexPath function: NSString *CellIdentifier = @

Drawing Hebrew text to and image using Image module (python)

最后都变了- 提交于 2019-12-02 01:27:07
This is an issue I already asked about and several got answers but the problem remained. when I try to write in hebrew to an image using Image module I get instead of the hebrew lettring some other (ascii??) lettering. if I convert to unicode or ascii I get an error that it doesn't support. I got here a reference to a code that does what I want in chinese: import sys import Imag import ImageDraw import ImageFont import _imaging txt = '你好,世界!' font = ImageFont.truetype('c:/test/simsun.ttc',24) im = Image.new("RGBA",(300,200),(0,0,0)) draw = ImageDraw.Draw(im) #draw.text( (0,50), u'你好,世界!', font

How to fix a batch file with an Hebrew font?

蹲街弑〆低调 提交于 2019-12-02 01:22:23
I created a batch file that contains characters in Hebrew. ECHO אאאאא The result is ╫É╫É╫É on running the batch file. How can I fix it? It looks like you have encoded your batch file with UTF-8 saved without byte order mark (BOM) for Hebrew Letter Aleph with Unicode code value 05D0. The batch code below copied into a UTF-8 encoded file without BOM changes the code page to UTF-8 (65001) before the characters are written into the console window. @echo off chcp 65001 >nul ECHO אאאא Instead of using multi-byte encoding UTF-8, it would be also possible to use single-byte encoding with code page 862

regular expression with hebrew or english

99封情书 提交于 2019-12-02 00:58:09
I'm looking for a pattern that accept only hebrew or english letters from 2 letters to 15, and can accept 1 space. I have tried following code but it does not matching my string: <?php $subject = "שלום לך"; $regexp="#^\p[{Hebrew}| ][a-zA-Z]{2,15}? \+$#u"; print_r(preg_match($regexp, $subject)); ?> There are multiple errors in your code. First, your regex $regexp="#^\p[{Hebrew}| ][a-zA-Z]{2,15}? \+$#u"; Here is what it means: # : regex delimiter ^ : begining of string \p : character p [{Hebrew}| ] : character class, one of the char : {, H, e, b, r, w, }, |, space [a-zA-Z]{2,15}? : from 2 to 15