<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; "><DIV><DIV>On 14 Dec 2007, at 4:58 am, Computer Support Chad wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"><FONT face="Arial"><FONT size="2"> <DIV>I have a challenge for someone out there. I'm working in Arabic script, and have a need to include numbers in the text (in Hindi number format) that are superscripted and enclosed in a kind of "star". I have included an image below, but I don't know if that can come through on the list. (I can email it offline if anyone is interested.) The image shows a "star" that is actually the outside border of two squares rotated 45 degrees from each other. It may be acceptable for the actual shape of the "star" in my application to be different, so if someone wanted to produce a circle or a square (at least as a first draft), I would be interested in that as well.</DIV> <DIV> </DIV> <DIV>So is anyone up to the challenge of producing a (Xe)TeX macro that will do this?</DIV> </FONT></FONT></BLOCKQUOTE><BR></DIV><DIV>This sounds like the kind of thing for which U+06DD is intended, though its glyph varies a lot and is not usually star-shaped. But you might like to try this, with a font such as Scheherazade that supports this character:</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV> \TeXXeTstate=1</DIV><DIV> \font\ar="Scheherazade:script=arab" at 24pt \ar</DIV><DIV> \def\num#1{\char"202E\char"06DD #1\char"202C\relax}</DIV><DIV> </DIV><DIV> \noindent\beginR السلام \num{١٢٣} عليكم</DIV> <BR><DIV> \end</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>(Note that directional overrides are needed in order to make the rendering work properly; this is currently a limitation of how xetex, bidi ordering, and the OpenType tables interact.) You can enclose the whole sequence in \raise<dimen>\hbox{......} if you want to shift it up from the baseline.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Alternatively, you can locate a glyph you like in some other font, and use overlaid boxes to place your digits into it; here's an example using a plain square from Webdings:</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV> \font\webdings="Webdings" at 14pt</DIV><DIV> \font\arsmall="Scheherazade:script=arab" at 11pt</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV> \def\boxednum#1{\setbox0=\hbox{\webdings \char"F063}%</DIV><DIV> \setbox2=\hbox to \wd0{\hfil \arsmall #1\hfil}%</DIV><DIV> \raise.5ex\hbox{\rlap{\box0}\raise3pt\box2}}</DIV><DIV> </DIV><DIV> \noindent\beginR السلام \boxednum{٤٢} عليكم</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>If your original numbers are using Western digits (0123...), but you want to print them with the ٠١٢٣... characters, the easiest way is to apply a font-mapping that does this conversion; this has been discussed previously, or see examples in the ArabXeTeX package on CTAN.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>JK</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR class="khtml-block-placeholder"></DIV></BODY></HTML>