RC1 - LaTeX template - Export of plain TXT file.

I have issues when compiling the LaTeX template without any changes. This template compiles correctly on the Mac version of Scrivener.

  1. Codec Windows -1252 recommended. MMD LaTeX template exports using UTF-8. No option to export to UTF-8.
  2. Exports as TXT file and cannot export as TEX file. I have to rename it. MMD LaTeX template exports as TEX file.
  3. Export format style prefix is not part of export. As a result the exported file will not work in LaTeX.
  4. Export format style suffix is not part of export. As a result the exported file will not work in LaTeX.
  5. Template default title “latex_updates” fails with my LaTeX installation because of the underscore.

Front matter and back matter appear to export correctly.

Because of these problems I have not yet fully tested the export styles of the template to see if they are being compiled correctly.

Thanks for the summary:

  1. Known bug, I have this one filed. You can select UTF-8 but you have to do so as a global default from the Sharing: Export settings tab, not the ask-every-time thing. For some reason UTF-8 isn’t in that list, though it should be at the very top as a convenience choice.
  2. Just to make sure we’re on the same page, you mentioned this being a LaTeX template you’re using—I presume “General Non-Fiction (LaTeX)”? But in this one you do mention “MMD”, which is an entirely different way of creating .tex files. Otherwise, .txt files are .tex files—it’s just an extension difference, so is that what you mean? If so, that is logged.
  3. These I cannot actually reproduce. I tried applying Emphasis, Index Key and Inline Equation to some text, and they all came through. The more complex Enumerated List paragraph style also worked (both to declare the environment as a whole, and to prefix each line with \item). That said, some styles won’t work because they depend on Replacements, which don’t work. That is logged.
  4. Do you mean the compile Format document prefix and suffix, where the preamble and footer would go? If so, that’s logged, yes.
  5. Well that’s a silly bug. That this is stored into to the template is one problem (that’s one for the Mac as well though), but it’s never surfaced as an issue because when creating a new project from a project template it should be populating metadata based on system information and the saved project name, not whatever was used to create the template months ago. I’ll file that one too.

There are other issues as well, some worse than what you found. At least with a lack of functioning document prefix/suffix, you can make up for that with front/back matter files. It just means the Format drives the design a little less, which is fine for personal use. But if the Markup pane and Replacements don’t work, that means core expected features of the template like cross-referencing, figures and indexing will not work—and I can think of no way of making them work without those features.

I don’t think this template will be a part of the release version, in other words. :neutral_face:

1, Noted. Thank you.

  1. Yes the General Non-Fiction LaTeX template. I realize it is not designed for MMD. It was an effort to export some LaTeX that would work and to note that the MMD export was able to change the extension.

3, 4. Yes, I meant the document prefix and suffix.

  1. Yes silly, but when testing it caught me and took a while to figure out. :smiley:

I can see ways to improve the template with a few style changes and how the LaTeX preamble is done or with a few more export fomats for articles, journals, books, ebooks etc. Probably a lot of work for the few people who use Scrivener for LaTeX, who are probably experts in LaTeX anyway, so I can imagine it is low on the priority list.

Ah, okay, I misread. Yeah MMD→TeX has the extension hardcoded in to that selection, kind of like if you choose RTF it has the .rtf extension hardcoded. All of the file type selections have a hardcoded extensions—and that I suspect is the problem. Plain-text is .txt, but at the same time there is the Extension field in the upper-right corner of the Format designer that is supposed to let you set another default (tex) in this case. That is the part that isn’t working.

Of course the other silly part is my old habit of UNIX-naming everything. I shudder at the thought of using spaces in file names; how uncouth! :laughing:

Feel free to fire suggestions my way! I’m too busy with the documentation right now to mess with it, but I put all good ideas on a list. I’ll let you know the aims though:

  • Provide an idea, foremost. This is how one could use Scrivener’s features to create a flexible (multiple output target) LaTeX document. It is likely it will not encapsulate even one individual’s needs all by itself.
  • Since no boilerplate is going to work for everyone, avoid adding the burden of having to “undo” preferential decisions and figuring out where those decisions are made. What is there is dirt simple, and more a suggestion of where to put your stuff—as well as something that “works” if you type in a few words and hit compile.
  • And as you say, the odds of someone taking this template on without any knowledge of LaTeX are quite low. It doesn’t need to be a tutorial of that system in and of itself, and can depend upon the expertise the user brings to it. That said, you’d be surprised… people see the user manuals are made with it, and they want to learn how to create such output straight from Scrivener. The appeal of handing over a quantity of the “dirty work” to automation is natural.

At least, that’s the idea for the starter compile Format itself. Maybe some day I’ll have time to put together some nice looking prefabs that go a little more in-depth into creating a design one could build off of.

So for now, what I’d most be interested in, in terms of feedback, are poor practices, package substitutions if I’ve made some old-fashioned or ill-informed choices, better ways to implement syntax, etc.