From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Maus Subject: Re: LaTeX export > Avoid \newline command after timestampsX-Draft-From: ("nnimap+mc:INBOX.sncb") Date: Thu, 18 Mar 2010 16:41:23 +0100 Message-ID: <87wrx9skm4.wl%dmaus@ictsoc.de> References: <87ocin3yq6.fsf@mundaneum.com> <87fx3yg1mm.wl%dmaus@ictsoc.de> <87aau6t2ue.fsf@mundaneum.com> <87y6hpkg4f.wl%dmaus@ictsoc.de> <871vfhspjj.fsf@mundaneum.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: multipart/mixed; boundary="===============0680012203==" Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NsHqo-0006eK-Gb for emacs-orgmode@gnu.org; Thu, 18 Mar 2010 11:41:34 -0400 Received: from [140.186.70.92] (port=56416 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NsHqm-0006bR-IQ for emacs-orgmode@gnu.org; Thu, 18 Mar 2010 11:41:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NsHqk-0007DM-Ua for emacs-orgmode@gnu.org; Thu, 18 Mar 2010 11:41:32 -0400 Received: from mysql1.xlhost.de ([213.202.242.106]:47530) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NsHqk-0007D1-KU for emacs-orgmode@gnu.org; Thu, 18 Mar 2010 11:41:30 -0400 In-Reply-To: <871vfhspjj.fsf@mundaneum.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Francesco Pizzolante Cc: mailing-list-org-mode , Carsten Dominik --===============0680012203== Content-Type: multipart/signed; boundary="pgp-sign-Multipart_Thu_Mar_18_16:41:22_2010-1"; protocol="application/pgp-signature" Content-Transfer-Encoding: 7bit --pgp-sign-Multipart_Thu_Mar_18_16:41:22_2010-1 Content-Type: multipart/mixed; boundary="Multipart_Thu_Mar_18_16:41:22_2010-1" --Multipart_Thu_Mar_18_16:41:22_2010-1 Content-Type: text/plain; charset=US-ASCII Francesco Pizzolante wrote: >Hi David, >> This cleary /is/ problem. Maybe we should catch these two cases >> (patch attached): >> >> ,---- >> | (unless (and (looking-at ".*\n[ \t]*\n") (looking-at ".*\\\\newline[ \t]*$")) >> `---- >> >> Insert \newline only if there is no paragraph separator. As far as I >> can see the LaTeX code is already rendered when >> `org-export-latex-keywords' is called so this should work out. >I tried your patch, but I still get extra \newline commands in the generated >LaTeX. Yes, sorry, my brain's logical unit misfired. What I meant was ,---- | (unless (or (looking-at ".*\n[ \t]*\n") (looking-at ".*\\\\newline[ \t]*$")) `---- Translating to: insert /no/ \newline, if either (a) there is a empty line beneath this line or (b) there is already a \newline. Using this the examples give: 1) Heading with no text --8<---------------cut here---------------start------------->8--- ** STARTED First SCHEDULED: <2010-03-01 Mon> DEADLINE: <2010-03-19 Fri> --8<---------------cut here---------------end--------------->8--- Gives the following: --8<---------------cut here---------------start------------->8--- \section{STARTED First} \label{sec-1} \texttt{SCHEDULED:} \textit{2010-03-01 Mon} \texttt{DEADLINE:} \textit{2010-03-19 Fri} --8<---------------cut here---------------end--------------->8--- No extra vertical space between this heading and the next one. 2) Heading with text and no blank line between heading and text --8<---------------cut here---------------start------------->8--- ** STARTED Second SCHEDULED: <2010-03-01 Mon> DEADLINE: <2010-03-19 Fri> This task is split among all services and communication between the entities. --8<---------------cut here---------------end--------------->8--- Gives the following: --8<---------------cut here---------------start------------->8--- \section{STARTED Second} \label{sec-2} \texttt{SCHEDULED:} \textit{2010-03-01 Mon} \texttt{DEADLINE:} \textit{2010-03-19 Fri}\newline This task is split among all services and communication between the entities. --8<---------------cut here---------------end--------------->8--- This would be Carsten's case. 3) Heading with text and blank line between heading and text --8<---------------cut here---------------start------------->8--- ** DONE Third DEADLINE: <2010-03-26 Fri> This task is split among all services and communication between the entities. Second paragraph. fdqsfdq --8<---------------cut here---------------end--------------->8--- Gives the following: --8<---------------cut here---------------start------------->8--- \section{\textbf{DONE} Third} \label{sec-3} \texttt{DEADLINE:} \textit{2010-03-26 Fri} This task is split among all services and communication between the entities. Second paragraph. fdqsfdq --8<---------------cut here---------------end--------------->8--- What you expected. IMO inserting a \newline after the deadline/scheduled line if text follows immediately (example 2) makes sense. HTH -- David -- OpenPGP... 0x99ADB83B5A4478E6 Jabber.... dmjena@jabber.org Email..... dmaus@ictsoc.de --Multipart_Thu_Mar_18_16:41:22_2010-1 Content-Type: application/octet-stream; type=patch Content-Disposition: attachment; filename="latex-newline-2.diff" Content-Transfer-Encoding: base64 ZGlmZiAtLWdpdCBhL2xpc3Avb3JnLWxhdGV4LmVsIGIvbGlzcC9vcmctbGF0ZXguZWwKaW5kZXgg MWY2OTdkNS4uZDUwZGMyZCAxMDA2NDQKLS0tIGEvbGlzcC9vcmctbGF0ZXguZWwKKysrIGIvbGlz cC9vcmctbGF0ZXguZWwKQEAgLTE1MTcsNyArMTUxNyw3IEBAIFRoZSBjb252ZXJzaW9uIGlzIG1h ZGUgZGVwZW5kaW5nIG9mIFNUUklORy1CRUZPUkUgYW5kIFNUUklORy1BRlRFUi4iCiAJCQkgICAo bWF0Y2gtc3RyaW5nIDApKSB0IHQpCiAgICAgKHNhdmUtZXhjdXJzaW9uCiAgICAgICAoYmVnaW5u aW5nLW9mLWxpbmUgMSkKLSAgICAgICh1bmxlc3MgKGxvb2tpbmctYXQgIi4qXFxcXG5ld2xpbmVb IFx0XSokIikKKyAgICAgICh1bmxlc3MgKG9yIChsb29raW5nLWF0ICIuKlxuWyBcdF0qXG4iKSAo bG9va2luZy1hdCAiLipcXFxcbmV3bGluZVsgXHRdKiQiKSkKIAkoZW5kLW9mLWxpbmUgMSkKIAko aW5zZXJ0ICJcXG5ld2xpbmUiKSkpKSkKIAo= --Multipart_Thu_Mar_18_16:41:22_2010-1-- --pgp-sign-Multipart_Thu_Mar_18_16:41:22_2010-1 Content-Type: application/pgp-signature Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iF4EABEIAAYFAkuiSaIACgkQma24O1pEeOZqTwEAuWf0UhtoHR9mcXji1jiwMyNO g508x48OAdtDS8GevNQA/3P3O9ZAlGmVxbUsHopacvfI+myFHOkWWQk7oQa1Sqvo =eNnG -----END PGP SIGNATURE----- --pgp-sign-Multipart_Thu_Mar_18_16:41:22_2010-1-- --===============0680012203== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============0680012203==--