LATEX-L Archives

Mailing list for the LaTeX3 project

LATEX-L@LISTSERV.UNI-HEIDELBERG.DE

Options: Use Classic View

Use Proportional Font
Show HTML Part by Default
Condense Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Mime-Version: 1.0 (1.0)
Content-Type: text/plain; charset=utf-8
Date: Thu, 10 Jan 2019 09:43:35 +0800
Reply-To: Mailing list for the LaTeX3 project <[log in to unmask]>
From: Will Robertson <[log in to unmask]>
Message-ID: <[log in to unmask]>
In-Reply-To: <[log in to unmask]>
Content-Transfer-Encoding: quoted-printable
Sender: Mailing list for the LaTeX3 project <[log in to unmask]>
Parts/Attachments: text/plain (37 lines)
Hi Kelly

Good question! 

There is one and only one (I think) direct advantage from using the text commands instead of the symbols, which is that you can use alternate encodings (see fontspec manual) to check that the symbol exists and/or replace it with something else. 

It’s also pretty safe for Unicode symbols to make them active and add some extra logic to them if you like. 

Cheers
Will
(Sent from phone; please excuse brevity.) 

> On 10 Jan 2019, at 5:03 am, Kelly Smith <[log in to unmask]> wrote:
> 
> Hello,
> 
> I know that text commands (as defined by \DeclareTextCommand) have
> been important because of the various font encodings that arose over
> LaTeX’s history, but it seems that the situation is quite different
> for the XeTeX and LuaTeX engines.
> 
> Given that both XeLaTeX and LuaLaTeX accept UTF-8 input and use only
> the TU font encoding, is it acceptable to forgo \DeclareTextCommand
> for most—if not all—cases?
> 
> For example, ® can simply be included directly in the document source,
> so \textcopyright is not much more than an ASCII alias.
> 
> As for less common symbols, one could simply wrap the text in a
> document command.
> 
> Excuse my naîveté, as there are probably important advantages to the
> text command approach that I’ve completely overlooked.
> 
> Warmly,
> Kelly

ATOM RSS1 RSS2