Re: latex paragraph export
Andre, Thanks for your reply. It finally occurred to me to look at the html source produced by latex2html (view source while displayed by browser) The header info contained a reference to a stylesheet. This turned out to be an external file with an extension of .css (cascading style sheets) that was generated by latex2html. I hunted around on the net and found specs for css files. Was able to solve the problem! For indented paragraphs with no line skips in html display generated by latex2html: P {text-indent: 2em} P {margin-top: 0em} add the above 2 commands to the filename.css file created automatically by latex2html Probably there is some style or other that would cause this to happen, but I can't find it or figure out how latex2html references it. How pdflatex figures it out is a mystery. tth blows up on me, so it may work fine; I don't know. My novel goes up tomorrow, worldwide (love the net), at: http://home.maine.rr.com/wetterau John
latex paragraph export
Lyx 1.1.3 is producing great PS output with indented paragraphs and no line skip between them. Pdflatex produces the same output in PDF format (indented paragraphs with no line skip). Latex2html, however, takes the same .tex file that was used by pdflatex and produces html code with no paragraph indents and with a line skip between each paragraph. Have been through the latex2html docs and mail list archives and can find no switch or way to control this. The .tex file also has no indents and line skips, so latex2html seems to be converting it exactly. Yet pdflatex takes the same input and produces indented PDF code. How does it know to do this, while latex2html doesn't? Any ideas? There must be a simple answer, but after a day of screwing around I've been unable to find it. Thanks, John P.S. when this problem is solved, anyone who wishes to read my novel "Joe Burke's Last Stand" can, at: http://home.maine.rr.com/wetterau
more thanks
Thanks indeed, all you developers. I am working on my second novel using LyX. I converted from Widows/Word to Linux, LateX, and LyX. What a joy to use. Every morning I start rewriting work from the day before, perfectly typeset. Review copies that I print at home look great. So far, only one editor has refused PDF files, and he accepted ASCII (which only took a day's work to meet his requirements). No crashes. No hassles. Just what a tool should be. And I don't even use the fancy stuff--math editing, bibliograpy, cross referencing, tables, etc. If I have to stop writing novels to make some money, I can switch to technical writing without having to change tools. You guys are heroes. Who is going to write a good "Using LyX" book? Should be a market for it. Although, what language would one use?
dvips scalable fonts
Nimrod, I searched on GhostScript in AltaVista and came up with: http://www.cs.wisc.edu/~ghost/aladdin/get550.html The rpm is: ghostscript-5.50-2.i386.rpm I installed with the upgrade parameter: rpm -Uvh ./ghostscript-5.50-2.i386.rpm as I had RedHat 5.2 with ghostscript 4.03 already installed. Reuben Thomas steered me in the right direction. Many thanks. John
dvips scalable fonts
All, problem disappeared when I followed Reuben's advice to get GhostScript 5.50. There is an rpm available for download that upgraded RedHat 5.2 GhostScript 4.03 perfectly. ps2pdf in the new version seems to substitute scalable fonts for the bitmapped.
dvips Type 1 font output
Hi, plowing along trying to get pdf files of a reasonable size. So far I have been unable to force dvips to use Type 1 scalable fonts which, reportedly, allow ps2pdf to produce small pdf files (rather than 10X the size of the ps file which I get using dvips in the normal configuration). I have the Adobe paper by Kevin Whitehouse on creating quality Adobe pdf files from TeX with DVIPS, but the specifics elude me. How do you create a fontmap that lists all the fonts that DVIPS should not use as bitmapped? Where does one find the equivalent font names that should be substituted? My document (book) is plain vanilla Times Roman, no figures, nothing fancy. I found all sorts of font map files, and experimented with "p +fontname.map" in a .dvipsrc file located in my home directory, but I could detect no change in the output from dvips (once converted with ps2pdf and displayed with Acrobat 3.0). Probably the solution is simpler than I think. Has anyone succeeded in forcing dvips to use Type 1 scalable fonts? I have RedHat 5.2 and LyX 1.01. I have pStill downloaded but have not compiled and tried it yet, as I'm assuming that it would not be any better than ps2pdf with dvips output that uses bitmapped fonts. The ability to distribute small pdf files would seem to be useful to many. Maybe we can document this procedure in one place. Greets, John
Re: LyX to Adobe PDF
Thierry, Reuben, Thanks a lot. That's a big help.
LyX to Adobe PDF
All, Is there a way to convert LyX output to Adobe PDF? Without going through ASCII export (and losing curly quotes)? LyX is marvelous for writing and printing. Now if I can find a way to transfer files to non-LyXers, all will be well. Greets, John
converting straight quotes to curly
All, I forgot about non-dialog uses of quotes (around a word or term, to emphasize) within a sentence. Thanks, Andre. The attached code takes care of almost all those cases. To be properly user friendly, this routine should prompt for input and output file names and should return a quick error check, separate counts of left and of right curly quotes, to see if they are equal. Or, fancier, some kind of stack push/pop routine to check nested levels for mismatched pairs and, when finding one, generating a location error message. There are too many possibilities to catch them all automatically. It would probably be better to keep the replacement algorithm simple, get 99.9% of them, and then let the user adjust the remaininder to his or her satisfaction. Just my opinion, of course. Ideally, this routine should be part of the ascii import code (a switch: convert straight quotes?) or else offered as a utility tool from within LyX. #!/usr/bin/perl -w # straightQuoteConvertToLyX # by John Wetterau # [EMAIL PROTECTED] # converts ascii straight quotes to LyX curly quotes # joe.burke.in.lyx is a novel originally written in Word for Windows. # It was exported in MS-DOS no lines format, copied to Linux, run # through dos2unix (to convert cr,lf to newline), and then imported # by LyX as an ascii file. The Word export routine replaced all curly # quotes with straight quotes. This perl code takes the lyx document, after # it has been imported by LyX, and inserts LyX code for left and right curly # quotes at the appropriate places. It may miss some unusual cases, # but it worked fine for me on hundreds of pages of mixed description and # dialog. This code will not work properly on incorrect punctuation. # e.g. "Zounds!" works, gets a left and right curly quote #"Zounds"! does not work, gets 2 left curly quotes # Hard coded input and output files cuz I don't # know any better (first perl code). # You will have to replace the filenames with your own. $LYXIN = "/home/jw/writing/joe.burke.out.lyx"; $LCURLY = "\n\\begin_inset Quotes eld\n\\end_inset \n\n"; $RCURLY = "\n\\begin_inset Quotes erd\n\\end_inset \n\n"; open LYXIN or die "Can't find file $LYXIN: $!\n"; open LYXOUT or die "Can't find file $LYXOUT: $!\n"; select LYXOUT; while () { # substitute for right straight quotes first s/\."/.$RCURLY/gxm; s/\?"/?$RCURLY/gxm; s/,"/,$RCURLY/gxm; s/!"/!$RCURLY/gxm; s/"\)/$RCURLY)/gxm; s/"\ /$RCURLY /gxm; # remaining straight quotes should be lefties s/"/$LCURLY/gxm; print; }
converting imported straight quotes to curly
Problem solved (with help from Andre Poenitz)! Attached is perl code that replaces straight quotes with LyX code for left or right curly quotes as appropriate. There are probably many ways to do this in one line, but this is my first perl code, so... This problem will be faced by anyone who imports ascii text into LyX, text that has been saved by a word processor in another operating system and that has been stripped of proprietary formatting codes. Manually changing each straight quote in LyX to a left or right curly quote is a long job for a book length document. I hope this will save others time. Newbie that I am, I don't know how to paste the text into this e-mail, so I have attached the file: straightQuoteConvertToLyX #!/usr/bin/perl -w # straightQuoteConvertToLyX # by John Wetterau # [EMAIL PROTECTED] # converts ascii straight quotes to LyX curly quotes # joe.burke.in.lyx is a novel originally written in Word for Windows. # It was exported in MS-DOS no lines format, copied to Linux, run # through dos2unix (to convert cr,lf to newline), and then imported # by LyX as an ascii file. The Word export routine replaced all curly # quotes with straight quotes. This perl code takes the lyx document, after # it has been imported by LyX, and inserts LyX code for left and right curly # quotes at the appropriate places. It may miss some unusual cases, # but it worked fine for me on hundreds of pages of mixed description and # dialog. # hard code input and output files cuz I don't # know any better (first perl code) $LYXIN = "/home/jw/writing/joe.burke.out.lyx"; $LCURLY = "\n\\begin_inset Quotes eld\n\\end_inset \n\n"; $RCURLY = "\n\\begin_inset Quotes erd\n\\end_inset \n\n"; open LYXIN or die "Can't find file $LYXIN: $!\n"; open LYXOUT or die "Can't find file $LYXOUT: $!\n"; select LYXOUT; while () { # substitute for right straight quotes first s/\."/.$RCURLY/gxm; s/\?"/?$RCURLY/gxm; s/,"/,$RCURLY/gxm; s/!"/!$RCURLY/gxm; # remaining straight quotes should be lefties s/"/$LCURLY/gxm; print; }