Re: Error using pdfpages package with ERT and relative paths
Venable writes: > Apologies for the near-repeat of the previous post. I googled the heck of this problem and it seems yesterday's posts had not been captured yet.
Error using -pdfpages- package with ERT and relative paths
Dear LyX users, I am having some trouble using the -pdfpages- package to insert some external PDFs into my LyX document. Everything works fine when I use the Insert - File - External Material menu option. However, for transparency and ease of reading, I would prefer to use ERT and the -includepdf- command. I am able to use the \includepdf command writing directly in LaTeX as long as I specify the absolute path of the pdf to be included, e.g. \includepdf{c:/research/dummy.pdf} or \includepdf{c:/research/dummy} (whether the pdf extension is specified does not seem to matter) For collaboration and for cross-project re-use, it would be very useful if it were not necessary to specify the absolute path, but use relative paths instead. For example, if the LyX document were in the c:/research/ folder, it would be preferable to use just \includepdf{dummy} However, this does not seem to be possible.(1) As an example, I imported the example tex file provided in the pdfpages documentation (2) into LyX and attempted to export to PDF. With File - Export - pdflatex, no pdf is created. When I click View PDF, I get the following error message: File does not exist: C:/Users/MyName/AppData/Local/Temp/lyx_tempdir.Hp5404/lyx_tmpbuf1/pdf-ex.pdf Does anyone have a suggestion on how to fix this? Many thanks in advance. PS (1) This is a bit surprising, given that this (includepdf with only a relative path) is what is created in LaTeX using the Include External Document menu option and exporting to Plain TeX. (2) Available at http://www-hep2.fzu.cz/tex/texmf-dist/doc/latex/pdfpages/ In fact, this is what is created using the Include External Document menu option and exported to Plain TeX.
Re: Output: Right margin problem for a section* (standard font:typewriter,italic)
Joe(theWordy)Philbrook writes: > However what I don't understand why, whether LaTeX can properly > justify typewriter font or not, surely such a powerful typesetting > system could detect that the line was going to exceed the intended > margin, and at least adjust "word wrap" to move the offending word > down to the next line. (of course then the next line would have to be > readjusted, then the next ad infinum...) It would still fail true > justification, but at least the text would remain inside the margins. LaTeX has internal algorithms to measure the "badness" of a block of text, and it makes spacing and line-wrapping decisions to minimize badness given some constraints. Violating a margin is allowed with some penalties; putting large amounts of space between words is allowed with some penalties. Under most circumstance, hyphenation is allowed with some penalties. In your case, there were apparently places where violating the margin was "cheaper". I suspect that a TeXpert could find and adjust the weights assigned to various forms of typographical malfeasance such that you'd be very unlikely to get a margin violation. (That's beyond my level of expertise.) I also suspect that if you did that, it would end up either looking like a ragged right paragraph (if you used small violations for short lines and somewhat large violations for chasms between words) or the first solution I mentioned (ERT to adjust inter-word spacing) if you continued to enforce justification and allowed funky inter-word spacing. Your comment about moving the offending word is essentially the latter case. > > And if there is a reason I don't understand, why, LaTeX can't do this, I suspect the authors did not want to make the decision above (which remedy to adopt) for you. > Then perhaps LyX itself {could/should?} in the spirit of letting it's > users focus on content, detect the known problem and make the > evidently complex coding adjustments necessary to alter the right > margin {I gather with LaTeX this is controlled by line length settings, > which I don't think a LyX user should need to know how to override in > such a way that the override only affects the typewriter font > paragraph(s)} The ERT fix is not complex, just a bit obscure. I suspect one could create a module to implement it as a LaTeX environment, although I'm not positive. It's possible the user would need to futz with the values used in the spacing adjustment (meaning that larger tolerances might be needed in some situations, and smaller tolerances might produce nicer looking output in others). /Paul
Re: Footnote location
Hi guys, Thank you all for helping me. I've found the bug and fixed it. It was just, that I've not properly done the format BEFORE writing the whole text, but afterwards. So it crashed my opinions and it happened what I've explained here. Sorry for asking such silly questions, like it looks now afterwards. But the first thing I've asked, how to manage the gap between the text and the footnote was really helpful. Thank you all for the support! SP Am 03.04.2010 um 23:35 schrieb Ingar Pareliussen: > If I understand your request correctly you want the footnotes always to > appear on > bottom of the page? This is what usually should happen, if you do not > use \raggedbottom or similar (irrc). > > Try to use the footmisc package. It is probably in your latex-installation, > if not install it from ctan. > (http://mirror.ctan.org/macros/latex/contrib/footmisc) > > Write something like this is Documents->Settings-->LaTeX Preamble > > \usepackage[bottom]{footmisc} > > To learn more about the footmisc (it has a lot of options): > http://mirror.ctan.org/macros/latex/contrib/footmisc/footmisc.pdf > > If this don't work we would need a small lyx file demonstrating the problem. > > And please do not top post. It makes it less likely for some of us older > folks to reply ;-). (and it is much easier to follow a thread in > mail-archive when inline quoting is used, just try it :)) > > hth, > Ingar Pareliussen
RE: Footnote location
If I understand your request correctly you want the footnotes always to appear on bottom of the page? This is what usually should happen, if you do not use \raggedbottom or similar (irrc). Try to use the footmisc package. It is probably in your latex-installation, if not install it from ctan. (http://mirror.ctan.org/macros/latex/contrib/footmisc) Write something like this is Documents->Settings-->LaTeX Preamble \usepackage[bottom]{footmisc} To learn more about the footmisc (it has a lot of options): http://mirror.ctan.org/macros/latex/contrib/footmisc/footmisc.pdf If this don't work we would need a small lyx file demonstrating the problem. And please do not top post. It makes it less likely for some of us older folks to reply ;-). (and it is much easier to follow a thread in mail-archive when inline quoting is used, just try it :)) hth, Ingar Pareliussen
Re: Output: Right margin problem for a section* (standard font:typewriter,italic)
It would appear that on Apr 3, Paul A. Rubin did say: > Seems to be a "quirk" of LaTeX specific to typewriter font. Since typewriter > font is intended to have fixed spacing, LaTeX can't justify things evenly. > There's a fix at > http://newsgroups.derkeiler.com/Archive/Comp/comp.text.tex/2005-09/msg4.html > that works on your document if you don't mind variable spacing between words. > Another possibility is to make that section of text left justified (ragged > right) rather than fully justified. Under other circumstance a third option > would be to use the hyphenat package to allow hyphenation of typewriter text. > Unfortunately, that would require a change to your prose style -- you're not > using long enough words in that section. :-) (I tested this -- hyphenation > did not cure the problem.) Thank you for the link, and the suggestion on left justification. I'll have to experiment... However what I don't understand why, whether LaTeX can properly justify typewriter font or not, surely such a powerful typesetting system could detect that the line was going to exceed the intended margin, and at least adjust "word wrap" to move the offending word down to the next line. (of course then the next line would have to be readjusted, then the next ad infinum...) It would still fail true justification, but at least the text would remain inside the margins. And if there is a reason I don't understand, why, LaTeX can't do this, Then perhaps LyX itself {could/should?} in the spirit of letting it's users focus on content, detect the known problem and make the evidently complex coding adjustments necessary to alter the right margin {I gather with LaTeX this is controlled by line length settings, which I don't think a LyX user should need to know how to override in such a way that the override only affects the typewriter font paragraph(s)} However both the preceding paragraphs project my idealistic concept of what LyX/LaTeX should do to keep it's user base concentrating on content, rather than any belief that either idea will ever come into play. So I'm curious, would there maybe be something I could put in an ert box that saves the current line length settings some place that I could restore them from after I then used some more LyX code to simply reduce the line length of the affected portion(s) of a document? One other thought, even if LyX can't be expected to 'automatically' compensate for this LaTeX "quirk" is it feasible that a line length element could someday be added to LyX's paragraph settings??? It would appear that on Apr 3, Steve Litt did say: > > On Saturday 03 April 2010 02:48:12 Joe(theWordy)Philbrook wrote: > > > I get similar, but slightly better results from setting the environment to > > quotation. Like verse, the righthand margin appears the same for both the > > leftside and rightside pages. But with quotation it's slightly better > > because the closest it gets to the righthand edge of the "paper" is > > approximately doubled to a half inch or so... But it's still not right. > > And besides, Like I said, I don't want it formatted as verse. And I'm not > > quoting anyone... > > I'd like to frame the preceding paragraph and send it to everyone I know. In > a > world where most people jam in codes everywhere, you actually try to make > your > styles represent the intent of the writing. Well it's not that I'm against inserting codes whenever I need a down and dirty fix for something. But rather it's a combination of not having taken a course in typesetting with LaTeX, having difficulty remembering the things I have learned (I blame that on CRS), and last but certainly not least, the fact that I'm sold on the idea of letting my document processor (LyX) free me from micro-managing the details of my document(s) appearance so that I can concentrate on the content. That last point was why I chose to try to learn to use LyX about 6 years ago, even though I already realized that for me the learning curve would be painfully slow. But if you think it would help encourage style based solutions, please feel free to copy, modify, and publish any or all of my post with the sole exception of the copyrighted text embedded in the example attachment. - - - - - - - - -< snip/glue/snip >- - - - - - - - - - > What you want is the MEANING of "Joe's special paragraph" but a LOOK similar > to the standard quotation environment. So do something like this in a layout > file: > > = > Preamble > \newenvironment{joesspecialparagraphL} > { > \begin{quotation} > % Add any tweaks you want here > }{ > % Add any ending tweaks you want here > \end{quotation} > } > EndPreamble > > > Style JoesSpecialParagraph > CopyStyle Quotation > LatexType Environment > LatexName joesspecialparagraphL > End > = > > The part where I discuss tweaks is where you modify the look of the
Re: References style
On 4/3/2010 11:32 AM, rgheck wrote: On 04/03/2010 11:23 AM, Paul A. Rubin wrote: On 4/3/2010 11:15 AM, rgheck wrote: On 04/03/2010 10:54 AM, Paul A. Rubin wrote: Insert \renewcommand{\refname}{\rmfamily\mdseries\begin{center} References\end{center}} in ERT early in the document. Or put it in the preamble, where it won't clutter the text. Doesn't seem to work in the preamble -- I think something (not sure what) loads or is processed after the preamble and asserts the standard heading format at that point. Hmm. Perhaps this is done at the beginning of the document. rh Babel loads after the preamble, so if it redefines \refname, that would be the culprit. /Paul
Re: Output: Right margin problem for a section* (standard font:typewriter,italic)
On Saturday 03 April 2010 02:48:12 Joe(theWordy)Philbrook wrote: > I get similar, but slightly better results from setting the environment to > quotation. Like verse, the righthand margin appears the same for both the > leftside and rightside pages. But with quotation it's slightly better > because the closest it gets to the righthand edge of the "paper" is > approximately doubled to a half inch or so... But it's still not right. > And besides, Like I said, I don't want it formatted as verse. And I'm not > quoting anyone... Hi Joe, What you want is the MEANING of "Joe's special paragraph" but a LOOK similar to the standard quotation environment. So do something like this in a layout file: = Preamble \newenvironment{joesspecialparagraphL} { \begin{quotation} % Add any tweaks you want here }{ % Add any ending tweaks you want here \end{quotation} } EndPreamble Style JoesSpecialParagraph CopyStyle Quotation LatexType Environment LatexName joesspecialparagraphL End = The part where I discuss tweaks is where you modify the look of the quotation environment to match your desired look. So you'd put margin changes, font changes, and any decorations (boxes, shaded boxes or whatever) in the tweak areas. I highly recommend you separate the LaTeX code (the stuff between the Preamble and EndPreamble from the LyX code (the stuff between "Style" and "End"). LyX allows you to stick a Preamble/EndPreamble pair right in the LyX style, and a lot of people recommend that, but under certain arcane conditions reusable code can break in a non-obvious way when you do that. I always put my LaTeX in the upper part of my layout file and the LyX code in the lower part so I don't have these problems. As far as how to make a layout file, I have a bunch of documentation on the subject here: http://www.troubleshooters.com/linux/lyx/index.htm SteveT Steve Litt Recession Relief Package http://www.recession-relief.US Twitter: http://www.twitter.com/stevelitt
Re: Output: Right margin problem for a section* (standard font:typewriter,italic)
On Saturday 03 April 2010 02:48:12 Joe(theWordy)Philbrook wrote: > I get similar, but slightly better results from setting the environment to > quotation. Like verse, the righthand margin appears the same for both the > leftside and rightside pages. But with quotation it's slightly better > because the closest it gets to the righthand edge of the "paper" is > approximately doubled to a half inch or so... But it's still not right. > And besides, Like I said, I don't want it formatted as verse. And I'm not > quoting anyone... I'd like to frame the preceding paragraph and send it to everyone I know. In a world where most people jam in codes everywhere, you actually try to make your styles represent the intent of the writing. There's an easy answer to your problem, and I'll tell it to you in another email. StevET Steve Litt Recession Relief Package http://www.recession-relief.US Twitter: http://www.twitter.com/stevelitt
Re: Offer... for technical writing
In my humble opinion, this offer of Mr Noronha should be appreciated. A touch of an artist from a non-programming area would be a very valuable addition to LyX project. - Original Message - From: "Frederick Noronha" To: Sent: Saturday, April 03, 2010 2:54 AM Subject: Offer... for technical writing Dear all: I am a journalist and writer, and a heavy user of Lyx. Please let me know if you need any help (volunteering, without fee) to help write or edit Lyx help files for users. I am not a techie, but understand the software ... with guidance I could do it. My English skills are near-native speaker level. FN -- Frederick Noronha Books from Goa :: http://goa1556.goa-india.org
Re: References style
On 04/03/2010 11:23 AM, Paul A. Rubin wrote: On 4/3/2010 11:15 AM, rgheck wrote: On 04/03/2010 10:54 AM, Paul A. Rubin wrote: Insert \renewcommand{\refname}{\rmfamily\mdseries\begin{center} References\end{center}} in ERT early in the document. Or put it in the preamble, where it won't clutter the text. Doesn't seem to work in the preamble -- I think something (not sure what) loads or is processed after the preamble and asserts the standard heading format at that point. Hmm. Perhaps this is done at the beginning of the document. rh
Re: things that I miss in lyx
On 04/03/2010 11:27 AM, Wolfgang Engelmann wrote: Am Saturday 03 April 2010 15:13:22 schrieb rgheck: On 04/03/2010 02:27 AM, Wolfgang Engelmann wrote: Just wondering: Would the following be difficult to implement in Lyx or to use it via enter>file> 'external material' ? Wolfgang From http://ctan.tug.org/tex-archive/help/Catalogue/entries/texdirflatten.html Collect files related to a LaTeX job in a single directory. The Perl script parses a LaTeX file recursively, scanning all child files, and collects details of any included and other data files. These component files, are then all put into a single directory (thus “flattening” the document’s directory tree). The author is Cengiz Gunay. This looks like something that one would call as part of the converter chain. and how could I do it? Define a new format, ltxpak, and then declare texdirflatten as a latex-->ltxpak converter. With appropriate arguments, of course. This all gets done under Tools>Preferences>File Handling. There is a complication, namely, that everything is going to happen here in LyX's temporary directory. So what I think will happen is that texdirflatten will create its directory at e.g. /tmp/lyx_tmpdir.X0765/lyx_tmpbuf0/flat/ and now the question is: How do we export this? i.e., copy it to the original file location? Answer: We define a "copier", and tell it to copy this directory to the original document directory. Have a look at the ext_copy.py copier that is used with the LaTeX-->HTML converters. You may be able to use that, or at least to adapt it to your purposes. Copiers, etc, are all discussed in the Customization manual. rh
Re: References style
On 4/3/2010 11:15 AM, rgheck wrote: On 04/03/2010 10:54 AM, Paul A. Rubin wrote: Insert \renewcommand{\refname}{\rmfamily\mdseries\begin{center} References\end{center}} in ERT early in the document. Or put it in the preamble, where it won't clutter the text. Doesn't seem to work in the preamble -- I think something (not sure what) loads or is processed after the preamble and asserts the standard heading format at that point. /Paul
Re: References style
On 04/03/2010 10:54 AM, Paul A. Rubin wrote: On 4/1/2010 11:32 AM, Carlos Ramirez wrote: Does anyone know how to center and un-bold the "References" title using bibtext ? Insert \renewcommand{\refname}{\rmfamily\mdseries\begin{center} References\end{center}} in ERT early in the document. Or put it in the preamble, where it won't clutter the text. also how to avoid the blank page after the references is inserted ? I don't think this is a general phenomenon. It probably is a function either of the document class you are using or something specific in your file. If I write a short test file using the article class, insert a BibTeX bibliography, and add some text after the bibliography, the extra text occurs on the same page as the bibliography (with a little extra vertical space separating them. In some classes, chapters always start on an odd page, and the references are formatted in such classes as an unnumbered chapter usually. rh
Re: things that I miss in lyx
Am Saturday 03 April 2010 15:13:22 schrieb rgheck: > On 04/03/2010 02:27 AM, Wolfgang Engelmann wrote: > > Just wondering: > > > > Would the following be difficult to implement in Lyx or to use it via > > enter>file> 'external material' ? > > > > Wolfgang > > > > From > > http://ctan.tug.org/tex-archive/help/Catalogue/entries/texdirflatten.html > > > > Collect files related to a LaTeX job in a single directory. > > > > The Perl script parses a LaTeX file recursively, scanning all child > > files, and collects details of any included and other data files. These > > component files, are then all put into a single directory (thus > > flattening the documents directory tree). > > > > The author is Cengiz Gunay. > > This looks like something that one would call as part of the converter > chain. > > rh and how could I do it? Wolfgang -- - Wolfgang Engelmann Schlossgartenstrasse 22 D-72070 Tübingen Tel 07071 68325
Re: References style
On 4/1/2010 11:32 AM, Carlos Ramirez wrote: Does anyone know how to center and un-bold the "References" title using bibtext ? Insert \renewcommand{\refname}{\rmfamily\mdseries\begin{center} References\end{center}} in ERT early in the document. also how to avoid the blank page after the references is inserted ? I don't think this is a general phenomenon. It probably is a function either of the document class you are using or something specific in your file. If I write a short test file using the article class, insert a BibTeX bibliography, and add some text after the bibliography, the extra text occurs on the same page as the bibliography (with a little extra vertical space separating them. /Paul
Re: Bizarre file not found error using pdfpages
Richard Brown wrote: > Using pdfpages to put a pdf doc into my komabook book (lyx 1.6 on Ubuntu > 9.10), instead of inserting the file I get a bizarre file not found error, > which states > > ' Error: pdfpackages error- can't find file > 10_home_richard_Desktop_book2_form' Which version of LyX exactly? LyX 1.6.5 included the following bug fix: - When using the PDF-Pages external inset, copy the included PDF file to the temporary directory, where LaTeX searches it (bug 6345). Jürgen
Re: Bizarre file not found error using pdfpages
On 4/3/2010 7:03 AM, Richard Brown wrote: Using pdfpages to put a pdf doc into my komabook book (lyx 1.6 on Ubuntu 9.10), instead of inserting the file I get a bizarre file not found error, which states ' Error: pdfpackages error- can't find file 10_home_richard_Desktop_book2_form' The file it should find, but obviously doesn't, is /./home/richard/Desktop/book2/form but with the backslash changed for all those underscores I'm not surprised the package can't find it. And what gives with the number 10? Anyone any idea what's going on? When LyX compiles a document, it creates a temporary directory (typically under /tmp on a Linux system), exports the necessary LaTeX file there, copies ancillary files (such as images) there, does any necessary format conversions of images there, then runs latex (or pdflatex, or whatever), bibtex (if needed) etc. in that temp directory. Files copied from other directories have their names "mangled" to indicate the source path, with path separators changed to underscores. In mangling the file name, LyX prepends a number (not sure why; might be to avoid naming clashes). So the mangled file name is in fact correct behavior. The question is why it's not found. If you repeat the process and open the LyX temp buffer (Tools > Preferences > Paths > Temporary directory will point you to the parent directory of the temporary buffer) in a file manager, you should find a copy of your PDF file there with the corresponding name. If not, then apparently LyX was unable to copy it there for some reason. Did you use Insert > File > External material, with the PDFPages template selected, to insert the file? Also, did you specify the path with that "/." at the beginning (rather than "/home/...")? /Paul
Re: Output: Right margin problem for a section* (standard font:typewriter,italic)
Seems to be a "quirk" of LaTeX specific to typewriter font. Since typewriter font is intended to have fixed spacing, LaTeX can't justify things evenly. There's a fix at http://newsgroups.derkeiler.com/Archive/Comp/comp.text.tex/2005-09/msg4.html that works on your document if you don't mind variable spacing between words. Another possibility is to make that section of text left justified (ragged right) rather than fully justified. Under other circumstance a third option would be to use the hyphenat package to allow hyphenation of typewriter text. Unfortunately, that would require a change to your prose style -- you're not using long enough words in that section. :-) (I tested this -- hyphenation did not cure the problem.) /Paul
Re: Offer... for technical writing
On 04/02/2010 07:54 PM, Frederick Noronha wrote: Dear all: I am a journalist and writer, and a heavy user of Lyx. Please let me know if you need any help (volunteering, without fee) to help write or edit Lyx help files for users. I am not a techie, but understand the software ... with guidance I could do it. My English skills are near-native speaker level. FN Thanks for the offer. My first suggestion would be to describe to the LyX documentation list. It's low volume, but issues relating to the docs tend to get discussed there. Generally, though, the documentation is written by whoever has the initiative to do it. So if there's something you think isn't clear, could be better explained, or just isn't included, then try to do better and post your changes to the docs list. The maintainer of the relevant manual will then discuss them with you. For the tutorial, user's guide, and math manual, that's Uwe Stohr; for the customization and additional features manuals (I think), that's me. Others don't have a dedicated maintainer. Hint: Use change tracking when you make these sorts of changes, so it's easy for us to identify them. Richard
Re: things that I miss in lyx
On 04/03/2010 02:27 AM, Wolfgang Engelmann wrote: Just wondering: Would the following be difficult to implement in Lyx or to use it via enter>file> 'external material' ? Wolfgang From http://ctan.tug.org/tex-archive/help/Catalogue/entries/texdirflatten.html Collect files related to a LaTeX job in a single directory. The Perl script parses a LaTeX file recursively, scanning all child files, and collects details of any included and other data files. These component files, are then all put into a single directory (thus “flattening” the document’s directory tree). The author is Cengiz Gunay. This looks like something that one would call as part of the converter chain. rh
Bizarre file not found error using pdfpages
Using pdfpages to put a pdf doc into my komabook book (lyx 1.6 on Ubuntu 9.10), instead of inserting the file I get a bizarre file not found error, which states ' Error: pdfpackages error- can't find file 10_home_richard_Desktop_book2_form' The file it should find, but obviously doesn't, is /./home/richard/Desktop/book2/form but with the backslash changed for all those underscores I'm not surprised the package can't find it. And what gives with the number 10? Anyone any idea what's going on? TIA Richard
Re: Using pdfsync with LyX
Ami wrote: > I configured LyX to use Sumatra, but now- what should I do to make the sync > work? The wiki page discusses ``reverse search", while I'm interested in > the opposite direction (line in LyX -> line [or page] in pdf when viewing > it). As I wrote in another post: this is not possible. LyX currently only supports reverse search, not forward search. Jürgen