How to underline and color hyperlinks?

Pavel Sanda sanda at lyx.org
Mon Sep 30 18:10:38 UTC 2024


On Sat, Sep 28, 2024 at 11:52:04PM -0400, Richard Kimberly Heck wrote:
> On 9/28/24 5:29 PM, Pavel Sanda wrote:
> > On Sat, Sep 28, 2024 at 09:55:04PM +0200, Pavel Sanda wrote:
> > > On Sun, Sep 22, 2024 at 07:11:36PM +0300, Udicoudco wrote:
> > > > The "cololinks" option in the hyperref package disables the borders
> > > > at the beginning of the document. If you want both you need to add the
> > > > following to the preamble after enabling colored links
> > > > 
> > > > \AtBeginDocument{\hypersetup{pdfborder=0 0 1}}
> > > > 
> > > > Its a question of whether the GUI should indicate
> > > > things similar to the LaTeX implementation or not.
> > > I think we could indicate this in the UI pane (either
> > > disabling border option when colorlinks are enabled
> > > or enhance the tooltip).
> > This option like the attached.
> > 
> > Second option would be to actually use the proposed workaround
> > and allow frames with colors.  The cons:
> > 1) not clear how our hack will work in future
> >    (might be better to ask upstream if we really aim for this)
> > 2) even more complex code wrt the use of \AtBeginDocument & \hypersetup
> > 3) will change output for checked color links option only,
> >     so we should probably wait for 2.5 to introduce this
> > 
> > 
> > I favour option 1. Opinions?
> 
> Yes, I think this is really a hyperref limitation. I tried, in raw LaTeX, to
> use both colorlinks and pdfborder (or linkbordercolor) as options to
> hyperref, and even that doesn't work. So the hack may be fragile.

It's in 601abfe9291.

I propose to include it in branch.

Pavel


More information about the lyx-devel mailing list