[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#290930: hyperref should support mailto



Martin Michlmayr <tbm@cyrius.com> writes:

> It would be nice if hyperref.sty had a special command \mailto{} to
> generate a mailto: link but have the text formated like an URL.  At
> the moment, if you want to have mailto links in the text which look
> like URLs, you need something like
>
>   \href{mailto:foo@example.com}{\textt{foo@example.com}}
>
> which is imho quite ugly.

Not that it's up to me, but surely you would instead do

\newcommand{\mailto}[1]{\href{mailto:#1}{\texttt{#1}}}

and then \mailto{foo@example.com} is not so ugly? One reason for the
package not providing \mailto is that some people would want 

\newcommand{\mailto}[2]{\href{mailto:#1}{#2}}

and some people would want the \texttt included everytime, and others
would want to add ?Subject=#3 to the link etc...



Reply to: