Re: How to paste into LyX-Code ?!!
Daniel said on Thu, 18 Nov 2021 08:48:07 +0100 >On 2021-11-17 23:28, Steve Litt wrote: >> Daniel said on Wed, 17 Nov 2021 10:44:23 +0100 >> >>> On 17/11/2021 10:01, Steve Litt wrote: >>>> Hi all, >>>> >>>> I have a C program I want to show in a book. So I use the LyX-Code >>>> environment, but when I copy the C file to the clipboard and paste >>>> it into the LyX-Code environment, all the newlines are removed. >>>> What's the right way to show a C program file within LyX? >>>> >>>> Thanks, >>>> >>>> SteveT >>>> >>>> Steve Litt >>>> Spring 2021 featured book: Troubleshooting Techniques of the >>>> Successful Technologist http://www.troubleshooters.com/techniques >>>> >>> >>> You could try >>> >>> "Edit" > "Paste Special" > "Plain Text" or Ctrl+Shift+V. >> >> The preceding worked. Thank you! >>> >>> I never understood what "Plain Text" does not among other things it >>> should keep the line breaks. I guess keeping line-breaks should be >>> the default... >> >> It's ridiculous that it's not the default, you're right. >> >> Thanks also to Norman Dunbar who suggested the same things. >> >> Thanks also to Hartmut Hasse and Stephan Witt for their suggestions, >> which I didn't try for lack of time once the Shift+Ctrl+v worked. >> >> I spent 2 hours trying to find a method last night, before figuring >> I'd be better off asking the list. Thanks for your suggestions! >> >> SteveT > >Sorry to hear that you wasted so much time. Thanks Daniel. I'm not sorry: It's adventures like this that keep me on my toes. Also, I don't ask on the list until I've done significant research. > Others seem to have been >there before as well: > >https://www.lyx.org/trac/ticket/8026 Until somebody gets around to "fixing" it, which at this point would mess up those used to the current behavior, it could be treated as a documentation problem. It would be interesting to put it on a page titled "The Top 20 Unexpected Behaviors in LyX". That page could be prominently linked to by many other pages. I'm so used to LyX that I long ago forgot the other 19 :-). SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: How to paste into LyX-Code ?!!
On 2021-11-17 23:28, Steve Litt wrote: Daniel said on Wed, 17 Nov 2021 10:44:23 +0100 On 17/11/2021 10:01, Steve Litt wrote: Hi all, I have a C program I want to show in a book. So I use the LyX-Code environment, but when I copy the C file to the clipboard and paste it into the LyX-Code environment, all the newlines are removed. What's the right way to show a C program file within LyX? Thanks, SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques You could try "Edit" > "Paste Special" > "Plain Text" or Ctrl+Shift+V. The preceding worked. Thank you! I never understood what "Plain Text" does not among other things it should keep the line breaks. I guess keeping line-breaks should be the default... It's ridiculous that it's not the default, you're right. Thanks also to Norman Dunbar who suggested the same things. Thanks also to Hartmut Hasse and Stephan Witt for their suggestions, which I didn't try for lack of time once the Shift+Ctrl+v worked. I spent 2 hours trying to find a method last night, before figuring I'd be better off asking the list. Thanks for your suggestions! SteveT Sorry to hear that you wasted so much time. Others seem to have been there before as well: https://www.lyx.org/trac/ticket/8026 Unfortunately, gmane is dead and I couldn't figure out where the mentioned discussion is. But I guess its result just wasn't followed by action. I tried to bump the ticket up again. And there was someone on the list, I think, who had a similar problem when pasting into ERT where joining lines seems to be no good idea either. In general, it seems to me that the default paste should honor the format of the original. And if that isn't desired, "join lines" could be selected. (Mostly there is *some* good idea for why things are as they are but there needs to be adjustment in light of people's actual experiences.) Daniel -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: How to paste into LyX-Code ?!!
Daniel said on Wed, 17 Nov 2021 10:44:23 +0100 >On 17/11/2021 10:01, Steve Litt wrote: >> Hi all, >> >> I have a C program I want to show in a book. So I use the LyX-Code >> environment, but when I copy the C file to the clipboard and paste it >> into the LyX-Code environment, all the newlines are removed. What's >> the right way to show a C program file within LyX? >> >> Thanks, >> >> SteveT >> >> Steve Litt >> Spring 2021 featured book: Troubleshooting Techniques of the >> Successful Technologist http://www.troubleshooters.com/techniques >> > >You could try > >"Edit" > "Paste Special" > "Plain Text" or Ctrl+Shift+V. The preceding worked. Thank you! > >I never understood what "Plain Text" does not among other things it >should keep the line breaks. I guess keeping line-breaks should be the >default... It's ridiculous that it's not the default, you're right. Thanks also to Norman Dunbar who suggested the same things. Thanks also to Hartmut Hasse and Stephan Witt for their suggestions, which I didn't try for lack of time once the Shift+Ctrl+v worked. I spent 2 hours trying to find a method last night, before figuring I'd be better off asking the list. Thanks for your suggestions! SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: How to paste into LyX-Code ?
Ctrl-shift-v pastes with new lines. Ctrl-v pastes without. Caught me out for a while. Cheers, Norm. -- Sent from my Android device with K-9 Mail. Please excuse my brevity. On 17 November 2021 09:01:12 GMT, Steve Litt wrote: >Hi all, > >I have a C program I want to show in a book. So I use the LyX-Code >environment, but when I copy the C file to the clipboard and paste it >into the LyX-Code environment, all the newlines are removed. What's the >right way to show a C program file within LyX? > >Thanks, > >SteveT > >Steve Litt >Spring 2021 featured book: Troubleshooting Techniques of the Successful >Technologist >http://www.troubleshooters.com/techniques >-- >lyx-users mailing list >lyx-users@lists.lyx.org >http://lists.lyx.org/mailman/listinfo/lyx-users -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: How to paste into LyX-Code ?
Am 17.11.2021 um 10:01 schrieb Steve Litt : > > Hi all, > > I have a C program I want to show in a book. So I use the LyX-Code > environment, but when I copy the C file to the clipboard and paste it > into the LyX-Code environment, all the newlines are removed. What's the > right way to show a C program file within LyX? Hi Steve, you may insert a Listings inset and configure it to point to your C file. After that you can define the lines you want to show and many more things. See here for the options: https://mirror.dogado.de/tex-archive/macros/latex/contrib/listings/listings.pdf BR, Stephan -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: How to paste into LyX-Code ?
On 17/11/2021 10:01, Steve Litt wrote: Hi all, I have a C program I want to show in a book. So I use the LyX-Code environment, but when I copy the C file to the clipboard and paste it into the LyX-Code environment, all the newlines are removed. What's the right way to show a C program file within LyX? Thanks, SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques You could try "Edit" > "Paste Special" > "Plain Text" or Ctrl+Shift+V. I never understood what "Plain Text" does not among other things it should keep the line breaks. I guess keeping line-breaks should be the default... Daniel -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: How to paste into LyX-Code ?
Hi Steve, what if you rename the .c file into .txt and do in Lux insert➡️file ➡️ simple text? -- Viele Grüße Hartmut Diese Nachricht wurde mit meinem Tablett serviert.-- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
How to paste into LyX-Code ?
Hi all, I have a C program I want to show in a book. So I use the LyX-Code environment, but when I copy the C file to the clipboard and paste it into the LyX-Code environment, all the newlines are removed. What's the right way to show a C program file within LyX? Thanks, SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
SV: I need an environment similar to, but not identical to LyX-Code
> I need an environment similar to, but not identical to the LyX-Code > environment. Specifically, I need the page margins to be the same as > regular text, and I'd also like a smaller font. LyX-code is defined in /usr/share/lyx/layouts/lyxmacros.inc (OSes other than Linux may use a different folder) In this file, you find both the LyX layout specification, and the LaTeX code: Style LyX-Code Category MainText MarginStatic LatexType Environment LatexName lyxcode NextNoIndent 1 LeftMarginMMM RightMargin MMM TopSep0.5 BottomSep 0.5 Align Left AlignPossible Block, Left, Right, Center LabelType No_Label FreeSpacing 1 Preamble \newenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} EndPreamble Font Family Typewriter EndFont End LyX-Code is set using the LaTeX environment lyxcode, which is defined inside the style itself. I happen to have a custom layout with with what you request; Code with smaller text and regular margins. The style looks like this: Style Code-small CopyStyle LyX-Code LatexType Environment LatexName codesmall LeftMargin "" RightMargin "" Font Size Scriptsize Family Typewriter EndFont Spellcheck 0 Preamble \newenvironment{codesmall} {\begin{scriptsize}\par\begin{list}{}{ \setlength{\leftmargin}{0pt} \setlength{\rightmargin}{0pt} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}\end{scriptsize}} EndPreamble End Feel free to adapt it to your needs.Perhaps you want another size instead of Scriptsize. Helge Hafting Fra: lyx-users på vegne av Steve Litt Sendt: fredag 11. juni 2021 01:54:03 Til: lyx-users@lists.lyx.org Emne: I need an environment similar to, but not identical to LyX-Code I need an environment similar to, but not identical to the LyX-Code environment. Specifically, I need the page margins to be the same as regular text, and I'd also like a smaller font. So I figured I'd find the LaTeX definition of LyX-Code and work from there, possibly using CopyStyle. But I've searched for 1/2 hour and cannot find the TeX definition of the latexname part of LyX-Code, nor can I find the LyX user interface part of LyX-Code. So where can I find the definition of LyX-Code? SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: I need an environment similar to, but not identical to LyX-Code
On 6/10/21 7:54 PM, Steve Litt wrote: I need an environment similar to, but not identical to the LyX-Code environment. Specifically, I need the page margins to be the same as regular text, and I'd also like a smaller font. So I figured I'd find the LaTeX definition of LyX-Code and work from there, possibly using CopyStyle. But I've searched for 1/2 hour and cannot find the TeX definition of the latexname part of LyX-Code, nor can I find the LyX user interface part of LyX-Code. So where can I find the definition of LyX-Code? SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques Steve, Create a file with one line of whatever in a LyX-Code environment. Turn on View > Code Preview Pane, and in the preview pane use an appropriate format (such as pdflatex) and set the drop down for what to show to Preamble Only. You'll find the \newenvironment{lyxcode}{...} stuff in the preview pane (after a little scrolling). Paul -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
I need an environment similar to, but not identical to LyX-Code
I need an environment similar to, but not identical to the LyX-Code environment. Specifically, I need the page margins to be the same as regular text, and I'd also like a smaller font. So I figured I'd find the LaTeX definition of LyX-Code and work from there, possibly using CopyStyle. But I've searched for 1/2 hour and cannot find the TeX definition of the latexname part of LyX-Code, nor can I find the LyX user interface part of LyX-Code. So where can I find the definition of LyX-Code? SteveT Steve Litt Spring 2021 featured book: Troubleshooting Techniques of the Successful Technologist http://www.troubleshooters.com/techniques -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: Blank lines in Lyx-Code mode
On Wed, 14 Mar 2018, Paul A. Rubin wrote: I think this behavior is pretty consistent across versions (give or take whether the blank line appears to be preserved during pasting). Paul, Oh, Okay. I don't use the code environment all that often, but when I do ... As far as the best way to insert a blank line, I usually stick in an unbreakable space (ctrl-space), or use ctrl-Enter to put in a manual line break. I put an manual line break at the end of each line just as a matter of course. Regards, Rich
Re: Blank lines in Lyx-Code mode
On 03/14/2018 01:52 PM, Rich Shepard wrote: On Wed, 14 Mar 2018, Bruce Momjian wrote: Using LyX 2.1.4, when I paste text using "Paste Special" into a LyX-Code block, blank lines are preserved in the LyX display. Bruce, Have you tried a newer version, e.g., 2.2.3 or 2.3.0rc2? Rich I think this behavior is pretty consistent across versions (give or take whether the blank line appears to be preserved during pasting). I also think the end result (no blank line in the code listing) is expect LaTeX behavior. Possibly someone could request a feature enhancement in LyX where LyX would look for empty lines in the clipboard and insert line breaks in them to preserve them. I'm not sure whether that would be generally desirable or not. As far as the best way to insert a blank line, I usually stick in an unbreakable space (ctrl-space), or use ctrl-Enter to put in a manual line break. I don't know if there is an "official" LaTeX-ish way to preserve empty lines. Paul
Re: Blank lines in Lyx-Code mode
On Wed, 14 Mar 2018, Bruce Momjian wrote: Using LyX 2.1.4, when I paste text using "Paste Special" into a LyX-Code block, blank lines are preserved in the LyX display. Bruce, Have you tried a newer version, e.g., 2.2.3 or 2.3.0rc2? Rich
Blank lines in Lyx-Code mode
Using LyX 2.1.4, when I paste text using "Paste Special" into a LyX-Code block, blank lines are preserved in the LyX display. However, when I render the document as a PDF, the blank lines are removed. If I add a space on the empty line, the blank line is output properly. Is this expected behavior? It certain is surprising. Is there a better way to render blank lines in Lyx-Code mode than adding a space to the blank line? -- Bruce Momjian <br...@momjian.us>http://momjian.us EnterpriseDB http://enterprisedb.com + As you are, so once was I. As I am, so you will be. + + Ancient Roman grave inscription +
Re: Backtick in LyX's "LyX-Code" mode
On Thu, Dec 28, 2017 at 03:40:27AM -0500, Scott Kostyshak wrote: > On Fri, Oct 06, 2017 at 01:31:49AM +, Scott Kostyshak wrote: > > On Thu, Sep 28, 2017 at 08:48:13AM +, Guenter Milde wrote: > > > On 2017-09-27, Bruce Momjian wrote: > > > > On Wed, Sep 27, 2017 at 12:41:27PM -0400, Scott Kostyshak wrote: > > > >> On Mon, Sep 25, 2017 at 10:24:47PM +, Bruce Momjian wrote: > > > >> > I am using LyX 2.1.2 on Ubuntu 14.04. > > > >> > > > > >> > If I enter this: > > > >> > > > > >> > ab'c de`f > > > >> > > > > >> > in "Standard" mode I get PDF output with proper left/right single > > > >> > quotes. However, if I switch to LyX-Code mode for that text, I get > > > >> > as > > > >> > PDF output: > > > >> > > > > >> > ab'c de'f > > > > > > >> Testing on 2.1.0 and on 2.3.0dev, I get the following as PDF output: > > > > > > >> ab’c de‘f > > > > > > >> which is different from what you get, but also not what you want. > > > > > > > Actually, that would be fine output, as long as they look different. > > > > > > >> > This is a problem for text of shell scripts. I the want backticks > > > >> > because backtick means 'execute' in the shell. > > > >> > > > > >> > What I have done instead to get literal backticks output is to use a > > > >> > TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block > > > >> > and > > > >> > used \char18, which properly outputs the backtick. > > > >> > > > > >> > Is this expected behavior? Is that the recommended solution for > > > >> > this? > > > > > > >> I have not seen a report of this, but I haven't seen an indication that > > > >> a lot of people are using LyX-Code, so I'm not sure if is known. > > > > > > > OK, not sure what could be the cause then. I am using ps2pdf to produce > > > > the PDF. > > > > > > The view in PDF depends on the selected fonts rather than export route. I > > > get identic results with PDF (pdflatex) and PDF (ps2pdf). > > > > > > You may experiment with different fonts, as well as checking the result of > > > drag-and-drop from the PDF. Here, it is > > > ab'c de`f with PDF(pdflatex) and ab' de`f with PDF(ps2pdf). > > > > > > > What I have done as a work-around is to warn in my Makefile if a > > > > backquote is used in the LyX document. > > > > > > Did you try with listings? > > > > Hi Bruce, > > > > I just wanted to make sure that you saw Günter's message (pasted above), > > since he had a good idea, to experiment with different fonts. > > Hi Bruce (I'm CC'ing you directly now), just wanted to make sure you saw > Günter's message above. Thanks. I ended up adding this to the Makefile I use to generate the PDFs: # check for backquotes, which appear as single quotes if grep -q '`' "$FILE" thenecho 'Backquotes found, replace with TeX Code \\char18' exit 1 fi It warns me about backquotes and suggests replacement with TeX Code \\char18. -- Bruce Momjian <br...@momjian.us>http://momjian.us EnterpriseDB http://enterprisedb.com + As you are, so once was I. As I am, so you will be. + + Ancient Roman grave inscription +
Re: Backtick in LyX's "LyX-Code" mode
On Fri, Oct 06, 2017 at 01:31:49AM +, Scott Kostyshak wrote: > On Thu, Sep 28, 2017 at 08:48:13AM +, Guenter Milde wrote: > > On 2017-09-27, Bruce Momjian wrote: > > > On Wed, Sep 27, 2017 at 12:41:27PM -0400, Scott Kostyshak wrote: > > >> On Mon, Sep 25, 2017 at 10:24:47PM +, Bruce Momjian wrote: > > >> > I am using LyX 2.1.2 on Ubuntu 14.04. > > >> > > > >> > If I enter this: > > >> > > > >> > ab'c de`f > > >> > > > >> > in "Standard" mode I get PDF output with proper left/right single > > >> > quotes. However, if I switch to LyX-Code mode for that text, I get as > > >> > PDF output: > > >> > > > >> >ab'c de'f > > > > >> Testing on 2.1.0 and on 2.3.0dev, I get the following as PDF output: > > > > >> ab’c de‘f > > > > >> which is different from what you get, but also not what you want. > > > > > Actually, that would be fine output, as long as they look different. > > > > >> > This is a problem for text of shell scripts. I the want backticks > > >> > because backtick means 'execute' in the shell. > > >> > > > >> > What I have done instead to get literal backticks output is to use a > > >> > TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block and > > >> > used \char18, which properly outputs the backtick. > > >> > > > >> > Is this expected behavior? Is that the recommended solution for this? > > > > >> I have not seen a report of this, but I haven't seen an indication that > > >> a lot of people are using LyX-Code, so I'm not sure if is known. > > > > > OK, not sure what could be the cause then. I am using ps2pdf to produce > > > the PDF. > > > > The view in PDF depends on the selected fonts rather than export route. I > > get identic results with PDF (pdflatex) and PDF (ps2pdf). > > > > You may experiment with different fonts, as well as checking the result of > > drag-and-drop from the PDF. Here, it is > > ab'c de`f with PDF(pdflatex) and ab' de`f with PDF(ps2pdf). > > > > > What I have done as a work-around is to warn in my Makefile if a > > > backquote is used in the LyX document. > > > > Did you try with listings? > > Hi Bruce, > > I just wanted to make sure that you saw Günter's message (pasted above), > since he had a good idea, to experiment with different fonts. Hi Bruce (I'm CC'ing you directly now), just wanted to make sure you saw Günter's message above. Scott
Re: Backtick in LyX's "LyX-Code" mode
On Thu, Sep 28, 2017 at 08:48:13AM +, Guenter Milde wrote: > On 2017-09-27, Bruce Momjian wrote: > > On Wed, Sep 27, 2017 at 12:41:27PM -0400, Scott Kostyshak wrote: > >> On Mon, Sep 25, 2017 at 10:24:47PM +, Bruce Momjian wrote: > >> > I am using LyX 2.1.2 on Ubuntu 14.04. > >> > > >> > If I enter this: > >> > > >> > ab'c de`f > >> > > >> > in "Standard" mode I get PDF output with proper left/right single > >> > quotes. However, if I switch to LyX-Code mode for that text, I get as > >> > PDF output: > >> > > >> > ab'c de'f > > >> Testing on 2.1.0 and on 2.3.0dev, I get the following as PDF output: > > >> ab’c de‘f > > >> which is different from what you get, but also not what you want. > > > Actually, that would be fine output, as long as they look different. > > >> > This is a problem for text of shell scripts. I the want backticks > >> > because backtick means 'execute' in the shell. > >> > > >> > What I have done instead to get literal backticks output is to use a > >> > TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block and > >> > used \char18, which properly outputs the backtick. > >> > > >> > Is this expected behavior? Is that the recommended solution for this? > > >> I have not seen a report of this, but I haven't seen an indication that > >> a lot of people are using LyX-Code, so I'm not sure if is known. > > > OK, not sure what could be the cause then. I am using ps2pdf to produce > > the PDF. > > The view in PDF depends on the selected fonts rather than export route. I > get identic results with PDF (pdflatex) and PDF (ps2pdf). > > You may experiment with different fonts, as well as checking the result of > drag-and-drop from the PDF. Here, it is > ab'c de`f with PDF(pdflatex) and ab' de`f with PDF(ps2pdf). > > > What I have done as a work-around is to warn in my Makefile if a > > backquote is used in the LyX document. > > Did you try with listings? Hi Bruce, I just wanted to make sure that you saw Günter's message (pasted above), since he had a good idea, to experiment with different fonts. Best, Scott signature.asc Description: PGP signature
Re: Backtick in LyX's "LyX-Code" mode
On 2017-09-27, Bruce Momjian wrote: > On Wed, Sep 27, 2017 at 12:41:27PM -0400, Scott Kostyshak wrote: >> On Mon, Sep 25, 2017 at 10:24:47PM +, Bruce Momjian wrote: >> > I am using LyX 2.1.2 on Ubuntu 14.04. >> > >> > If I enter this: >> > >> > ab'c de`f >> > >> > in "Standard" mode I get PDF output with proper left/right single >> > quotes. However, if I switch to LyX-Code mode for that text, I get as >> > PDF output: >> > >> >ab'c de'f >> Testing on 2.1.0 and on 2.3.0dev, I get the following as PDF output: >> ab’c de‘f >> which is different from what you get, but also not what you want. > Actually, that would be fine output, as long as they look different. >> > This is a problem for text of shell scripts. I the want backticks >> > because backtick means 'execute' in the shell. >> > >> > What I have done instead to get literal backticks output is to use a >> > TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block and >> > used \char18, which properly outputs the backtick. >> > >> > Is this expected behavior? Is that the recommended solution for this? >> I have not seen a report of this, but I haven't seen an indication that >> a lot of people are using LyX-Code, so I'm not sure if is known. > OK, not sure what could be the cause then. I am using ps2pdf to produce > the PDF. The view in PDF depends on the selected fonts rather than export route. I get identic results with PDF (pdflatex) and PDF (ps2pdf). You may experiment with different fonts, as well as checking the result of drag-and-drop from the PDF. Here, it is ab'c de`f with PDF(pdflatex) and ab' de`f with PDF(ps2pdf). > What I have done as a work-around is to warn in my Makefile if a > backquote is used in the LyX document. Did you try with listings? Günter
Re: Backtick in LyX's "LyX-Code" mode
On Wed, Sep 27, 2017 at 12:41:27PM -0400, Scott Kostyshak wrote: > On Mon, Sep 25, 2017 at 10:24:47PM +, Bruce Momjian wrote: > > I am using LyX 2.1.2 on Ubuntu 14.04. > > > > If I enter this: > > > > ab'c de`f > > > > in "Standard" mode I get PDF output with proper left/right single > > quotes. However, if I switch to LyX-Code mode for that text, I get as > > PDF output: > > > > ab'c de'f > > Testing on 2.1.0 and on 2.3.0dev, I get the following as PDF output: > > ab’c de‘f > > which is different from what you get, but also not what you want. Actually, that would be fine output, as long as they look different. > > This is a problem for text of shell scripts. I the want backticks > > because backtick means 'execute' in the shell. > > > > What I have done instead to get literal backticks output is to use a > > TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block and > > used \char18, which properly outputs the backtick. > > > > Is this expected behavior? Is that the recommended solution for this? > > I have not seen a report of this, but I haven't seen an indication that > a lot of people are using LyX-Code, so I'm not sure if is known. OK, not sure what could be the cause then. I am using ps2pdf to produce the PDF. What I have done as a work-around is to warn in my Makefile if a backquote is used in the LyX document. -- Bruce Momjian <br...@momjian.us>http://momjian.us EnterpriseDB http://enterprisedb.com + As you are, so once was I. As I am, so you will be. + + Ancient Roman grave inscription +
Re: Backtick in LyX's "LyX-Code" mode
On Mon, Sep 25, 2017 at 10:24:47PM +, Bruce Momjian wrote: > I am using LyX 2.1.2 on Ubuntu 14.04. > > If I enter this: > >ab'c de`f > > in "Standard" mode I get PDF output with proper left/right single > quotes. However, if I switch to LyX-Code mode for that text, I get as > PDF output: > > ab'c de'f Testing on 2.1.0 and on 2.3.0dev, I get the following as PDF output: ab’c de‘f which is different from what you get, but also not what you want. > This is a problem for text of shell scripts. I the want backticks > because backtick means 'execute' in the shell. > > What I have done instead to get literal backticks output is to use a > TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block and > used \char18, which properly outputs the backtick. > > Is this expected behavior? Is that the recommended solution for this? I have not seen a report of this, but I haven't seen an indication that a lot of people are using LyX-Code, so I'm not sure if is known. Scott signature.asc Description: PGP signature
Re: Backtick in LyX's "LyX-Code" mode
On 2017-09-25, Bruce Momjian wrote: > I am using LyX 2.1.2 on Ubuntu 14.04. > If I enter this: >ab'c de`f > in "Standard" mode I get PDF output with proper left/right single > quotes. This is a feature of LaTeX fonts: the ASCII quote and backtick are mapped to "typographical" quotes u2019 and u2018: ab’c de‘f > However, if I switch to LyX-Code mode for that text, I get as > PDF output: > ab'c de'f Here, I get the "typographical" quotes u2019 and u2018 in a teletype font: ab’c de‘f With Document>Settings>Fonts>non-TeX fonts, the PDF output is as expected: ab'c de`f > This is a problem for text of shell scripts. I the want backticks > because backtick means 'execute' in the shell. > What I have done instead to get literal backticks output is to use a > TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block and > used \char18, which properly outputs the backtick. In case using Unicode fonts is not an option, you may also try the "listings" package (Insert>Program listing) with the options upquote=true basicstyle=\ttfamily in Document>Settings>Program listings. In a minimal document, you may need to add \usepackage{textcomp} to the LaTeX preamble. A a last ressort, you can use the macro \textasciigrave (instead of \char18) in raw LaTeX (ERT). Günter
Backtick in LyX's "LyX-Code" mode
I am using LyX 2.1.2 on Ubuntu 14.04. If I enter this: ab'c de`f in "Standard" mode I get PDF output with proper left/right single quotes. However, if I switch to LyX-Code mode for that text, I get as PDF output: ab'c de'f This is a problem for text of shell scripts. I the want backticks because backtick means 'execute' in the shell. What I have done instead to get literal backticks output is to use a TeX Code URT (Ugly Red Text) block inside the "LyX-Code mode" block and used \char18, which properly outputs the backtick. Is this expected behavior? Is that the recommended solution for this? -- Bruce Momjian <br...@momjian.us>http://momjian.us EnterpriseDB http://enterprisedb.com + As you are, so once was I. As I am, so you will be. + + Ancient Roman grave inscription +
improve my physics book with lyx code
Dear Uwe, lyx users 1- i upgrade my small physics book: - add more image with svg in the source. - make formula font small by this code in preamble: \everymath{\scriptstyle} - improve preamble (thanks for mr.Uwe,mr.Guenter). the book her (GPL): https://sourceforge.net/projects/ohodquizgame/files/Books/physics.pdf/download the source of the book with images (GPL): https://sourceforge.net/projects/ohodquizgame/files/Books/physics_source_lyx2.2.1.zip/download another Gifts: 2- - my quiz game for (android, windows) mobile, 12000 questions for free (but in arabic language and not GPL). https://sourceforge.net/projects/ohodquizgame/files/android/ 3- my EduXampp program (GPL): - xampp server for windows. - TCexam Administrative examination. - opensis for Administrative schools. - Gibbon for Administrative schools. download: https://sourceforge.net/projects/ohodquizgame/files/EduXampp/ 4- my Ohod quiz for website, 5000 questions (GPL, arabic language). - support utf-8, so easy to used in any language. - easy to convrt to android apk or windows or linux by webkit. https://sourceforge.net/projects/ohodquizgame/files/A/ "This gifts to express my thanks to you" best regards
Re: Double quotes in LyX-Code
On 15/01/2013 8:47 p.m., Stephan Witt wrote: Am 15.01.2013 um 08:46 schrieb Stephan Witt st.w...@gmx.net: Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. Sorry, obviously I should have written S-C-2 Stephan Thanks for the answer about ~. Following your S-C-2 example, I deleted the shortcut I'd made to get , and instead modified cua.bind by commenting out \bind S-C-quotedbl self-insert \ and, for my keyboard where ' and are on the same key, replacing it with \bind S-C-' self-insert \ Starting up LyX again, this gives me exactly what I want, ASCII 34, the straight double quote. Andrew
Re: Double quotes in LyX-Code
On Tue, Jan 15, 2013 at 2:47 AM, Stephan Witt st.w...@gmx.net wrote: Am 15.01.2013 um 08:46 schrieb Stephan Witt st.w...@gmx.net: Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. There's a related (unresolved) issue with the parentheses shortcuts in the sciword binding: http://www.lyx.org/trac/ticket/8364#comment:7 Scott
Re: Double quotes in LyX-Code
On 14.01.2013 09:35, Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of standard LyX, specifically for the LyX-Code environment. One workaround could be to use listing instead of LyXCode (Insert - Program Listing), with the option: upquote=true (to be typed in the Listing Settings window, Advanced tab) Best regards, O. Andrew
Re: Double quotes in LyX-Code
On 15/01/2013 8:47 p.m., Stephan Witt wrote: Am 15.01.2013 um 08:46 schrieb Stephan Witt st.w...@gmx.net: Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. Sorry, obviously I should have written S-C-2 Stephan Thanks for the answer about ~. Following your S-C-2 example, I deleted the shortcut I'd made to get , and instead modified cua.bind by commenting out \bind S-C-quotedbl self-insert \ and, for my keyboard where ' and are on the same key, replacing it with \bind S-C-' self-insert \ Starting up LyX again, this gives me exactly what I want, ASCII 34, the straight double quote. Andrew
Re: Double quotes in LyX-Code
On Tue, Jan 15, 2013 at 2:47 AM, Stephan Witt st.w...@gmx.net wrote: Am 15.01.2013 um 08:46 schrieb Stephan Witt st.w...@gmx.net: Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. There's a related (unresolved) issue with the parentheses shortcuts in the sciword binding: http://www.lyx.org/trac/ticket/8364#comment:7 Scott
Re: Double quotes in LyX-Code
On 14.01.2013 09:35, Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of standard LyX, specifically for the LyX-Code environment. One workaround could be to use listing instead of LyXCode (Insert - Program Listing), with the option: upquote=true (to be typed in the Listing Settings window, Advanced tab) Best regards, O. Andrew
Re: Double quotes in LyX-Code
On 15/01/2013 8:47 p.m., Stephan Witt wrote: Am 15.01.2013 um 08:46 schrieb Stephan Witt: Am 15.01.2013 um 08:06 schrieb Liviu Andronic : On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe : What does ~ signify here? It's the not operator. In your case "not shift". I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? "~S-C-quotedbl" is "the key which translates to quotedbl plus control but without shift". If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to "~S-C-2". Sorry, obviously I should have written "S-C-2" Stephan Thanks for the answer about ~. Following your "S-C-2" example, I deleted the shortcut I'd made to get ", and instead modified cua.bind by commenting out \bind "S-C-quotedbl" "self-insert \"" and, for my keyboard where ' and " are on the same key, replacing it with \bind "S-C-'" "self-insert \"" Starting up LyX again, this gives me exactly what I want, ASCII 34, the straight double quote. Andrew
Re: Double quotes in LyX-Code
On Tue, Jan 15, 2013 at 2:47 AM, Stephan Wittwrote: > Am 15.01.2013 um 08:46 schrieb Stephan Witt : > >> Am 15.01.2013 um 08:06 schrieb Liviu Andronic : >> >>> On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe : > What does ~ signify here? It's the not operator. In your case "not shift". >>> I'm curious: What does this imply in terms of physical keyboard? That >>> is, what should one press to get 'not shift'? >> >> "~S-C-quotedbl" is "the key which translates to quotedbl plus control but >> without shift". >> >> If you don't have a keyboard with quotedbl without shift this binding does >> not match. >> IMHO, one has to change that e.g. for a german keyboard to "~S-C-2". There's a related (unresolved) issue with the parentheses shortcuts in the sciword binding: http://www.lyx.org/trac/ticket/8364#comment:7 Scott
Re: Double quotes in LyX-Code
On 14.01.2013 09:35, Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert " to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of "standard LyX", specifically for the LyX-Code environment. One workaround could be to use "listing" instead of LyXCode (Insert -> Program Listing), with the option: upquote=true (to be typed in the Listing "Settings" window, "Advanced" tab) Best regards, O. Andrew
Double quotes in LyX-Code
I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of standard LyX, specifically for the LyX-Code environment. Andrew
Re: Double quotes in LyX-Code
On 2013-01-14, Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of standard LyX, specifically for the LyX-Code environment. IMV, the right thing would be to turn off the smart quote feature in LyX-Code. To the developers: * Would it be possible to change the quote-inset so that it generates straight/literal quote characters in LyX-Code? * This would/should also solve the bug http://www.lyx.org/trac/ticket/7309 program listings lose quotation marks of converted code Günter
Re: Double quotes in LyX-Code
Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays slanted double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+ in the standard setting (cua). Jürgen
Re: Double quotes in LyX-Code
On 15/01/2013 1:03 a.m., Jürgen Spitzmüller wrote: Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays slanted double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+ in the standard setting (cua). Jürgen I use the cua bindings ( Windows Vista). On my present keyboard, I think previous ones, the single double quotes use the same key, being Shift+', but LyX interprets this as smart double quotes. The single quote is not interpreted as a smart quote: Alt+Shift+' gives a smart single quote. I see in cua.bind: \bind ~S-M-quotedbl quote-insert single \bind ~S-C-quotedbl self-insert \ What does ~ signify here? Andrew
Re: Double quotes in LyX-Code
Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: On 15/01/2013 1:03 a.m., Jürgen Spitzmüller wrote: Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays slanted double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+ in the standard setting (cua). Jürgen I use the cua bindings ( Windows Vista). On my present keyboard, I think previous ones, the single double quotes use the same key, being Shift+', but LyX interprets this as smart double quotes. The single quote is not interpreted as a smart quote: Alt+Shift+' gives a smart single quote. I see in cua.bind: \bind ~S-M-quotedbl quote-insert single \bind ~S-C-quotedbl self-insert \ What does ~ signify here? It's the not operator. In your case not shift. Stephan
Re: Double quotes in LyX-Code
On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? Liviu
Re: Double quotes in LyX-Code
Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. See the debug messages I get when trying to input Control- 1. Pure frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777248 keyState: Shift- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777248, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777248, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Shift_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 34 keyState: Shift- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 34, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 34, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is quotedbl frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 0 frontends/qt4/GuiApplication.cpp (1904): action first set to [] frontends/qt4/GuiApplication.cpp (1912): action now set to [] frontends/qt4/GuiApplication.cpp (1923): Key [action=][Shift-] frontends/qt4/GuiApplication.cpp (1936): Trying without shift frontends/qt4/GuiApplication.cpp (1938): Action now 2. Now Control- frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777249 keyState: Control- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777249, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777249, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Control_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777248 keyState: Shift-Control- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777248, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777248, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Shift_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 08:41:03.874: Befehl ist deaktiviertfrontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 50 keyState: Shift-Control- frontends/qt4/GuiKeySymbol.cpp (618): keyevent has isNull() text ! frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is 2 frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 0 frontends/qt4/GuiApplication.cpp (1904): action first set to [] frontends/qt4/GuiApplication.cpp (1912): action now set to [] frontends/qt4/GuiApplication.cpp (1923): Key [action=][Shift-Befehl-2] Stephan
Re: Double quotes in LyX-Code
Am 15.01.2013 um 08:46 schrieb Stephan Witt st.w...@gmx.net: Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. Sorry, obviously I should have written S-C-2 Stephan
Double quotes in LyX-Code
I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of standard LyX, specifically for the LyX-Code environment. Andrew
Re: Double quotes in LyX-Code
On 2013-01-14, Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of standard LyX, specifically for the LyX-Code environment. IMV, the right thing would be to turn off the smart quote feature in LyX-Code. To the developers: * Would it be possible to change the quote-inset so that it generates straight/literal quote characters in LyX-Code? * This would/should also solve the bug http://www.lyx.org/trac/ticket/7309 program listings lose quotation marks of converted code Günter
Re: Double quotes in LyX-Code
Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays slanted double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+ in the standard setting (cua). Jürgen
Re: Double quotes in LyX-Code
On 15/01/2013 1:03 a.m., Jürgen Spitzmüller wrote: Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays slanted double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+ in the standard setting (cua). Jürgen I use the cua bindings ( Windows Vista). On my present keyboard, I think previous ones, the single double quotes use the same key, being Shift+', but LyX interprets this as smart double quotes. The single quote is not interpreted as a smart quote: Alt+Shift+' gives a smart single quote. I see in cua.bind: \bind ~S-M-quotedbl quote-insert single \bind ~S-C-quotedbl self-insert \ What does ~ signify here? Andrew
Re: Double quotes in LyX-Code
Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: On 15/01/2013 1:03 a.m., Jürgen Spitzmüller wrote: Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays slanted double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+ in the standard setting (cua). Jürgen I use the cua bindings ( Windows Vista). On my present keyboard, I think previous ones, the single double quotes use the same key, being Shift+', but LyX interprets this as smart double quotes. The single quote is not interpreted as a smart quote: Alt+Shift+' gives a smart single quote. I see in cua.bind: \bind ~S-M-quotedbl quote-insert single \bind ~S-C-quotedbl self-insert \ What does ~ signify here? It's the not operator. In your case not shift. Stephan
Re: Double quotes in LyX-Code
On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? Liviu
Re: Double quotes in LyX-Code
Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. See the debug messages I get when trying to input Control- 1. Pure frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777248 keyState: Shift- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777248, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777248, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Shift_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 34 keyState: Shift- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 34, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 34, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is quotedbl frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 0 frontends/qt4/GuiApplication.cpp (1904): action first set to [] frontends/qt4/GuiApplication.cpp (1912): action now set to [] frontends/qt4/GuiApplication.cpp (1923): Key [action=][Shift-] frontends/qt4/GuiApplication.cpp (1936): Trying without shift frontends/qt4/GuiApplication.cpp (1938): Action now 2. Now Control- frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777249 keyState: Control- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777249, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777249, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Control_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777248 keyState: Shift-Control- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777248, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777248, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Shift_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 08:41:03.874: Befehl ist deaktiviertfrontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 50 keyState: Shift-Control- frontends/qt4/GuiKeySymbol.cpp (618): keyevent has isNull() text ! frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is 2 frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 0 frontends/qt4/GuiApplication.cpp (1904): action first set to [] frontends/qt4/GuiApplication.cpp (1912): action now set to [] frontends/qt4/GuiApplication.cpp (1923): Key [action=][Shift-Befehl-2] Stephan
Re: Double quotes in LyX-Code
Am 15.01.2013 um 08:46 schrieb Stephan Witt st.w...@gmx.net: Am 15.01.2013 um 08:06 schrieb Liviu Andronic landronim...@gmail.com: On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt st.w...@gmx.net wrote: Am 14.01.2013 um 21:56 schrieb Andrew Parsloe apars...@clear.net.nz: What does ~ signify here? It's the not operator. In your case not shift. I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? ~S-C-quotedbl is the key which translates to quotedbl plus control but without shift. If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to ~S-C-2. Sorry, obviously I should have written S-C-2 Stephan
Double quotes in LyX-Code
I notice when I press the double-quote key in a LyX-Code environment that LyX displays *slanted* double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. I can understand this for the usual text environments (Standard, Quote etc.) but for LyX-Code this seems wrong. LyX-Code is used for things like program listings, where double quotes are usually understood to be ASCII 34s. Copying and pasting code fragments containing slanted double quotes from a LyX-Code environment into a program will generally produce errors because of this. I've tripped on this before and have now assigned the shortcut command-sequence self-insert " to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the straight double quote symbol which LyX converts into slanted quotes.) I think a key combination to produce ASCII 34 should be part of "standard LyX", specifically for the LyX-Code environment. Andrew
Re: Double quotes in LyX-Code
On 2013-01-14, Andrew Parsloe wrote: > I notice when I press the double-quote key in a LyX-Code environment > that LyX displays *slanted* double quotes, nor does there seem to be any > shortcut specified to produce straight double quotes. I can understand > this for the usual text environments (Standard, Quote etc.) but for > LyX-Code this seems wrong. LyX-Code is used for things like program > listings, where double quotes are usually understood to be ASCII 34s. > Copying and pasting code fragments containing slanted double quotes from > a LyX-Code environment into a program will generally produce errors > because of this. > I've tripped on this before and have now assigned the shortcut > command-sequence self-insert " > to Ctrl+Shift+' to produce ASCII 34. (On my keyboard Shift+' is the > straight double quote symbol which LyX converts into slanted quotes.) I > think a key combination to produce ASCII 34 should be part of "standard > LyX", specifically for the LyX-Code environment. IMV, the right thing would be to turn off the "smart quote" feature in LyX-Code. To the developers: * Would it be possible to change the quote-inset so that it generates straight/literal quote characters in LyX-Code? * This would/should also solve the bug http://www.lyx.org/trac/ticket/7309 "program listings "lose" quotation marks of converted code" Günter
Re: Double quotes in LyX-Code
Andrew Parsloe wrote: > I notice when I press the double-quote key in a LyX-Code environment > that LyX displays slanted double quotes, nor does there seem to be any > shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+" in the standard setting (cua). Jürgen
Re: Double quotes in LyX-Code
On 15/01/2013 1:03 a.m., Jürgen Spitzmüller wrote: Andrew Parsloe wrote: I notice when I press the double-quote key in a LyX-Code environment that LyX displays slanted double quotes, nor does there seem to be any shortcut specified to produce straight double quotes. Straight quotes are bound to Shift+" in the standard setting (cua). Jürgen I use the cua bindings (& Windows Vista). On my present keyboard, & I think previous ones, the single & double quotes use the same key, " being Shift+', but LyX interprets this as smart double quotes. The single quote is not interpreted as a smart quote: Alt+Shift+' gives a smart single quote. I see in cua.bind: \bind "~S-M-quotedbl" "quote-insert single" \bind "~S-C-quotedbl" "self-insert \"" What does ~ signify here? Andrew
Re: Double quotes in LyX-Code
Am 14.01.2013 um 21:56 schrieb Andrew Parsloe <apars...@clear.net.nz>: > On 15/01/2013 1:03 a.m., Jürgen Spitzmüller wrote: >> Andrew Parsloe wrote: >>> I notice when I press the double-quote key in a LyX-Code environment >>> that LyX displays slanted double quotes, nor does there seem to be any >>> shortcut specified to produce straight double quotes. >> >> Straight quotes are bound to Shift+" in the standard setting (cua). >> >> Jürgen >> > I use the cua bindings (& Windows Vista). On my present keyboard, & I think > previous ones, the single & double quotes use the same key, " being Shift+', > but LyX interprets this as smart double quotes. The single quote is not > interpreted as a smart quote: Alt+Shift+' gives a smart single quote. > > I see in cua.bind: > > \bind "~S-M-quotedbl" "quote-insert single" > \bind "~S-C-quotedbl" "self-insert \"" > > What does ~ signify here? It's the not operator. In your case "not shift". Stephan
Re: Double quotes in LyX-Code
On Mon, Jan 14, 2013 at 10:38 PM, Stephan Wittwrote: > Am 14.01.2013 um 21:56 schrieb Andrew Parsloe : >> What does ~ signify here? > > It's the not operator. In your case "not shift". > I'm curious: What does this imply in terms of physical keyboard? That is, what should one press to get 'not shift'? Liviu
Re: Double quotes in LyX-Code
Am 15.01.2013 um 08:06 schrieb Liviu Andronic: > On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt wrote: >> Am 14.01.2013 um 21:56 schrieb Andrew Parsloe : >>> What does ~ signify here? >> >> It's the not operator. In your case "not shift". >> > I'm curious: What does this imply in terms of physical keyboard? That > is, what should one press to get 'not shift'? "~S-C-quotedbl" is "the key which translates to quotedbl plus control but without shift". If you don't have a keyboard with quotedbl without shift this binding does not match. IMHO, one has to change that e.g. for a german keyboard to "~S-C-2". See the debug messages I get when trying to input Control-" 1. Pure " frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777248 keyState: Shift- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777248, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777248, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Shift_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: " isAutoRepeat: 0 key: 34 keyState: Shift- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 34, with text '"' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 34, " frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is quotedbl frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 0 frontends/qt4/GuiApplication.cpp (1904): action first set to [] frontends/qt4/GuiApplication.cpp (1912): action now set to [] frontends/qt4/GuiApplication.cpp (1923): Key [action=][Shift-"] frontends/qt4/GuiApplication.cpp (1936): Trying without shift frontends/qt4/GuiApplication.cpp (1938): Action now 2. Now Control-" frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777249 keyState: Control- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777249, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777249, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Control_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 frontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 16777248 keyState: Shift-Control- frontends/qt4/GuiKeySymbol.cpp (623): Getting key 16777248, with text '' frontends/qt4/GuiKeySymbol.cpp (629): Setting key to 16777248, frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is Shift_L frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 1 08:41:03.874: Befehl ist deaktiviertfrontends/qt4/GuiWorkArea.cpp (1068): count: 1 text: isAutoRepeat: 0 key: 50 keyState: Shift-Control- frontends/qt4/GuiKeySymbol.cpp (618): keyevent has isNull() text ! frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiApplication.cpp (1881): KeySym is 2 frontends/qt4/GuiKeySymbol.cpp (644): isOK is 1 frontends/qt4/GuiKeySymbol.cpp (652): isModifier is 0 frontends/qt4/GuiApplication.cpp (1904): action first set to [] frontends/qt4/GuiApplication.cpp (1912): action now set to [] frontends/qt4/GuiApplication.cpp (1923): Key [action=][Shift-Befehl-2] Stephan
Re: Double quotes in LyX-Code
Am 15.01.2013 um 08:46 schrieb Stephan Witt: > Am 15.01.2013 um 08:06 schrieb Liviu Andronic : > >> On Mon, Jan 14, 2013 at 10:38 PM, Stephan Witt wrote: >>> Am 14.01.2013 um 21:56 schrieb Andrew Parsloe : What does ~ signify here? >>> >>> It's the not operator. In your case "not shift". >>> >> I'm curious: What does this imply in terms of physical keyboard? That >> is, what should one press to get 'not shift'? > > "~S-C-quotedbl" is "the key which translates to quotedbl plus control but > without shift". > > If you don't have a keyboard with quotedbl without shift this binding does > not match. > IMHO, one has to change that e.g. for a german keyboard to "~S-C-2". Sorry, obviously I should have written "S-C-2" Stephan
Re: Lyx code env.
On 01/14/2011 05:48 PM, S Nedunuri wrote: Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! LyX automatically defines it for you, as: \newenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} So you will need to redefine this environment in your preamble. It may be enough to do this: \renewenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\leftmargin}{0pt} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} Untested. Richard
Re: Lyx code env.
Thanks! that did the trick Richard Heck rgh...@comcast.net wrote in message news:4d319fec.30...@comcast.net... On 01/14/2011 05:48 PM, S Nedunuri wrote: Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! LyX automatically defines it for you, as: \newenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} So you will need to redefine this environment in your preamble. It may be enough to do this: \renewenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\leftmargin}{0pt} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} Untested. Richard
Re: Lyx code env.
On 01/14/2011 05:48 PM, S Nedunuri wrote: Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! LyX automatically defines it for you, as: \newenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} So you will need to redefine this environment in your preamble. It may be enough to do this: \renewenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\leftmargin}{0pt} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} Untested. Richard
Re: Lyx code env.
Thanks! that did the trick Richard Heck rgh...@comcast.net wrote in message news:4d319fec.30...@comcast.net... On 01/14/2011 05:48 PM, S Nedunuri wrote: Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! LyX automatically defines it for you, as: \newenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} So you will need to redefine this environment in your preamble. It may be enough to do this: \renewenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\leftmargin}{0pt} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} Untested. Richard
Re: Lyx code env.
On 01/14/2011 05:48 PM, S Nedunuri wrote: Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! LyX automatically defines it for you, as: \newenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} So you will need to redefine this environment in your preamble. It may be enough to do this: \renewenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\leftmargin}{0pt} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} Untested. Richard
Re: Lyx code env.
Thanks! that did the trick "Richard Heck" <rgh...@comcast.net> wrote in message news:4d319fec.30...@comcast.net... On 01/14/2011 05:48 PM, S Nedunuri wrote: Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! LyX automatically defines it for you, as: \newenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} So you will need to redefine this environment in your preamble. It may be enough to do this: \renewenvironment{lyxcode} {\par\begin{list}{}{ \setlength{\leftmargin}{0pt} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} Untested. Richard
Lyx code env.
Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! thanks
Lyx code env.
Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! thanks
Lyx code env.
Does anyone know how to adjust the left margin in the Lyx Code environment? I create an Algorithm float, and as soon as I set the env. of the contents to Lyx Code, the contents get shifted in. I have very little column space as it is, and I don't need a gratuitous indentation! thanks
Symbol for wrapped lines in LyX-Code
Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. I'll keep on searching and post anything interesting here. Thanks! Symbol for wrapped lines in LyX-Code -- View this message in context: http://lyx.475766.n2.nabble.com/Symbol-for-wrapped-lines-in-LyX-Code-tp5277467p5277467.html Sent from the LyX - Users mailing list archive at Nabble.com.
Re: Symbol for wrapped lines in LyX-Code
On 07/10/2010 07:20 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). There's no easy way to indicate wrapped lines automatically, so far as I know. You could do it manually, using ⏎, which you can insert using unicode-insert 0x23ce in the minibuffer. Richard
Re: Symbol for wrapped lines in LyX-Code
Was this an accidental repost? The same message was posted a few days ago (http://thread.gmane.org/gmane.editors.lyx.general/64608) and drew several responses, including my suggestion about the listings package. /Paul
Re: Symbol for wrapped lines in LyX-Code
Hi all, I had some problems joining the mailing list, so following Nabble's instructions, I re-posted again. Meanwhile, some people provided some nice suggestions and solutions there: http://thread.gmane.org/gmane.editors.lyx.general/64608 Have a look. I myself will try on Monday Thanks all -- View this message in context: http://lyx.475766.n2.nabble.com/Symbol-for-wrapped-lines-in-LyX-Code-tp5277467p5277989.html Sent from the LyX - Users mailing list archive at Nabble.com.
Symbol for wrapped lines in LyX-Code
Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. I'll keep on searching and post anything interesting here. Thanks! Symbol for wrapped lines in LyX-Code -- View this message in context: http://lyx.475766.n2.nabble.com/Symbol-for-wrapped-lines-in-LyX-Code-tp5277467p5277467.html Sent from the LyX - Users mailing list archive at Nabble.com.
Re: Symbol for wrapped lines in LyX-Code
On 07/10/2010 07:20 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). There's no easy way to indicate wrapped lines automatically, so far as I know. You could do it manually, using ⏎, which you can insert using unicode-insert 0x23ce in the minibuffer. Richard
Re: Symbol for wrapped lines in LyX-Code
Was this an accidental repost? The same message was posted a few days ago (http://thread.gmane.org/gmane.editors.lyx.general/64608) and drew several responses, including my suggestion about the listings package. /Paul
Re: Symbol for wrapped lines in LyX-Code
Hi all, I had some problems joining the mailing list, so following Nabble's instructions, I re-posted again. Meanwhile, some people provided some nice suggestions and solutions there: http://thread.gmane.org/gmane.editors.lyx.general/64608 Have a look. I myself will try on Monday Thanks all -- View this message in context: http://lyx.475766.n2.nabble.com/Symbol-for-wrapped-lines-in-LyX-Code-tp5277467p5277989.html Sent from the LyX - Users mailing list archive at Nabble.com.
Symbol for wrapped lines in LyX-Code
Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. I'll keep on searching and post anything interesting here. Thanks! Symbol for wrapped lines in LyX-Code -- View this message in context: http://lyx.475766.n2.nabble.com/Symbol-for-wrapped-lines-in-LyX-Code-tp5277467p5277467.html Sent from the LyX - Users mailing list archive at Nabble.com.
Re: Symbol for wrapped lines in LyX-Code
On 07/10/2010 07:20 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). There's no easy way to indicate wrapped lines automatically, so far as I know. You could do it manually, using ⏎, which you can insert using "unicode-insert 0x23ce" in the minibuffer. Richard
Re: Symbol for wrapped lines in LyX-Code
Was this an accidental repost? The same message was posted a few days ago (http://thread.gmane.org/gmane.editors.lyx.general/64608) and drew several responses, including my suggestion about the listings package. /Paul
Re: Symbol for wrapped lines in LyX-Code
Hi all, I had some problems joining the mailing list, so following Nabble's instructions, I re-posted again. Meanwhile, some people provided some nice suggestions and solutions there: http://thread.gmane.org/gmane.editors.lyx.general/64608 Have a look. I myself will try on Monday Thanks all -- View this message in context: http://lyx.475766.n2.nabble.com/Symbol-for-wrapped-lines-in-LyX-Code-tp5277467p5277989.html Sent from the LyX - Users mailing list archive at Nabble.com.
Re: Symbol for wrapped lines in LyX-Code
2010/7/6 pierrickuk luluflake2000-nab...@yahoo.fr: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. I met opposite practice to mark places when user has to hit enter with a graphical mark of typewriter's carriage return (↵) and proper comment about meaning of this sign in the book content. It could be grey to avoid confusion it is a part of text to enter. I saw a book where it was even a small photography (or rendering) of enter key. -- Manveru jabber: manv...@manveru.pl gg: 1624001 http://www.manveru.pl
Re: Symbol for wrapped lines in LyX-Code
On 7/6/2010 5:38 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. Step 1: Pick the glyph you want to use to indicate line wrapping. The Comprehensive LATEX Symbol List may help here. If necessary, install whatever font package it comes in, and add a \usepackage{...} to your preamble. Avoid symbols that occur only in math mode (which, sadly, accounts for most arrows); if there's a way to make them work, I haven't found it yet. Step 2: Rather than using LyX-code, use Insert Program Listing, which creates an inset using the listings package. Right-click the inset, click Settings ..., and on the Main Settings tab check Break long lines. You can leave the language setting at No language unless you think what you're writing matches one of the languages on the list fairly well. Step 3: Go to the advanced tab and, in the right pane, type 'prebreak=whatever', without the quotes and replacing whatever with the symbol you want. For instance, prebreak=\textbackslash will put '\' wherever wrapping occurs. That should do it. /Paul
Re: Symbol for wrapped lines in LyX-Code
That is actually very good. Is anybody putting together a Tricks with LyX guide? Because this should be in there... Yours, Morten On Tue, 06 Jul 2010 10:21:07 -0400, Paul A. Rubin ru...@msu.edu wrote: On 7/6/2010 5:38 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. Step 1: Pick the glyph you want to use to indicate line wrapping. The Comprehensive LATEX Symbol List may help here. If necessary, install whatever font package it comes in, and add a \usepackage{...} to your preamble. Avoid symbols that occur only in math mode (which, sadly, accounts for most arrows); if there's a way to make them work, I haven't found it yet. Step 2: Rather than using LyX-code, use Insert Program Listing, which creates an inset using the listings package. Right-click the inset, click Settings ..., and on the Main Settings tab check Break long lines. You can leave the language setting at No language unless you think what you're writing matches one of the languages on the list fairly well. Step 3: Go to the advanced tab and, in the right pane, type 'prebreak=whatever', without the quotes and replacing whatever with the symbol you want. For instance, prebreak=\textbackslash will put '\' wherever wrapping occurs. That should do it. /Paul -- __ Morten Juhl-Johansen Zölde-Fejér http://syntaktisk.dk * mj...@syntaktisk.dk
Re: Symbol for wrapped lines in LyX-Code
Morten Juhl-Johansen Zölde-Fejér morten at writtenandread.net writes: That is actually very good. Is anybody putting together a Tricks with LyX guide? Because this should be in there... Thanks. Tips and tricks abound on the wiki (http://wiki.lyx.org), but I just had a look there and did not see any tips regarding the listings package. The organization of the wiki is a bit, well, wiki-ish. If anyone wants to start a page and post this tip, feel free. /Paul
Re: Symbol for wrapped lines in LyX-Code
On Tue, Jul 6, 2010 at 3:28 PM, Morten Juhl-Johansen Zölde-Fejér mor...@writtenandread.net wrote: That is actually very good. Is anybody putting together a Tricks with LyX guide? Because this should be in there... You could always add this to the wiki. Regards Liviu
Re: Symbol for wrapped lines in LyX-Code
2010/7/6 pierrickuk luluflake2000-nab...@yahoo.fr: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. I met opposite practice to mark places when user has to hit enter with a graphical mark of typewriter's carriage return (↵) and proper comment about meaning of this sign in the book content. It could be grey to avoid confusion it is a part of text to enter. I saw a book where it was even a small photography (or rendering) of enter key. -- Manveru jabber: manv...@manveru.pl gg: 1624001 http://www.manveru.pl
Re: Symbol for wrapped lines in LyX-Code
On 7/6/2010 5:38 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. Step 1: Pick the glyph you want to use to indicate line wrapping. The Comprehensive LATEX Symbol List may help here. If necessary, install whatever font package it comes in, and add a \usepackage{...} to your preamble. Avoid symbols that occur only in math mode (which, sadly, accounts for most arrows); if there's a way to make them work, I haven't found it yet. Step 2: Rather than using LyX-code, use Insert Program Listing, which creates an inset using the listings package. Right-click the inset, click Settings ..., and on the Main Settings tab check Break long lines. You can leave the language setting at No language unless you think what you're writing matches one of the languages on the list fairly well. Step 3: Go to the advanced tab and, in the right pane, type 'prebreak=whatever', without the quotes and replacing whatever with the symbol you want. For instance, prebreak=\textbackslash will put '\' wherever wrapping occurs. That should do it. /Paul
Re: Symbol for wrapped lines in LyX-Code
That is actually very good. Is anybody putting together a Tricks with LyX guide? Because this should be in there... Yours, Morten On Tue, 06 Jul 2010 10:21:07 -0400, Paul A. Rubin ru...@msu.edu wrote: On 7/6/2010 5:38 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. Step 1: Pick the glyph you want to use to indicate line wrapping. The Comprehensive LATEX Symbol List may help here. If necessary, install whatever font package it comes in, and add a \usepackage{...} to your preamble. Avoid symbols that occur only in math mode (which, sadly, accounts for most arrows); if there's a way to make them work, I haven't found it yet. Step 2: Rather than using LyX-code, use Insert Program Listing, which creates an inset using the listings package. Right-click the inset, click Settings ..., and on the Main Settings tab check Break long lines. You can leave the language setting at No language unless you think what you're writing matches one of the languages on the list fairly well. Step 3: Go to the advanced tab and, in the right pane, type 'prebreak=whatever', without the quotes and replacing whatever with the symbol you want. For instance, prebreak=\textbackslash will put '\' wherever wrapping occurs. That should do it. /Paul -- __ Morten Juhl-Johansen Zölde-Fejér http://syntaktisk.dk * mj...@syntaktisk.dk
Re: Symbol for wrapped lines in LyX-Code
Morten Juhl-Johansen Zölde-Fejér morten at writtenandread.net writes: That is actually very good. Is anybody putting together a Tricks with LyX guide? Because this should be in there... Thanks. Tips and tricks abound on the wiki (http://wiki.lyx.org), but I just had a look there and did not see any tips regarding the listings package. The organization of the wiki is a bit, well, wiki-ish. If anyone wants to start a page and post this tip, feel free. /Paul
Re: Symbol for wrapped lines in LyX-Code
On Tue, Jul 6, 2010 at 3:28 PM, Morten Juhl-Johansen Zölde-Fejér mor...@writtenandread.net wrote: That is actually very good. Is anybody putting together a Tricks with LyX guide? Because this should be in there... You could always add this to the wiki. Regards Liviu
Re: Symbol for wrapped lines in LyX-Code
2010/7/6 pierrickuk <luluflake2000-nab...@yahoo.fr>: > > Hi there, > > I am posting this as 2 hours of searching got me nowhere so far. > I am writing some instructions manual to set up some software my company is > distributing. > For this I need to put some linux console commands for which I use the > LyX-code format. Everything is fine unless the line is too long and then get > wrapped. As some of our customer might not know much about linux, I am > afraid they might hit return at the end of the line. > So I am looking for a way to automatically indicate that the line is wrapped > to fit on a page (preferably by some special symbol not used in a > terminal/console). > > Maybe there is some LaTeX package that would work, or some trick I am not > aware of... Or maybe I'm looking in the wrong direction here. I met opposite practice to mark places when user has to hit enter with a graphical mark of typewriter's carriage return ("↵") and proper comment about meaning of this sign in the book content. It could be grey to avoid confusion it is a part of text to enter. I saw a book where it was even a small photography (or rendering) of enter key. -- Manveru jabber: manv...@manveru.pl gg: 1624001 http://www.manveru.pl
Re: Symbol for wrapped lines in LyX-Code
On 7/6/2010 5:38 AM, pierrickuk wrote: Hi there, I am posting this as 2 hours of searching got me nowhere so far. I am writing some instructions manual to set up some software my company is distributing. For this I need to put some linux console commands for which I use the LyX-code format. Everything is fine unless the line is too long and then get wrapped. As some of our customer might not know much about linux, I am afraid they might hit return at the end of the line. So I am looking for a way to automatically indicate that the line is wrapped to fit on a page (preferably by some special symbol not used in a terminal/console). Maybe there is some LaTeX package that would work, or some trick I am not aware of... Or maybe I'm looking in the wrong direction here. Step 1: Pick the glyph you want to use to indicate line wrapping. "The Comprehensive LATEX Symbol List" may help here. If necessary, install whatever font package it comes in, and add a \usepackage{...} to your preamble. Avoid symbols that occur only in math mode (which, sadly, accounts for most arrows); if there's a way to make them work, I haven't found it yet. Step 2: Rather than using LyX-code, use Insert > Program Listing, which creates an inset using the listings package. Right-click the inset, click Settings ..., and on the Main Settings tab check "Break long lines". You can leave the language setting at "No language" unless you think what you're writing matches one of the languages on the list fairly well. Step 3: Go to the advanced tab and, in the right pane, type 'prebreak=whatever', without the quotes and replacing whatever with the symbol you want. For instance, prebreak=\textbackslash will put '\' wherever wrapping occurs. That should do it. /Paul
Re: Symbol for wrapped lines in LyX-Code
That is actually very good. Is anybody putting together a Tricks with LyX guide? Because this should be in there... Yours, Morten On Tue, 06 Jul 2010 10:21:07 -0400, "Paul A. Rubin" <ru...@msu.edu> wrote: > On 7/6/2010 5:38 AM, pierrickuk wrote: >> >> Hi there, >> >> I am posting this as 2 hours of searching got me nowhere so far. >> I am writing some instructions manual to set up some software my company >> is >> distributing. >> For this I need to put some linux console commands for which I use the >> LyX-code format. Everything is fine unless the line is too long and then >> get >> wrapped. As some of our customer might not know much about linux, I am >> afraid they might hit return at the end of the line. >> So I am looking for a way to automatically indicate that the line is >> wrapped >> to fit on a page (preferably by some special symbol not used in a >> terminal/console). >> >> Maybe there is some LaTeX package that would work, or some trick I am not >> aware of... Or maybe I'm looking in the wrong direction here. >> > > Step 1: Pick the glyph you want to use to indicate line wrapping. "The > Comprehensive LATEX Symbol List" may help here. If necessary, install > whatever font package it comes in, and add a \usepackage{...} to your > preamble. Avoid symbols that occur only in math mode (which, sadly, > accounts for most arrows); if there's a way to make them work, I haven't > found it yet. > > Step 2: Rather than using LyX-code, use Insert > Program Listing, which > creates an inset using the listings package. Right-click the inset, > click Settings ..., and on the Main Settings tab check "Break long > lines". You can leave the language setting at "No language" unless you > think what you're writing matches one of the languages on the list > fairly well. > > Step 3: Go to the advanced tab and, in the right pane, type > 'prebreak=whatever', without the quotes and replacing whatever with the > symbol you want. For instance, > > prebreak=\textbackslash > > will put '\' wherever wrapping occurs. > > That should do it. > > /Paul -- __ Morten Juhl-Johansen Zölde-Fejér http://syntaktisk.dk * mj...@syntaktisk.dk
Re: Symbol for wrapped lines in LyX-Code
Morten Juhl-Johansen Zölde-Fejér writtenandread.net> writes: > > That is actually very good. > Is anybody putting together a Tricks with LyX guide? Because this should > be in there... > Thanks. Tips and tricks abound on the wiki (http://wiki.lyx.org), but I just had a look there and did not see any tips regarding the listings package. The organization of the wiki is a bit, well, wiki-ish. If anyone wants to start a page and post this tip, feel free. /Paul
Re: Symbol for wrapped lines in LyX-Code
On Tue, Jul 6, 2010 at 3:28 PM, Morten Juhl-Johansen Zölde-Fejérwrote: > That is actually very good. > Is anybody putting together a Tricks with LyX guide? Because this should > be in there... > You could always add this to the wiki. Regards Liviu
Re: in Lyx-Code quote, double quote, and back-tic not as expected.
Try the following: 1. In the preamble, \usepackage{textcomp}. 2. Rather than LyX-Code, Insert Program Listing and paste the code in there. 3. Right click anywhere in the listing, pick Settings..., go the Advanced tab, and insert columns=fullflexible and upquote=true. The former gets rid of kerning and the latter gets you the backtick character. (The vertical quote seems to take care of itself.) /Paul
Re: Re: in Lyx-Code quote, double quote, and back-tic not as expected.
Paul Rubin wrote, On Fri, 28 May 2010 15:35:16 + (UTC): Try the following: 1. In the preamble, \usepackage{textcomp}. 2. Rather than LyX-Code, Insert Program Listing and paste the code in there. 3. Right click anywhere in the listing, pick Settings..., go the Advanced tab, and insert columns=fullflexible and upquote=true. The former gets rid of kerning and the latter gets you the backtick character. (The vertical quote seems to take care of itself.) /Paul Thanks, I'll give those a try as soon as I get back to _that_ document. -- Todd Denniston Crane Division, Naval Surface Warfare Center (NSWC Crane) Harnessing the Power of Technology for the Warfighter
Re: in Lyx-Code quote, double quote, and back-tic not as expected.
Try the following: 1. In the preamble, \usepackage{textcomp}. 2. Rather than LyX-Code, Insert Program Listing and paste the code in there. 3. Right click anywhere in the listing, pick Settings..., go the Advanced tab, and insert columns=fullflexible and upquote=true. The former gets rid of kerning and the latter gets you the backtick character. (The vertical quote seems to take care of itself.) /Paul
Re: Re: in Lyx-Code quote, double quote, and back-tic not as expected.
Paul Rubin wrote, On Fri, 28 May 2010 15:35:16 + (UTC): Try the following: 1. In the preamble, \usepackage{textcomp}. 2. Rather than LyX-Code, Insert Program Listing and paste the code in there. 3. Right click anywhere in the listing, pick Settings..., go the Advanced tab, and insert columns=fullflexible and upquote=true. The former gets rid of kerning and the latter gets you the backtick character. (The vertical quote seems to take care of itself.) /Paul Thanks, I'll give those a try as soon as I get back to _that_ document. -- Todd Denniston Crane Division, Naval Surface Warfare Center (NSWC Crane) Harnessing the Power of Technology for the Warfighter
Re: in Lyx-Code quote, double quote, and back-tic not as expected.
Try the following: 1. In the preamble, \usepackage{textcomp}. 2. Rather than LyX-Code, Insert > Program Listing and paste the code in there. 3. Right click anywhere in the listing, pick Settings..., go the Advanced tab, and insert columns=fullflexible and upquote=true. The former gets rid of kerning and the latter gets you the backtick character. (The vertical quote seems to take care of itself.) /Paul
Re: Re: in Lyx-Code quote, double quote, and back-tic not as expected.
Paul Rubin wrote, On Fri, 28 May 2010 15:35:16 + (UTC): > Try the following: > > 1. In the preamble, \usepackage{textcomp}. > > 2. Rather than LyX-Code, Insert > Program Listing and paste the code in there. > > 3. Right click anywhere in the listing, pick Settings..., go the Advanced tab, > and insert columns=fullflexible and upquote=true. The former gets rid of > kerning and the latter gets you the backtick character. (The vertical quote > seems to take care of itself.) > > /Paul > > Thanks, I'll give those a try as soon as I get back to _that_ document. -- Todd Denniston Crane Division, Naval Surface Warfare Center (NSWC Crane) Harnessing the Power of Technology for the Warfighter
in Lyx-Code quote, double quote, and back-tic not as expected.
Version LyX 1.6.5 (from EPEL repository) on CentOS 5.5 Issue 1: Am I really expecting the wrong behavior here? Open a new LyX document (and for complete disclosure set the fonts to Palatino, Helvetica, Courier) type Test and set it to type Section ##not strictly necessary but this is the way I did it. Set the type of text to LyX-Code ##paste in: for i in `seq 1 10|awk '{print $1}'`; \ do \ echo Counter $i; \ done ## click the view pdf button in the PDF select the whole for loop (for to done) and paste it into a terminal. find out that s are ?Smart? double quotes. 's are ?Smart? quotes. ` are I have no idea. i is i`, I assume this is due to a ligature(is that the correct word?). As annoying as that is, I did find in the interface that I am allowed to type: Ctrl+ to get real ASCII double quotes. Ctrl+' to get real ASCII quotes. no way to get a real `. no way to get a real i. Does anyone know how to get real back-tics (`) and i? When I was working under Fedora Core 4 (and before) with IIRC LyX 1.4.?? I did not have these issues with any text type, i.e., it did not matter where I was in any portion of the PDF output I could copy and paste and get ASCII out. It seemed to me that Does anyone know which of the following product line upgrades would have changed the behavior: LyX | LaTeX | PDFLaTeX | tetex | evince ? I have seen OCR'ed PDFs that have ASCII text below the picture of the document, is there a way to get the LyX stack to make those kind of PDFs, i.e., have a typeset version the gets shown printed, but a text version that gets copy and pasted? Issue 2: It is also troubling when I export to plain text and find the above ?Smart? transformations have taken place in the text output. Is there a a way to get a true export to ASCII text? Thanks. -- Todd Denniston Crane Division, Naval Surface Warfare Center (NSWC Crane) Harnessing the Power of Technology for the Warfighter newfile1.lyx Description: application/lyx