Thank you for your reply Clemens!
cgnieder wrote:ougka wrote:A macro could work but has the following problems :
a) Latex treats it as an hbox (obviously), so in almost all the circumstances that I've checked the hbox exceeds the normal line's width on the right, which is pretty annoying. It doesn't try to put the hbox in the line's width so that it pushes it all to the next line and space out the text (which would be my preferred way).
This depends on the lines badness after/before breaking. You want to prevent TeX from breaking Wi-Fi which it did because it calculated it to be the best solution. Since this is not allowed anymore you will naturally get bad boxes and have to tweak or re-arrange the text in some cases. TeX is only allowed to stretch and shrink the interword space a certain amount (depending on several factors like the font). I'm sure TeX tried to put the box on a new line but hasn't found any solution without infinite badness.
Well, I understand the above, but I would want from Latex to push Wi-Fi to the next line and space out the previous line a bit... after all it is just a few letters so I would think that this wouldn't be a problem...
cgnieder wrote:ougka wrote:b) I have to go over ALL the problematic acronyms in my text and do sth like \WiFi, which in all honesty is a trouble I would like to avoid.
I'm afraid there won't be a way to avoid that. You'd have to do some “search & replace”. Good thing is: once you've done that you can change layout and boxing at one place in the preamble.
Well yes it is a search & replace think but think of all the captions, tables etc where I wouldn't want to have boxes cause they will be messing up with things... Also, it is not just Wi-Fi that I have a problem with, I have tens of other examples, I am afraid, EAP-TLS, EAP-TTLS, real-world, on-the-go etc...
I've just found this which might help
http://java.ugent.be/~tdemedts/latex.php
So essentially do something like :
Code: Select all
\newcommand\n{$n$\nobreakdash-\hspace{0pt}}
Consider the \n dimensional manifold ...