Beginner's question about ending block quotes

Hi,

I’ve taken the plunge and decided to use Scrivener-MMD-LaTeX to write and format my thesis. I am slowly learning how to do things but I am still definitely on the words-of-one-syllable level of understanding.

I wonder if someone could tell me how to end a block quote without starting a new paragraph (i.e., indenting the next line)?

So far the only way to end a block quote that I have figured out is to insert two carriage returns, which then starts a new paragraph when the text is typeset.

Is there an “end block quote” command or something of the sort that I can insert while in Scrivener?

Thanks!

I don’t quite follow what you are getting at here. From a typesetting standpoint, I’m not sure how you cease quoting something while still in the same paragraph. The purpose of the quote environment is to set a block of text apart from the rest of the text, using indenting to accomplish this—if the quotation ends, and you are then commenting upon the quotation… the blockquote environment should also end, both from a typesetting and semantic standpoint—this is an established convention and would likely be confusing to your readers if broken.

So I guess in answer to your question: no there isn’t a way to stop a blockquote without starting a new block of text, for the same reason there isn’t a way to start an enumerated list in the middle of a paragraph.

Hi, just to say that I think I know what you are talking about. I have had the same problem. In my PhD, there are blockquotes where the first non-quote line should be indented (meaningful new paragraph) and other blockquotes where the first non-quote line should not be indented (continuation of paragraph that began before the block quote). With LaTeX, I always end up needing to clean up by adding \noindent in the case of the latter. I don’t think MMD can accommodate this nuance.

Ioa, thank you for your reply. My apologies for just letting it drop. I dimly remember having some problems logging onto the forums the day after I posted that question and then I’m afraid I just got distracted and forgot about it. :blush:

rebeccaross, yes! that’s exactly what I mean. Thanks for saying it more clearly than I could. Yes, I have just been cleaning it up as you describe in TeXShop and that does work. (I would of course love to be able to deal with it from within Scrivener just because it happens so many times in my text, but it’s definitely work-around-able.)

No problem, and yeah I think I understand what you are wanting to do better, now. MMD itself has no way of doing this, as you’ve discovered. The cleanest way to do something like this is probably something along the lines of the tip described on this page, which demonstrates a technique for using the blockquote environment to do something other than blockquotes, in this case creating a framed box.

I use a similar technique that to my eye is less “syntax” in Scrivener itself, by using its inline annotation feature in conjunction with a keyword as demonstrated in this example, to produce special blocks of LaTeX.

Working with XSLT is decidedly more advanced, but it is the way to extend MultiMarkdown and make it do things the default cannot do. Given the learning curve though, there is another technique you can use which just relies on Scrivener alone: Replacements. These are compile-time Search & Replace functions that are run on your manuscript as it is compiled. I use these as well from time to time. For instance if I want to switch to a two column layout, I have two tokens I’ve created out of Replacements:

<$startMultiCols>: [code]

[/code]
<$endMultiCols>: [code]

[/code]

So if you wanted to insert an indent change in formatting, you could take a similar approach by creating your own start and stop tokens and placing the LaTeX environment codes into the replacement field, wrapped in HTML comments like you see above. Wrapping LaTeX into a comment preserves them through the MMD process. Otherwise their special characters will be escaped and you’ll see the raw LaTeX in the final PDF.

You can use anything for the “token”; I just copied Scrivener’s standard for the sake of consistency. Something as easy as “=>” and “<=” for indent ON and indent OFF would work, so long as that pattern never crops up naturally. Replacements work just like standard Search & Replace tools, so just keep the limitations and powers of that in mind when creating them.

Ioa, thank you so much for this! It’s going to take me a little while to digest but I can see how using Replacements as you suggest will do what I need. Great solution.

And now I’m just thinking out loud, feel free to ignore…technically, of course, I don’t exactly want to start a new, non-indented paragraph after the block quote, but rather, just escape the block quote environment and let the previous paragraph keep flowing on. So, maybe a good solution would be to use this technique to insert LaTeX code to force-end the block quote (so to speak), rather than using it to direct the next line of text not to indent. In this way there would never be any weirdness if I one day ended up using a format where paragraphs were separated by extra space as well as (or instead of) indention.

OK, I’m going to work on it. Thanks a lot!

Just wanted to post the procedure I came up with, in case it might help anyone else in the future.

Instead of the very simple MMD block quote code (>), I’m using short tokens at the beginning and end of the block quote which, during Compile, are replaced by LaTeX code for beginning and ending the quotation environment.

becomes:

<!-- \begin{quotation} -->

becomes:

<!-- \end{quotation} -->

The quotation environment automatically indents the first line of the block quote. But sometimes I need the block quote to start without an indent (for example, if the quoted text begins in the middle of a paragraph in the original source). When this is the case, I also insert a token at the beginning of the block quote that gets replaced by LaTeX code for non-indention.

becomes:

<!-- \noindent -->

(As an aside, if you never needed indention in your block quotes, it seems like you would be better off using the LaTeX quote–as opposed to quotation–environment, which sets block quotes without indented paragraphs.)

Finally, after the block quote is dealt with, I can insert an empty line or not, depending on whether a new paragraph begins in the main text after the quote or not.

This is easy and formats correctly, as far as I can tell. At least so far. :smiley: Thanks a lot for the help!