emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* How to signal end of a section or subsection
@ 2014-01-14 15:12 Ken Mankoff
  2014-01-14 16:55 ` Eric S Fraga
  2014-01-20 16:30 ` Skip Collins
  0 siblings, 2 replies; 14+ messages in thread
From: Ken Mankoff @ 2014-01-14 15:12 UTC (permalink / raw)
  To: Org-mode


I just re-watched the Carsten Google Tech Talk from 2008. He 
explains that Org was created as a hybrid note taker and TODO list, 
and that the TODOs should be embedded in the text. This leads me to 
a strange situation and I hope list members can explain how they 
deal with it.


* ONE: Sometimes I have as section of text as I take notes.

** TWO: And under that subsections

    A And there there are multiple paragraphs of text like this.

    B And like this.

    C And if one of these becomes an item that should be turned into 
a TODO item, how do I best do this?

For example, if "B" needs to be a TODO item, I could set it equal to 
TWO (subsection) like so: "** TODO B" or keep it in its current area 
under TWO (subsubsection) like so "*** TODO B".

The first doesn't make sense because I've elevated the notes under 
"** TWO" to be equal to it. The second option makes sense, but the 
problem is now that "C" is suddenly contained in "B" because there 
is no way to signal that the subsubsection "B" has ended and further 
text is in its original level of under subsection TWO.

I could go through and make A, B, and C all subsubsections, but now 
I need to make up titles for each paragraph of text under "TWO".

Perhaps the best-practice is what I wrote last - not paragraphs of 
text, but each paragraph is its own sub(sub(sub))section with as 
summary title. Is this what others do? Any other advice how do deal 
with this?

Thanks,

   -k.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-14 15:12 How to signal end of a section or subsection Ken Mankoff
@ 2014-01-14 16:55 ` Eric S Fraga
  2014-01-15 12:24   ` Ken Mankoff
  2014-01-20 16:30 ` Skip Collins
  1 sibling, 1 reply; 14+ messages in thread
From: Eric S Fraga @ 2014-01-14 16:55 UTC (permalink / raw)
  To: Ken Mankoff; +Cc: Org-mode

Ken Mankoff <mankoff@gmail.com> writes:

> I just re-watched the Carsten Google Tech Talk from 2008. He explains

Great talk that was!  Changed my life.

> that Org was created as a hybrid note taker and TODO list, and that
> the TODOs should be embedded in the text. This leads me to a strange
> situation and I hope list members can explain how they deal with it.
>
>
> * ONE: Sometimes I have as section of text as I take notes.
>
> ** TWO: And under that subsections
>
>    A And there there are multiple paragraphs of text like this.
>
>    B And like this.
>
>    C And if one of these becomes an item that should be turned into a
> TODO item, how do I best do this?

What I would do is make the A, B and C paragraph items.  Then add
checkboxes (C-u C-c C-x C-b) to any list item you want to mark as a todo
item.  You can set/unset using C-c C-x C-b.  If you add the text [/] to
the headline with the TODO on it, it will be updated to indicate the
number of completed checkboxes and the total number of such boxes each
time you set or unset one.
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.1, Org release_8.2.4-322-gece429

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-14 16:55 ` Eric S Fraga
@ 2014-01-15 12:24   ` Ken Mankoff
  2014-01-15 17:15     ` Eric S Fraga
  0 siblings, 1 reply; 14+ messages in thread
From: Ken Mankoff @ 2014-01-15 12:24 UTC (permalink / raw)
  To: Ken Mankoff, Org-mode

[-- Attachment #1: Type: text/plain, Size: 641 bytes --]

Hi Eric,

On Tue, Jan 14, 2014 at 11:55 AM, Eric S Fraga <e.fraga@ucl.ac.uk> wrote:
>
>
> What I would do is make the A, B and C paragraph items.  Then add
> checkboxes (C-u C-c C-x C-b) to any list item you want to mark as a todo
> item.  You can set/unset using C-c C-x C-b.  If you add the text [/] to
> the headline with the TODO on it, it will be updated to indicate the
> number of completed checkboxes and the total number of such boxes each
> time you set or unset one.
>

 I just discovered org inline tasks. This seems to be another approach, and
very useful!

http://orgmode.org/worg/org-faq.html#closing-outline-sections

   -k.

[-- Attachment #2: Type: text/html, Size: 1183 bytes --]

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-15 12:24   ` Ken Mankoff
@ 2014-01-15 17:15     ` Eric S Fraga
  0 siblings, 0 replies; 14+ messages in thread
From: Eric S Fraga @ 2014-01-15 17:15 UTC (permalink / raw)
  To: Ken Mankoff; +Cc: Org-mode

Ken Mankoff <mankoff@gmail.com> writes:

[...]

>  I just discovered org inline tasks. This seems to be another approach, and
> very useful!

Indeed!  I use these all the time for when I have tasks inersprsed in a
large document.  I'm not sure why I forgot to mention this capability;
probably because org has so many ways to accomplish most tasks.  I'm
glad you found out anyway.
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.1, Org release_8.2.4-322-gece429

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-14 15:12 How to signal end of a section or subsection Ken Mankoff
  2014-01-14 16:55 ` Eric S Fraga
@ 2014-01-20 16:30 ` Skip Collins
  2014-01-21 16:41   ` Eric S Fraga
  1 sibling, 1 reply; 14+ messages in thread
From: Skip Collins @ 2014-01-20 16:30 UTC (permalink / raw)
  To: Org-mode

Several requests have been made over the years for a way to end a
subsection without starting a new new higher level section. This is
possible with plain lists: a blank line ends the list. Some other
syntax would have to be added to org to allow this for sections. I
would love to see something like this implemented:

--- begin org example ---

* First top-level section
A bunch of text.

Blah blah.

Yada yada.

** TODO Something I need to do
** :END:

Resuming first top-level section.

** Here is a small subsection
When this sub-section ends, the top-level section will resume.
** :END:

Resuming first top-level section.

--- end org example ---

Such a fundamental change to org syntax might be difficult to
implement without extensive changes to how files are parsed. But,
IMHO, it would add to its elegance and flexibility. As things stand
now, inline tasks and lists are used as workarounds.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-20 16:30 ` Skip Collins
@ 2014-01-21 16:41   ` Eric S Fraga
  2014-01-22 20:16     ` Alan Schmitt
  0 siblings, 1 reply; 14+ messages in thread
From: Eric S Fraga @ 2014-01-21 16:41 UTC (permalink / raw)
  To: Skip Collins; +Cc: Org-mode

Hi,

I guess you can find plenty of discussions on this list on this topic so
I won't rehash.  Just to say that there has never been a convincing use
case that is not easily addressed with description lists and inline
tasks.  The former can be made to look like encapsulated sections on
export with appropriate customisation of the various export targets.

I suggest you check out the list and think about your actual use case.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.1, Org release_8.2.4-322-gece429

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-21 16:41   ` Eric S Fraga
@ 2014-01-22 20:16     ` Alan Schmitt
  2014-01-22 20:22       ` Nicolas Goaziou
  0 siblings, 1 reply; 14+ messages in thread
From: Alan Schmitt @ 2014-01-22 20:16 UTC (permalink / raw)
  To: Skip Collins; +Cc: Org-mode

Eric S Fraga <e.fraga@ucl.ac.uk> writes:

> I guess you can find plenty of discussions on this list on this topic so
> I won't rehash.  Just to say that there has never been a convincing use
> case that is not easily addressed with description lists and inline
> tasks.  The former can be made to look like encapsulated sections on
> export with appropriate customisation of the various export targets.
>
> I suggest you check out the list and think about your actual use case.

I have a use case for beamer export, where I have had to use latex
blocks to solve it. If I want:

,----
| blah blah
| 
| \begin{block}{Theorem}
| foo bar
| \end{block}
| 
| more blah blah
`----

I don't know how to do it using the org machinery without going back to
latex.

Alan

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-22 20:16     ` Alan Schmitt
@ 2014-01-22 20:22       ` Nicolas Goaziou
  2014-01-22 21:38         ` Sebastien Vauban
  2014-01-22 21:45         ` Alan Schmitt
  0 siblings, 2 replies; 14+ messages in thread
From: Nicolas Goaziou @ 2014-01-22 20:22 UTC (permalink / raw)
  To: Alan Schmitt; +Cc: Skip Collins, Org-mode

Hello,

Alan Schmitt <alan.schmitt@polytechnique.org> writes:

> I have a use case for beamer export, where I have had to use latex
> blocks to solve it. If I want:
>
> ,----
> | blah blah
> | 
> | \begin{block}{Theorem}
> | foo bar
> | \end{block}
> | 
> | more blah blah
> `----
>
> I don't know how to do it using the org machinery without going back to
> latex.

The following should work:

  #+attr_latex: :options {Theorem}
  #+begin_block
  foo bar
  #+end_block


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-22 20:22       ` Nicolas Goaziou
@ 2014-01-22 21:38         ` Sebastien Vauban
  2014-01-22 22:20           ` Nicolas Goaziou
  2014-01-22 21:45         ` Alan Schmitt
  1 sibling, 1 reply; 14+ messages in thread
From: Sebastien Vauban @ 2014-01-22 21:38 UTC (permalink / raw)
  To: emacs-orgmode-mXXj517/zsQ

Nicolas Goaziou wrote:
> Alan Schmitt <alan.schmitt-o/5/jSaJEHk+NdeTPqioyti2O/JbrIOy@public.gmane.org> writes:
>
>> I have a use case for beamer export, where I have had to use latex
>> blocks to solve it. If I want:
>>
>> ,----
>> | blah blah
>> | 
>> | \begin{block}{Theorem}
>> | foo bar
>> | \end{block}
>> | 
>> | more blah blah
>> `----
>>
>> I don't know how to do it using the org machinery without going back to
>> latex.
>
> The following should work:
>
>   #+attr_latex: :options {Theorem}
>   #+begin_block
>   foo bar
>   #+end_block

I thought that the standard way was the following:

--8<---------------cut here---------------start------------->8---
***                                                                 :B_theorem:
    :PROPERTIES:
    :BEAMER_env: theorem
    :END:

There is no largest prime number.

*** End of theorem                                            :B_ignoreheading:
    :PROPERTIES:
    :BEAMER_env: ignoreheading
    :END:
--8<---------------cut here---------------end--------------->8---

Obviously, it's much less readeable...

Maybe that solution should be deprecated, then?

Best regards,
  Seb

-- 
Sebastien Vauban

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-22 20:22       ` Nicolas Goaziou
  2014-01-22 21:38         ` Sebastien Vauban
@ 2014-01-22 21:45         ` Alan Schmitt
  1 sibling, 0 replies; 14+ messages in thread
From: Alan Schmitt @ 2014-01-22 21:45 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: Skip Collins, Org-mode

Nicolas Goaziou <n.goaziou@gmail.com> writes:

> Hello,
>
> Alan Schmitt <alan.schmitt@polytechnique.org> writes:
>
>> I have a use case for beamer export, where I have had to use latex
>> blocks to solve it. If I want:
>>
>> ,----
>> | blah blah
>> | 
>> | \begin{block}{Theorem}
>> | foo bar
>> | \end{block}
>> | 
>> | more blah blah
>> `----
>>
>> I don't know how to do it using the org machinery without going back to
>> latex.
>
> The following should work:
>
>   #+attr_latex: :options {Theorem}
>   #+begin_block
>   foo bar
>   #+end_block

Ah, nice, thank you, I did not know of this option.

Alan

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-22 21:38         ` Sebastien Vauban
@ 2014-01-22 22:20           ` Nicolas Goaziou
  2014-01-23  8:17             ` Sebastien Vauban
  0 siblings, 1 reply; 14+ messages in thread
From: Nicolas Goaziou @ 2014-01-22 22:20 UTC (permalink / raw)
  To: Sebastien Vauban; +Cc: public-emacs-orgmode-mXXj517/zsQ



Hello,

"Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
writes:

> I thought that the standard way was the following:
>
> ***                                                                 :B_theorem:
>     :PROPERTIES:
>     :BEAMER_env: theorem
>     :END:
>
> There is no largest prime number.
>
> *** End of theorem                                            :B_ignoreheading:
>     :PROPERTIES:
>     :BEAMER_env: ignoreheading
>     :END:
>
> Obviously, it's much less readeable...

But more powerful. For example, you can nest blocks of the same type
with this syntax. Not with the other one.

> Maybe that solution should be deprecated, then?

Certainly not. See above.


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-22 22:20           ` Nicolas Goaziou
@ 2014-01-23  8:17             ` Sebastien Vauban
  2014-01-23 11:14               ` Nicolas Goaziou
  0 siblings, 1 reply; 14+ messages in thread
From: Sebastien Vauban @ 2014-01-23  8:17 UTC (permalink / raw)
  To: emacs-orgmode-mXXj517/zsQ

Hello Nicolas,

Nicolas Goaziou wrote:
> "Sebastien Vauban" writes:
>
>> I thought that the standard way was the following:
>>
>> ***                                                                 :B_theorem:
>>     :PROPERTIES:
>>     :BEAMER_env: theorem
>>     :END:
>>
>> There is no largest prime number.
>>
>> *** End of theorem                                            :B_ignoreheading:
>>     :PROPERTIES:
>>     :BEAMER_env: ignoreheading
>>     :END:
>>
>> Obviously, it's much less readeable...
>
> But more powerful. For example, you can nest blocks of the same type
> with this syntax. Not with the other one.
>
>> Maybe that solution should be deprecated, then?
>
> Certainly not. See above.

OK.

Is the simpler solution valid on all types of block environments?

To enumerate them (extensively, AFAICT):

- structureenv
- alertblock
- exampleblock
- definition
- example
- proof
- beamercolorbox
- verse
- quotation
- quote

Best regards,
  Seb

-- 
Sebastien Vauban

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-23  8:17             ` Sebastien Vauban
@ 2014-01-23 11:14               ` Nicolas Goaziou
  2014-01-23 22:20                 ` Sebastien Vauban
  0 siblings, 1 reply; 14+ messages in thread
From: Nicolas Goaziou @ 2014-01-23 11:14 UTC (permalink / raw)
  To: Sebastien Vauban; +Cc: public-emacs-orgmode-mXXj517/zsQ



"Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
writes:

> Is the simpler solution valid on all types of block environments?
>
> To enumerate them (extensively, AFAICT):
>
> - structureenv
> - alertblock
> - exampleblock
> - definition
> - example
> - proof
> - beamercolorbox
> - verse
> - quotation
> - quote

The "simpler solution" is just a consequence of special blocks handling
in LaTeX export back-ends. So, it will work for any special block. You
can rule out verse, example and quote, which have their own type in Org
syntax.


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to signal end of a section or subsection
  2014-01-23 11:14               ` Nicolas Goaziou
@ 2014-01-23 22:20                 ` Sebastien Vauban
  0 siblings, 0 replies; 14+ messages in thread
From: Sebastien Vauban @ 2014-01-23 22:20 UTC (permalink / raw)
  To: emacs-orgmode-mXXj517/zsQ

Hello Nicolas,

Nicolas Goaziou wrote:
> "Sebastien Vauban" writes:
>
>> Is the simpler solution valid on all types of block environments?
>>
>> To enumerate them (extensively, AFAICT):
>>
>> - structureenv
>> - alertblock
>> - exampleblock
>> - definition
>> - example
>> - proof
>> - beamercolorbox
>> - verse
>> - quotation
>> - quote
>
> The "simpler solution" is just a consequence of special blocks handling
> in LaTeX export back-ends. So, it will work for any special block.

OK, thanks.

> You can rule out verse, example and quote, which have their own type
> in Org syntax.

Verse and quote give the same results in both the complex and the simple
ways.

However, it does not for example.

The following:

--8<---------------cut here---------------start------------->8---
** =example= environment

- Behaves like the theorem environment, except that the theorem style =example=
  is used.
- A side-effect of using this theorem style is that the contents is put in an
  =exampleblock= instead of a =block=.

*** Example                                                         :B_example:
    :PROPERTIES:
    :BEAMER_env: example
    :END:

Contents of example

*** End of example                                            :B_ignoreheading:
    :PROPERTIES:
    :BEAMER_env: ignoreheading
    :END:

** =example= environment

- Simpler solution:

#+begin_example
Contents of example
#+end_example
--8<---------------cut here---------------end--------------->8---

gives:

--8<---------------cut here---------------start------------->8---
\begin{frame}[fragile,label=sec-6-8]{\texttt{example} environment}
 \begin{itemize}
\item Behaves like the theorem environment, except that the theorem style \texttt{example}
is used.
\item A side-effect of using this theorem style is that the contents is put in an
  \texttt{exampleblock} instead of a \texttt{block}.
\end{itemize}

\begin{example}[Example]
Contents of example
\end{example}
\end{frame}
\begin{frame}[fragile,label=sec-6-9]{\texttt{example} environment}
 \begin{itemize}
\item Simpler solution:
\end{itemize}

\begin{verbatim}
Contents of example
\end{verbatim}
\end{frame}
--8<---------------cut here---------------end--------------->8---

Hence, a verbatim environment in LaTeX instead of an example.

Do I miss something?  Or do I have something wrong somewhere?

Best regards,
  Seb

-- 
Sebastien Vauban

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2014-01-23 22:20 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-14 15:12 How to signal end of a section or subsection Ken Mankoff
2014-01-14 16:55 ` Eric S Fraga
2014-01-15 12:24   ` Ken Mankoff
2014-01-15 17:15     ` Eric S Fraga
2014-01-20 16:30 ` Skip Collins
2014-01-21 16:41   ` Eric S Fraga
2014-01-22 20:16     ` Alan Schmitt
2014-01-22 20:22       ` Nicolas Goaziou
2014-01-22 21:38         ` Sebastien Vauban
2014-01-22 22:20           ` Nicolas Goaziou
2014-01-23  8:17             ` Sebastien Vauban
2014-01-23 11:14               ` Nicolas Goaziou
2014-01-23 22:20                 ` Sebastien Vauban
2014-01-22 21:45         ` Alan Schmitt

Code repositories for project(s) associated with this 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).