Le 14/02/2025 à 16:46, Denniston, Todd A CIV USN NSWC CD CRANE IN (USA)
via lyx-users a écrit :
Folks,
I am trying to add some script bits to the text of my lyx document and I (believe) am having some
trouble with lyx doing some auto-magic converting of single quotes "'" & back ticks
"`". I desire that I _should_ be able to copy and paste from both the lyx doc (while I am
editing it) and the PDF output into my terminals. {program versions at the bottom of the email}
I put *most* of these scriptlets in LyX-Code environments, and was expecting
LyX-Code to be enough to prevent auto-magic, but no.
Hello Todd,
LyX-Code is the worst in terms of auto-magic.
You could try either Verbatim or the Listings inset (which may be able
to do syntax coloring for you BTW).
JMarc
The issues I am having is I want the following chars, but get some
'typographical' replacements:
ASCII 0x27 ' single quote (I think some folks call it apostrophe)
ASCII 0x22 " double quote
ASCII 0x60 ` back tick
{and the different naming syntax across the web makes searching the web
difficult}
Example scriptlets:
rpm -q --info lyx | grep Packager | \
awk -F\: '{print $2}'
for i in `ls *.lyx`; \
do echo "$i is a wonderful file"; done
rpm -q --qf '%{NAME} %{INSTALLTIME}' lyx
Note: also insert a ctrl-enter after the \ on the end of the line, so they copy
together out of the PDF.
Also see attached MWE.
I think I found that using ctrl+" gets me something that works for double
quotes (and they work when I copy paste from the terminal to lyx).
But I have not figured out how to enter single quotes and back ticks that don't
get mangled on the translation to PDF yet.
I have looked at https://wiki.lyx.org/Tips/KeyboardShortcuts but not
necessarily understood how it can help me yet.
(In the kinder gentler times of Fedora 4 all this seemed to work without
thinking, but that has been a while ago, and now OTHER folks are once again
trying to use my documents next to their terminals, and don't take kindly to my
'mind the 's notes.)
Thanks for generally keeping my document creation and editing sane for the
last couple of decades.
Some more clues to control the situation would be appreciated.
Note: I use the versions provided by my OS to the maximum extent, because
otherwise I have security folks breathing hot down my neck. So don't ask why I
have such old tech, it works for *most* things I need.
Versions:
RHEL 8
LyX Version 2.3.6 (from EPEL)
QT 5.15.3
texlive 20180414
evince 3.28.4
--
lyx-users mailing list
lyx-users@lists.lyx.org
https://lists.lyx.org/mailman/listinfo/lyx-users