From: "Sébastien Vauban" <wxhgmqzgwmuf-geNee64TY+gS+FvcfC7Uqw@public.gmane.org>
To: emacs-orgmode-mXXj517/zsQ@public.gmane.org
Subject: Re: [patch] two bugs: one with comments and with exporting inline tasks
Date: Thu, 04 Nov 2010 17:32:10 +0100 [thread overview]
Message-ID: <80y6993vao.fsf@mundaneum.com> (raw)
In-Reply-To: 87vd4d9i7r.fsf@ucl.ac.uk
Eric,
Eric S Fraga wrote:
> In terms of what to actually do with inline tasks on export, what I would
> love to see would be to have an inline task converted to a footnote with a
> marginpar note, along the lines of:
>
> #+begin_src org
> ***************************** TODO figure out why this doesn't work
> Some text in the body of the inline task.
> ***************************** END
> #+end_src
>
> being converted to, say:
>
> #+begin_src latex
> \footnote{\textbf{<<headline text>>}: <<body text>>}\marginpar{\fbox{\thefootnote}}
> #+end_src
>
> i.e. where <<headline text>> would be replaced by "TODO figure out why this
> doesn't work" and <<body text>> by all the text between the ****** lines.
> This is roughly the type of construct I use when I annotate latex documents
> directly. What do you think?
... that we need this.
> We could make this a two argument latex function:
>
> #+begin_src latex
> \newcommand{\processinlinetask}[2]{%
> \footnote{\textbf{#1}: #2}\marginpar{\fbox{\thefootnote}}%
> }
> #+end_src
>
> which is defined in the org latex preamble and which a user could
> customise through =\renewcommand= if desired (or through an org emacs
> variable, of course). It would be invoked as
>
> #+begin_src latex
> \processinlinetask{<<headline text>>}{<<body text>>}
> #+end_src
>
> We'd have to escape {}s maybe and it could be
> somewhat fragile if there are multiple paragraphs in the inline body
> text...
>
> For HTML, you could convert to end notes maybe or some type of box
> inline with the text... (well, customisable by the user through CSS I
> guess)
>
> Thanks,
> eric
In exactly the same line of sight, I'm using the following already for (pure)
LaTeX -- I mean, not yet integrated within Org --:
#+begin_src latex
% must be loaded after url and hyperref
\RequirePackage[colorinlistoftodos]{todonotes}% (not in medium TeX Live installation)
\renewcommand{\@todonotes@backgroundcolor}{my-color-brand}
\renewcommand{\@todonotes@linecolor}{my-color-brand}
\newcounter{mycomment}
\newcommand{\mycomment}[2][]{% initials of the author + note in the margin
\if@mycomment
\refstepcounter{mycomment}
{\setstretch{0.7}% spacing
\todo[color={red!100!green!33},size=\small]{%
\textbf{Comment [\uppercase{#1}\themycomment]:}~#2}}
\else
\relax
\fi
}
\newcommand{\mytodo}[2][]{% title in bold + note
\refstepcounter{mycomment}
{\todo[inline,color=blue!20]{
\textbf{TODO [\uppercase{#1}\themycomment]:}~#2}}}
#+end_src
This is using the package =todonotes= which is, euh, excellent! Just have a
look, and you see that, with the above chunk of code, we can easily manage:
- mycomment :: margin notes (more for a comment, IMHO) and
- mytodo :: inlined notes (more for "inline tasks", IMHO).
Of course, this should now be automagically used by Org, as you do explain
above.
Best regards,
Seb
--
Sébastien Vauban
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode-mXXj517/zsQ@public.gmane.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
next prev parent reply other threads:[~2010-11-04 16:32 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-02 10:46 [bug] two bugs: one with comments and with exporting inline tasks Eric S Fraga
2010-11-02 19:27 ` Nicolas Goaziou
2010-11-02 20:51 ` Eric S Fraga
2010-11-02 23:11 ` Eric S Fraga
2010-11-04 7:41 ` Nicolas Goaziou
2010-11-04 7:51 ` [patch] " Nicolas Goaziou
2010-11-04 8:01 ` Nicolas Goaziou
2010-11-04 10:24 ` Eric S Fraga
2010-11-04 14:05 ` Nicolas Goaziou
2010-11-04 14:21 ` Eric S Fraga
2010-11-04 14:42 ` Nicolas Goaziou
2010-11-04 15:22 ` Eric S Fraga
2010-11-04 15:28 ` Nicolas Goaziou
2010-11-04 16:17 ` Eric S Fraga
2010-11-04 16:32 ` Sébastien Vauban [this message]
2010-11-04 17:45 ` Nicolas Goaziou
2010-11-05 8:01 ` Sébastien Vauban
2010-11-05 8:58 ` Sébastien Vauban
2010-11-05 12:50 ` Eric S Fraga
2010-11-05 12:50 ` Eric S Fraga
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=80y6993vao.fsf@mundaneum.com \
--to=wxhgmqzgwmuf-genee64ty+gs+fvcfc7uqw@public.gmane.org \
--cc=emacs-orgmode-mXXj517/zsQ@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).