<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<STYLE type=text/css>DIV {
        MARGIN: 0px
}
</STYLE>
<META content="MSHTML 6.00.6000.16587" name=GENERATOR></HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face="Arial Unicode MS">Dear Radha</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">Of course it's an extremely cumbersome way to
achieve diacritics, especially complex ones, and we should all be moving on to a
point where with Unicode fonts we can have é and not {\'e} (and the
rest!). But if you do, for a while, need to type in a lot of longwinded
code, a utility such as Autohotkey (<A
href="http://www.autohotkey.com/">http://www.autohotkey.com/</A>) can be very
helpful. And as I said, it's surprising how often these old bits of
plain-TeX code can come in useful, sometimes just in a single situation which it
would take a long time to sort out more elegantly.</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">Best wishes</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">John</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV>----- Original Message ----- </DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=rvaliveti@yahoo.com href="mailto:rvaliveti@yahoo.com">Radhakrishna
Valiveti</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=xetex@tug.org
href="mailto:xetex@tug.org">Unicode-based TeX for Mac OS X and other
platforms</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Friday, January 18, 2008 7:25
PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: [XeTeX] XeTex and
Accents</DIV>
<DIV><FONT face="Arial Unicode MS"></FONT><BR></DIV>
<DIV style="FONT-SIZE: 10pt; FONT-FAMILY: arial,helvetica,sans-serif">Hi
John:<BR> Thanks for your pointers to solving the problem I had
mentioned. The approach followed by exaccent (the style file I am using) is
exactly aligned with the approach you had suggested. The current approach
requires knowing the encoding used for the font. I don't see how it could be
avoided.<BR><BR>regards,<BR>radha<BR>
<DIV> </DIV><STRONG>Radhakrishna Valiveti <BR></STRONG><FONT
color=royalblue>rvaliveti@yahoo.com <BR></FONT>
<DIV style="FONT-SIZE: 10pt; FONT-FAMILY: arial,helvetica,sans-serif"><BR><BR>
<DIV
style="FONT-SIZE: 12pt; FONT-FAMILY: times new roman,new york,times,serif">-----
Original Message ----<BR>From: John Was <john.was@ntlworld.com><BR>To:
Unicode-based TeX for Mac OS X and other platforms
<xetex@tug.org><BR>Sent: Friday, January 18, 2008 12:27:31
AM<BR>Subject: Re: [XeTeX] XeTex and Accents<BR><BR>
<STYLE type=text/css>DIV {
MARGIN:0px;}
</STYLE>
<DIV><FONT face="Arial Unicode MS">Hello Radhakrishna</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">Even now I quite often find it useful to
employ an \overstrike macro which must have been one of the first things I
wrote when I started to read the TeXBook. It superimposes two characters
on top of each other, the narrow centred on the longer. It could be
tidied up a bit but here it is in its rought state:</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT
face="Arial Unicode MS">\def\overstrike#1#2{\leavevmode</FONT></DIV>
<DIV><FONT face="Arial Unicode MS">
\setbox0=\hbox{#1}\setbox1=\hbox{#2}\copy0<BR> \kern -0.5\wd0
\kern -0.5\wd1 \copy1 \kern -0.5\wd1 \kern 0.5\wd0}<BR></FONT></DIV>
<DIV><FONT face="Arial Unicode MS">(You would have to adapt that for LaTeX's
\DeclareTextCommand - I don't (yet) use LaTeX.)</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">The contents of each box can be varied up
and down (use \smash to give it zero height if you think this is going to
interfere with \baselineskip), and you can invoke characters from different
fonts - so if you have a font with a delicate horizontal bar, for example,
that could be used in #2 of the macro rather than the main font's hyphen
character (which will usually look ugly if you force it to serve as an accent,
which it wasn't designed to be).</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">You can nest \overstrike commands, which in
the days before the Unicode combining accents was a useful way of getting
something like a macron with an acute above. Measurements should always
be in terms of em (or ex) so that the right height is chosen regardless
of which point-size you are using.</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">Now if you find this works nicely with
one font but gives an ugly effect in another, you could use</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">\if \else
\fi</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">to give a series of alternative
definitions. In your font definitions you would then have to include a
\....true command. So to switch between definitions for Times and
Garamond, for example, give at the start of your file</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">\newif \iftimes</FONT></DIV>
<DIV><FONT face="Arial Unicode MS">\newif \ifgaramond</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">and whenever one of these fonts is used set
\timestrue or \garamondtrue.</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">The accent definitions would then
be:</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">\iftimes [DEFINITION ONE]
\else</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"> \ifgaramond [DEFINITION
TWO]\fi\fi</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">All this, of course, is very ugly in view
of what you can do neatly with Unicode fonts that have the proper accent
support, but if you are forced into using old fonts, and old .TEX files, this
might at least give you a pointer about how you could control the appearance
of diacritics.</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">Best</FONT></DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS"></FONT> </DIV>
<DIV><FONT face="Arial Unicode MS">John</FONT></DIV>
<DIV> </DIV>
<DIV>---------Original Message ----- </DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: rgb(0,0,0) 2px solid; MARGIN-RIGHT: 0px">
<DIV
style="BACKGROUND: rgb(228,228,228) 0% 50%; FONT: 10pt arial; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-size-adjust: none; font-stretch: normal"><B>From:</B>
<A title=rvaliveti@yahoo.com href="mailto:rvaliveti@yahoo.com" target=_blank
rel=nofollow ymailto="mailto:rvaliveti@yahoo.com">Radhakrishna Valiveti</A>
</DIV>
<DIV
style="FONT: 10pt arial; font-size-adjust: none; font-stretch: normal"><B>To:</B>
<A title=xetex@tug.org href="mailto:xetex@tug.org" target=_blank
rel=nofollow ymailto="mailto:xetex@tug.org">xetex</A> </DIV>
<DIV
style="FONT: 10pt arial; font-size-adjust: none; font-stretch: normal"><B>Sent:</B>
Friday, January 18, 2008 2:59 AM</DIV>
<DIV
style="FONT: 10pt arial; font-size-adjust: none; font-stretch: normal"><B>Subject:</B>
[XeTeX] XeTex and Accents</DIV>
<DIV><FONT face="Arial Unicode MS"></FONT><FONT
face="Arial Unicode MS"></FONT><BR></DIV>
<DIV
style="FONT-SIZE: 10pt; FONT-FAMILY: arial,helvetica,sans-serif">Hi,<BR><BR>
I have recently started using xelatex (with MikTex 2.7) instead of pdflatex.
I have a question about getting accents with xetex. Here are couple of
constraints/requirements for what I am looking for:<BR>
<UL>
<LI>For the book that I am working we need to use three TTF fonts (for
different portions of the text): MS Trebuchet, Futura, and Arial. I don't
have much freedom in choosing different fonts (since we have to preserve
the formatting used in earlier editions of the book).<BR>
<LI>The text in each of these fonts may have the accents: \=, \d, and \.
applied to some of the letters. Sometimes, the text with these accents is
underlined as well. In order to make sure that underline doesn't hide the
dot below the letter, I need to control the placement of the dot
accurately. <BR>
<LI>I would like a general solution that would produce controllable
accents/diacritics, regardless of the fonts. If there has to be some
dependence on the fonts, I would like such dependencies to be localized to
very few macros. It appears to me that using the "preformed" character
from the font (if it exists) may not give me all the flexibility I need.
What do you think?<BR>
<LI> I am currently using the style files: fontspec, exaccent and the
following macros to control the placement of diacritics that I
need:<BR>%======================================<BR>% Adjustment to the
location of
accents<BR>%=======================================<BR>\DeclareTextCommand{\=}{EU1}[1]{\upperaccent[-0.2ex]{"00AF}{#1}}
%macron<BR>\DeclareTextCommand{\.}{EU1}[1]{\upperaccent[-0.2ex]{"00B7}{#1}}
%dot<BR>\DeclareTextCommand{\d}{EU1}[1]{\loweraccent[0.1ex]{"00B7}{#1}}
%dot<BR><BR>But I find that the macron over the letter is just too large
and doesn't look nice (the hyphen looks too small as an overbar). Do we
have any other choice for this? <BR>
<LI>I would like the same macro(s) to work with (a) older, non-unicode TTF
fonts that have been somehow adapted by fontspec to be usable by xetex, or
(b) newer unicode fonts on my machine. When I tried the unicode font
called "Gentium" (which I found on the <A href="http://scripts.sil.org/"
target=_blank rel=nofollow>scripts.sil.org</A> website), the diacritics
over the letters in this font don't look appealing at all (i.e. the above
TextCommands don't seem to have any affect --- it is perhaps picking a
preformed glyph from the font). Is there anything I can
do?<BR></LI></UL> I look forward to hearing from people who have faced
similar issues, and may have a solution to this
issue.<BR><BR>thanks,<BR>radha
<DIV> </DIV><STRONG>Radhakrishna Valiveti <BR></STRONG><FONT
color=royalblue>rvaliveti@yahoo.com <BR></FONT>
<DIV><BR></DIV></DIV>
<P></P><SPAN
style="BORDER-TOP: rgb(128,128,128) 1px solid; MARGIN: 8px 0px; OVERFLOW: hidden; WIDTH: 100%; BORDER-BOTTOM: rgb(212,208,200) 1px solid; HEIGHT: 2px; BACKGROUND-COLOR: black"></SPAN>
<P></P>_______________________________________________<BR>XeTeX mailing
list<BR>postmaster@tug.org<BR><A
href="http://tug.org/mailman/listinfo/xetex"
target=_blank>http://tug.org/mailman/listinfo/xetex</A><BR></BLOCKQUOTE></DIV><BR></DIV></DIV>
<P>
<HR>
<P></P>_______________________________________________<BR>XeTeX mailing
list<BR>postmaster@tug.org<BR>http://tug.org/mailman/listinfo/xetex<BR></BLOCKQUOTE></BODY></HTML>