0

What the best way for me to close this question? I tried, but I simply cannot find the time to provide the code I promised, and I am certain I have already lost all interest in the answer, as I have made the difficult decision to moved back home (MS Word). However, someone else might find this useful? I do not know how to navigate the situation.

What's the best way to abandon the question unanswered (despite the nice attempts below) while maintaining any possible value to the community? Should I just close/delete it? or is there a protocol I should follow?

I'll check back to check for suggestions in the coming 2 days and implement them. Sorry for the inconvenience


I am writing my one and (hopefully) last LaTeX document, and I am using this template provided by my school: https://www.overleaf.com/latex/templates/university-of-waterloo-thesis-template-updated-august-2022/qxqqzmbrcmpp

I am working on preparing a minimal working example, I'll update the post when that's ready. It'll take me some time

it uses the glossaries-extra package:

\usepackage[automake,toc,abbreviations]{glossaries-extra}

with which I have the following issues:

  1. It colors every single abbreviation in my text. It becomes silly when I use it alot. I am also using it for mathematical formulas and to name things like temperature is T, and so on. Imagine c = a + b where a,b,c are green, but = and + are back. Yuk. To "fix" this, I have resorted to simply color it black: \renewcommand*{\glstextformat}[1]{\textcolor{black}{#1}}. I know that this may raise a few eyebrows, but I don't want the colors, underlines, or anything distracting. It will look very very bad.

  2. Issue #2 emerges. If I dare to use any \gls{} in my section or chapter titles, my table of contents becomes funny looking with a mostly blue text, with black words sprinkled here and there. I fixed it by simply not committing this cardinal sin. The reader will probably find this abbreviation in a nearby text, click on it there and they can see the full form or whatever. not a big deal. But is this really the correct use? even if I hadn't made it black, apparently the correct use was green (not blue), still a 5yo sketch book.

  3. I also use \gls{} with figure captions. These figure captions show up in a List of Figures page. Again funny colors, but this time it would be a big compromise to do the same as in titles and not use it.

  4. Now that I have my glossaries showing up in the first few pages, another feature becomes practically unusable. Say I have the following: \newabbreviation{qec}{QEC}{quantum error correction} the first \gls{qec} will show up in text as "quantum error correction (QEC)" while the following \gls{qec} will only show up as "QEC". Pretty neat feature, except that this first occurrence is apparently happening in the list of figures page before page #1! sigh...

I do not write in LaTeX for a living. This is probably the last time I'll use it, but I am in too deep to pull out now. In fact, I am in too deep to change glossary packages. If anyone knows of a solution, even a Band-Aid solution, I am all ears. If I am doing it wrong, please advise me. If neither, then I'll make do with what I have, and bury the memory of it once it's over.

There are probably more relevant "settings" that need to be mentioned. I have no clue what they are (otherwise I wouldn't be asking the question). I've linked to the template which I barely edited (setting wise). I hope it has all you need, and if not, please be kind and let me know what do you need from me without expecting much literacy in LaTeX. Oh, I am of course using overleaf, this is how LaTeX noobs do :)

Edit: to be clear, I want the hyperlinks to exist. I do not want them to become unclickable (otherwise the solution is simple, don't use \gls{}.

himura
  • 101
  • it would be easier if you showed some code, but as a guess try \hypersetup{hidelinks} – Ulrike Fischer Jun 27 '23 at 22:59
  • My understanding is that the link I gave is accessible by the public. is it not? I will update my question, but I still want these links to be clickable. my problem is with their "other" features, exactly as elaborated – himura Jun 27 '23 at 23:01
  • @himura Not everyone in this site has, or want to have, an overleaf account. In general external links are not the best way to show problems. Please add a minimal working example showing your problem. You will have a better change to receive answers if you do – Luis Turcio Jun 28 '23 at 00:29
  • I will not go to an external source to debug your problem, questions and answers on tex.sx should be understandable also in the future. hidelinks doesn't disable links, it only makes them invisible. If that resolves your problem: it is also possible to disable links locally, see the documentation of glossaries. – Ulrike Fischer Jun 28 '23 at 08:36
  • I understand that it is stressful to learn a new tool during an important project; that's why it's a good idea to get in some practice with less important projects beforehand. Here are some tips to get the help you need: 1. Be nice and to the point, don't complain, just ask your question. (After having searched for an existing answer, of course.) 2. Focus on one issue per question. If you need help with several things, ask several questions. 3. Always include an MWE! This helps you write better questions and us write better answers. – schtandard Jun 28 '23 at 15:52
  • 1
    This is news to me (expected, I know nothing about Latex community). Did no know that overleaf was not widespread. I'll workout a minimal working example and update the question in the near future – himura Jun 28 '23 at 21:34

1 Answers1

1

As you noticed placing hyperlinks in movable parts of your document (headings, "short" captions, etc.) is not a good idea, as they are re-used in the TOC, LOF etc. (which are lists of links) and nested links are not sensible. So you want to use the starred versions of the glossary macros in order to suppress the links (e.g. \gls* instead of \gls).

In order to avoid setting the first-use flag (which shouldn't be done in titles or captions anyhow), use \glstext* instead of \gls*.

Have a look at the glossaries and glossaries-extra documentations for more details. They are a bit overwhelming at first glance but you can find all relevant information on those macros in there.

schtandard
  • 14,892
  • Thanks. I'll try these solutions and report back. – himura Jun 29 '23 at 00:32
  • just to get back to you, I have tried your suggestion, and sadly, that is not what I want. I still want the hyperlink to function, but only not in the "list". glossaries-extra documentation mentioned something about \glsxtrfull and \glsxtrshort which do not always work for some reason. Its pretty bizarre. – himura Jul 12 '23 at 01:42
  • @himura While I think that it is cleaner and easier to just avoid links in such places, you can use one of the workarounds in this answer. – schtandard Jul 12 '23 at 10:05