Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-09 Thread Hans Hagen

On 8/8/2017 10:43 PM, Pablo Rodriguez wrote:

On 08/08/2017 09:36 AM, Hans Hagen wrote:

On 8/7/2017 11:03 PM, Pablo Rodriguez wrote:

But even in that case, numbering from:

\section{A}
\subsubsection{B}

gives:

1 A
1 B

Should it be the following?

1 A
1.1 B


no it would be 1 and 1.0.1 then


Sorry, I haven’t explained myself, Hans.

With the complete sample:

  \starttext
  \section{A}
  \subsubsection{B}
  \stoptext

Being the default and criterium applied, we get:

  1 A
  1 B

Isn’t this (again, I mean the default, not the extra option you are
going to implement) a wrong structuring?


sure, the input is wrong


I may understand that the original code considers the \subsubsection as
\subsection in regard to numbering to keep the structure, but
considering \subsubsection in the previous sample as a \section in
regard to numbering destroys the structure.

I hope this is clear now.

a zero in the number indicates that preceding levels are to be omitted

it has alway been the case ... this will not change ... a feature, not a 
bug


(if one systematically leaves out level one can use the relative 
sectioning mechanism i.e. subsub becomes sub then etc)


adding all kind of heuristics for weird structure is not on the agenda 
as it means lots of parameters and explanations and additional mess in 
subsystems that depend on structure being right


Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-08 Thread Pablo Rodriguez
On 08/08/2017 09:36 AM, Hans Hagen wrote:
> On 8/7/2017 11:03 PM, Pablo Rodriguez wrote:
>> But even in that case, numbering from:
>>
>>\section{A}
>>\subsubsection{B}
>>
>> gives:
>>
>>1 A
>>1 B
>>
>> Should it be the following?
>>
>>1 A
>>1.1 B
> 
> no it would be 1 and 1.0.1 then

Sorry, I haven’t explained myself, Hans.

With the complete sample:

 \starttext
 \section{A}
 \subsubsection{B}
 \stoptext

Being the default and criterium applied, we get:

 1 A
 1 B

Isn’t this (again, I mean the default, not the extra option you are
going to implement) a wrong structuring?

I may understand that the original code considers the \subsubsection as
\subsection in regard to numbering to keep the structure, but
considering \subsubsection in the previous sample as a \section in
regard to numbering destroys the structure.

I hope this is clear now.

Pablo
-- 
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-08 Thread Pablo Rodriguez
On 08/08/2017 02:42 PM, Idris Samawi Hamid ادريس سماوي حامد wrote:
> [...]
> - see attached - so maybe the criterium=all support wasn't included in  
> yesterday's release but is intended for a subsequent one..

I think so (he said he would support). It will be in next beta.
According to "curl -I http://pragma-ade.com/context/beta/cont-tmf.zip;
has to be released.

Pablo
-- 
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-08 Thread Idris Samawi Hamid ادريس سماوي حامد

On Tue, 08 Aug 2017 01:36:00 -0600, Hans Hagen  wrote:


On 8/7/2017 11:03 PM, Pablo Rodriguez wrote:

On 08/07/2017 08:57 PM, Hans Hagen wrote:

On 8/7/2017 5:08 PM, Pablo Rodriguez wrote:

[...]
I mean, in a common sectioning structure a \subsubsection comes after  
a

\subsection. But I don’t think it must be mandatory.


Well, it's all on purpose ... no excuse for bad structuring

 But even in that case, numbering from:
\section{A}
   \subsubsection{B}
 gives:
1 A
   1 B
 Should it be the following?
1 A
   1.1 B


no it would be 1 and 1.0.1 then


anyway, i'll support the criterium flag in sections too:

\setuphead[subsection][criterium=all]

and for sure i'll forget about it so I wonder who will document it ...

 I have done it
(http://wiki.contextgarden.net/Titles#Complete_Section_Numbering).
 But Idris should review and improve it ;-).
 Many thanks for the improvoement,


current version: 2017.08.07 11:30

===
\setuphead[subsection][criterium=all]

\starttext
\section{A}
\subsection{B}
\subsubsection{C}

\section{D}
% \subsection{E}
\subsubsection{F}
\stoptext
===

produces the following

1 A
1.1 B
1.1.1 C
2 D
1 F

- see attached - so maybe the criterium=all support wasn't included in  
yesterday's release but is intended for a subsequent one..


Idris
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512

section-intext2.pdf
Description: Adobe PDF document
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-08 Thread Hans Hagen

On 8/7/2017 11:03 PM, Pablo Rodriguez wrote:

On 08/07/2017 08:57 PM, Hans Hagen wrote:

On 8/7/2017 5:08 PM, Pablo Rodriguez wrote:

[...]
I mean, in a common sectioning structure a \subsubsection comes after a
\subsection. But I don’t think it must be mandatory.


Well, it's all on purpose ... no excuse for bad structuring


But even in that case, numbering from:

   \section{A}
   \subsubsection{B}

gives:

   1 A
   1 B

Should it be the following?

   1 A
   1.1 B


no it would be 1 and 1.0.1 then


anyway, i'll support the criterium flag in sections too:

\setuphead[subsection][criterium=all]

and for sure i'll forget about it so I wonder who will document it ...


I have done it
(http://wiki.contextgarden.net/Titles#Complete_Section_Numbering).

But Idris should review and improve it ;-).

Many thanks for the improvoement,

Pablo




--

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-07 Thread Idris Samawi Hamid ادريس سماوي حامد

Hi Hans, Pablo,

On Mon, 07 Aug 2017 15:03:41 -0600, Pablo Rodriguez  wrote:


On 08/07/2017 08:57 PM, Hans Hagen wrote:

On 8/7/2017 5:08 PM, Pablo Rodriguez wrote:

[...]
I mean, in a common sectioning structure a \subsubsection comes after a
\subsection. But I don’t think it must be mandatory.


Well, it's all on purpose ... no excuse for bad structuring


But even in that case, numbering from:

  \section{A}
  \subsubsection{B}

gives:

  1 A
  1 B

Should it be the following?

  1 A
  1.1 B


anyway, i'll support the criterium flag in sections too:

\setuphead[subsection][criterium=all]

and for sure i'll forget about it so I wonder who will document it ...


I have done it
(http://wiki.contextgarden.net/Titles#Complete_Section_Numbering).

But Idris should review and improve it ;-).

Many thanks for the improvoement,


Much appreciated and much obliged. Will try to find time to edit the wiki,  
although am already overloaded wearing too many hats (font development,  
lexer for npp, now writing metaphysics, semester about to start soon..)


Many thanks, guys.

Idris
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-07 Thread Pablo Rodriguez
On 08/07/2017 08:57 PM, Hans Hagen wrote:
> On 8/7/2017 5:08 PM, Pablo Rodriguez wrote:
>> [...]
>> I mean, in a common sectioning structure a \subsubsection comes after a
>> \subsection. But I don’t think it must be mandatory.
> 
> Well, it's all on purpose ... no excuse for bad structuring

But even in that case, numbering from:

  \section{A}
  \subsubsection{B}

gives:

  1 A
  1 B

Should it be the following?

  1 A
  1.1 B

> anyway, i'll support the criterium flag in sections too:
> 
> \setuphead[subsection][criterium=all]
> 
> and for sure i'll forget about it so I wonder who will document it ...

I have done it
(http://wiki.contextgarden.net/Titles#Complete_Section_Numbering).

But Idris should review and improve it ;-).

Many thanks for the improvoement,

Pablo
-- 
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-07 Thread Hans Hagen

On 8/7/2017 5:08 PM, Pablo Rodriguez wrote:


2. Look at the output of the adjusted version above - attached. Note that >>
a subsubsection after a section gives

1.1
2.1

which are the same as those given by a subsection after a section. How can
we get a subsubsection after a section to produce the following?

1.0.1
2.0.1


Again, I would say this is a bug in numbering:

 \starttext
 \section{A}
 %~ \subsection{B}
 \subsubsection{C}
 \stoptext

I mean, in a common sectioning structure a \subsubsection comes after a
\subsection. But I don’t think it must be mandatory.


Well, it's all on purpose ... no excuse for bad structuring .. anyway, 
i'll support the criterium flag in sections too:


\setuphead[subsection][criterium=all]

and for sure i'll forget about it so I wonder who will document it ...

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-07 Thread Pablo Rodriguez
On 08/06/2017 11:08 PM, Idris Samawi Hamid ادريس سماوي حامد wrote:
> [...]
> Challenges:
> 
> 1. How can we get automatic indentation for all heads *except* the first  
> one that occurs after the \starttitle?

Hi Idris,

this should be the default (it is actually \setupheads[indentnext=no]).

I think there is a bug here, because \setuphead[alternative=margintext]
prevents "indentnext=no" from working.

You might use "insidesection=\noindenting", but this only works if you
don’t use \starpar...\stoppar. And this is only a workaround.

> 2. Look at the output of the adjusted version above - attached. Note that  
> a subsubsection after a section gives
> 
> 1.1
> 2.1
> 
> which are the same as those given by a subsection after a section. How can  
> we get a subsubsection after a section to produce the following?
> 
> 1.0.1
> 2.0.1

Again, I would say this is a bug in numbering:

\starttext
\section{A}
%~ \subsection{B}
\subsubsection{C}
\stoptext

I mean, in a common sectioning structure a \subsubsection comes after a
\subsection. But I don’t think it must be mandatory.

Sorry for not being of much help,

Pablo
-- 
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-06 Thread Idris Samawi Hamid ادريس سماوي حامد

On Sun, 06 Aug 2017 13:49:37 -0600, Pablo Rodriguez  wrote:


On 08/06/2017 03:54 PM, Idris Samawi Hamid ادريس سماوي حامد wrote:

In addition to the two dropbox links above, see the following:

https://people.umass.edu/klement/tlp/tlp.html#bodytext
https://people.umass.edu/klement/tlp/tlp.pdf

The dropbox links (from Introduction to Hegel by GRG Mure) illustrate a
combination of Wittgenstein numbering with paragraph indentation. So it  
is

something of a hybrid between sectioning and paragraph numbering.

NOTE: A full implementation of Wittgenstein numbering is not required,  
and

would probably not be wise except in the context of producing a ConTeXt
edition of the Tractatus (something of zero interest to this writer).
Indeed, Wittgenstein's numbering system is inconsistent or obscure in
places... What we are looking for is something actually sane-)

Hi Idris,

I forgot to comment. If you want to reproduce the layout of the
Wittgenstein edition, margin heads would be a better approach.


No, we want the numbering, but the layout we're trying to reproduce is  
that of Introduction to Hegel (see dropbox samples in earlier message)



But for that, we need first to present to Hans a unified proposal for
paralell streams.


Ah the streams thread.. need to revisit that for other purposes as well.


I meant its layout, not the “Tractatus” itself :-).


Indeed (I'm biting my tongue here -) )


Just in case it helps (the proposal ;-)),


Many thanks!

Idris
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-06 Thread Idris Samawi Hamid ادريس سماوي حامد

On Sun, 06 Aug 2017 13:39:50 -0600, Pablo Rodriguez  wrote:


On 08/06/2017 03:54 PM, Idris Samawi Hamid ادريس سماوي حامد wrote:

[...]
Something along the lines of the following would be a sufficient (and
easier) first step for the current project, although we may want to
revisit the above for the future:

3  % section
3.0.1   % subsubsection

4  % section
4.1% subsection
4.1.1   % subsubsection

How can we automate this?


Hi Idris,

if you only need a printed version, I think the following approach might
help:

\setupwhitespace[big]

\setuphead[section]
[alternative=margintext,
 color=white,
 style=\tfxx,
 before=,
 after=,
 commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[sectionnumber][current]
\hspace[big]}}]}]

\setuphead[subsection]
[commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[subsectionnumber][current]
\hspace[big]}}]}]

\setuphead[subsubsection]
[commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[subsubsectionnumber][current]
\hspace[big]}}]}]

\starttext

\dorecurse{3}{\section{}
\startpar\input ward\stoppar
\startpar\input ward\stoppar
\dorecurse{3}{\subsection{}
\startpar\input ward\stoppar
\startpar\input ward\stoppar
\dorecurse{3}{\subsubsection{}
\startpar\input ward\stoppar
\startpar\input ward\stoppar
\startpar\input ward\stoppar}
\startpar\input ward\stoppar}
\startpar\input ward\stoppar}

\stoptext


Thank you very much, Pablo. Here is a modified version:

\setupwhitespace[big]

\setuphead[section]
[alternative=margintext,
 color=white,
 style=\tfxx,
 before=,
 after=,
 commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[sectionnumber][current]
\hspace[big]}}]}]

\setuphead[subsection]
[commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[subsectionnumber][current]
\hspace[big]}}]}]

\setuphead[subsubsection]
[commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[subsubsectionnumber][current]
\hspace[big]}}]}]

\starttext
\starttitle[title=Paper]
\dorecurse{2}{%
\startsection
\startpar\input ward\stoppar
\startparagraph\input ward\stopparagraph

\startsubsubsection{}
\startpar\input ward\stoppar
\stopsubsubsection

\dorecurse{2}{%
\startsubsection
\startpar\input ward\stoppar
\startparagraph\input ward\stopparagraph

\dorecurse{2}{%
\startsubsubsection{}
\startpar\input ward\stoppar
\startparagraph\input ward\stopparagraph
\stopsubsubsection
}

\startparagraph{\bf level 2} \input ward\stopparagraph
\stopsubsection
}

\startparagraph{\bf level 1} \input ward\stopparagraph
\stopsection
}

\stoptitle
\stoptext
Challenges:

1. How can we get automatic indentation for all heads *except* the first  
one that occurs after the \starttitle?


2. Look at the output of the adjusted version above - attached. Note that  
a subsubsection after a section gives


1.1
2.1

which are the same as those given by a subsection after a section. How can  
we get a subsubsection after a section to produce the following?


1.0.1
2.0.1

etc.

Thanks again, Pablo!
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512

numbered-paragraphs-pablo.pdf
Description: Adobe PDF document
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-06 Thread Pablo Rodriguez
On 08/06/2017 03:54 PM, Idris Samawi Hamid ادريس سماوي حامد wrote:
> In addition to the two dropbox links above, see the following:
> 
> https://people.umass.edu/klement/tlp/tlp.html#bodytext
> https://people.umass.edu/klement/tlp/tlp.pdf
> 
> The dropbox links (from Introduction to Hegel by GRG Mure) illustrate a
> combination of Wittgenstein numbering with paragraph indentation. So it is
> something of a hybrid between sectioning and paragraph numbering.
> 
> NOTE: A full implementation of Wittgenstein numbering is not required, and
> would probably not be wise except in the context of producing a ConTeXt
> edition of the Tractatus (something of zero interest to this writer).
> Indeed, Wittgenstein's numbering system is inconsistent or obscure in
> places... What we are looking for is something actually sane-)
Hi Idris,

I forgot to comment. If you want to reproduce the layout of the
Wittgenstein edition, margin heads would be a better approach.

But for that, we need first to present to Hans a unified proposal for
paralell streams.

I meant its layout, not the “Tractatus” itself :-).

Just in case it helps (the proposal ;-)),

Pablo
-- 
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-06 Thread Pablo Rodriguez
On 08/06/2017 03:54 PM, Idris Samawi Hamid ادريس سماوي حامد wrote:
> [...]
> Something along the lines of the following would be a sufficient (and
> easier) first step for the current project, although we may want to
> revisit the above for the future:
> 
> 3  % section
> 3.0.1   % subsubsection
> 
> 4  % section
> 4.1% subsection
> 4.1.1   % subsubsection
> 
> How can we automate this?

Hi Idris,

if you only need a printed version, I think the following approach might
help:

\setupwhitespace[big]

\setuphead[section]
[alternative=margintext,
 color=white,
 style=\tfxx,
 before=,
 after=,
 commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[sectionnumber][current]
\hspace[big]}}]}]

\setuphead[subsection]
[commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[subsectionnumber][current]
\hspace[big]}}]}]

\setuphead[subsubsection]
[commandafter={\setupparagraphintro[first]
[{{\bf \getmarking[subsubsectionnumber][current]
\hspace[big]}}]}]

\starttext

\dorecurse{3}{\section{}
\startpar\input ward\stoppar
\startpar\input ward\stoppar
\dorecurse{3}{\subsection{}
\startpar\input ward\stoppar
\startpar\input ward\stoppar
\dorecurse{3}{\subsubsection{}
\startpar\input ward\stoppar
\startpar\input ward\stoppar
\startpar\input ward\stoppar}
\startpar\input ward\stoppar}
\startpar\input ward\stoppar}

\stoptext

I hope it helps,

Pablo

-- 
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-06 Thread Idris Samawi Hamid ادريس سماوي حامد

On Sat, 05 Aug 2017 21:28:30 -0600, Idris Samawi Hamid ادريس سماوي حامد
 wrote:


The parameter insidesection= helps:


\setupwhitespace[big]

\def\SPACE#1{#1\hskip2em\hbox{}}
\setuphead[section]
[style=\bf,
 after={\blank[big]},
 before={\blank[big,medium]},
 color=walayahgreen,
 alternative=text,
 insidesection=\hskip-1.2em]
 % textcommand=\SPACE]
\setuphead[subsection]
[style=\bf,
 after={\blank[big]},
 before={\blank[big,medium]},
 color=walayahgreen,
 alternative=text,
 insidesection=\hskip-1.2em]
\setuphead[subsubsection]
[style=\bf,
 after={\blank[big]},
 before={\blank[big,medium]},
 color=walayahgreen,
 alternative=text,
 insidesection=\hskip-1.2em]

\define[1]\PARHEAD {{\bf{#1}}}

\starttext
\starttitle[title=Section 1]
\startsection[title=Paragraph 1]
\input ward
\stopsection

\startsection
\PARHEAD{Paragraph 2.} \input ward

\startparagraph
\input ward
\stopparagraph

\startsubsection
\input ward
\startsubsubsection
\input ward
\stopsubsubsection
\stopsubsection
\stopsection

\startsection
\input ward
\startsubsubsection
\input ward
\stopsubsubsection
\stopsection
\stoptitle
\stoptext


Paragraph 1 shows that we cannot use the normal title= mechanism and  
maintain consistent spacing.


Paragraph 2 does not use the \start|stopparagraph mechanism, but the  
succeeding non-numbered paragraph does.


CHALLENGES:

1. See the following:

https://www.dropbox.com/s/wckt0zm0zfpx721/numbered-paragraphs-indent.pdf?dl=0

The first numbered paragraph is not indented, but the second onward is.  
How can we automate this?


2. See attached. Consider the following snippet:

\startsection
\input ward
\startsubsubsection
\input ward
\stopsubsubsection
\stopsection

The paragraph number comes out as 3, but the subsubparagraph as 1. What  
we want is


3 
3.01 

The '0' indicates that there is no subsection. Here is an example:

https://www.dropbox.com/s/gy3e93x7jqt6ivx/numbered-paragraphs-indent-01.pdf?dl=0

How can we automate this?

Thanks in advance for any guidance and pointers.


In addition to the two dropbox links above, see the following:

https://people.umass.edu/klement/tlp/tlp.html#bodytext
https://people.umass.edu/klement/tlp/tlp.pdf

The dropbox links (from Introduction to Hegel by GRG Mure) illustrate a
combination of Wittgenstein numbering with paragraph indentation. So it is
something of a hybrid between sectioning and paragraph numbering.

NOTE: A full implementation of Wittgenstein numbering is not required, and
would probably not be wise except in the context of producing a ConTeXt
edition of the Tractatus (something of zero interest to this writer).
Indeed, Wittgenstein's numbering system is inconsistent or obscure in
places... What we are looking for is something actually sane-)

1. If we take the sectioning approach outlined above, then the challenges
are

i)  indent a section after a title; and
ii) implement something not identical to but in the spirit of wittgenstein
numbers, e.g., where a subsubsection follows a section:

3  % section
3.01   % subsubsection

4  % section
4.1% subsection
4.11   % subsubsection

But this may be difficult to automate except for simple cases.

Something along the lines of the following would be a sufficient (and
easier) first step for the current project, although we may want to
revisit the above for the future:

3  % section
3.0.1   % subsubsection

4  % section
4.1% subsection
4.1.1   % subsubsection

How can we automate this?

2. There may be better approaches than the sectioning model outlined in
the previous message.

Thank you in advance for your help.

Idris
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] methods for numbered paragraphs (ii)

2017-08-05 Thread Idris Samawi Hamid ادريس سماوي حامد
On Sat, 05 Aug 2017 14:08:28 -0600, Idris Samawi Hamid ادريس سماوي حامد  
 wrote:



[Sent this a couple of days ago, maybe will get some takers this time -)]

Dear syndicate,

Not sure if there is a canonical way to do numbered paragraphs. In the
following, I use subsections to mimic numbered paragraphs:

===section-intext.tex===
\setuphead[section][style=\bfa,after={\blank[big]},before={\blank[big,medium]},color=walayahblue]
\setuphead[subsection][style=\bf,after={\blank[big]},before={\blank[big,medium]},color=walayahgreen,alternative=text,distance=0.28em]
\setuphead[subsubsection][style=\tf,after={\blank[big]},before={\blank[big,medium]},color=walayahred,alternative=text,distance=0.28em]

\starttext
\startsection[title=Section 1]
\startsubsection
\input ward
\stopsubsection

\startsubsection[title=Paragraph 2]
\input ward
\stopsubsection

\startsubsection
\startparagraph
\input ward
\stopparagraph
\stopsubsection
\stopsection
\stoptext
==

See attached output.

In paragraphs 1 and 2, there is too much distance between the subsection
number (subsection number + title in paragraph 2) and between the text.
The distance parameter is not appropriate here, it is the distance  
*after*

the section head that needs adjustment (even if the text portion of the
head (i.e., the section title) is empty).

Question 1: How do we fix the post-head distance?


The parameter insidesection= helps:


\setupwhitespace[big]

\def\SPACE#1{#1\hskip2em\hbox{}}
\setuphead[section]
   [style=\bf,
after={\blank[big]},
before={\blank[big,medium]},
color=walayahgreen,
alternative=text,
insidesection=\hskip-1.2em]
% textcommand=\SPACE]
\setuphead[subsection]
   [style=\bf,
after={\blank[big]},
before={\blank[big,medium]},
color=walayahgreen,
alternative=text,
insidesection=\hskip-1.2em]
\setuphead[subsubsection]
   [style=\bf,
after={\blank[big]},
before={\blank[big,medium]},
color=walayahgreen,
alternative=text,
insidesection=\hskip-1.2em]

\define[1]\PARHEAD {{\bf{#1}}}

\starttext
\starttitle[title=Section 1]
\startsection[title=Paragraph 1]
\input ward
\stopsection

\startsection
\PARHEAD{Paragraph 2.} \input ward

\startparagraph
\input ward
\stopparagraph

\startsubsection
\input ward
\startsubsubsection
\input ward
\stopsubsubsection
\stopsubsection
\stopsection

\startsection
\input ward
\startsubsubsection
\input ward
\stopsubsubsection
\stopsection
\stoptitle
\stoptext


Paragraph 1 shows that we cannot use the normal title= mechanism and  
maintain consistent spacing.


Paragraph 2 does not use the \start|stopparagraph mechanism, but the  
succeeding non-numbered paragraph does.


CHALLENGES:

1. See the following:

https://www.dropbox.com/s/wckt0zm0zfpx721/numbered-paragraphs-indent.pdf?dl=0

The first numbered paragraph is not indented, but the second onward is.  
How can we automate this?


2. See attached. Consider the following snippet:

\startsection
\input ward
\startsubsubsection
\input ward
\stopsubsubsection
\stopsection

The paragraph number comes out as 3, but the subsubparagraph as 1. What we  
want is


3 
3.01 

The '0' indicates that there is no subsection. Here is an example:

https://www.dropbox.com/s/gy3e93x7jqt6ivx/numbered-paragraphs-indent-01.pdf?dl=0

How can we automate this?

Thanks in advance for any guidance and pointers.

Best wishes
Idris


Paragraph three shows that one apparently cannot mix this sectioning
approach with the \start-stopparagraph mechanism.

Question 2: Is there a way to mix \start-stopparagraph with the above
subsection approach to par numbering?

I suppose that as long as I maintain exactly one paragraph per  
subsection,

then structured output  (xml etc.) should look ok.

Question 3: Is there a wiser way to handle this kind of par numbering in
mkiv?

Thanks in advance!

Idris

--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512

section-intext.pdf
Description: Adobe PDF document
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] methods for numbered paragraphs (ii)

2017-08-05 Thread Idris Samawi Hamid ادريس سماوي حامد

[Sent this a couple of days ago, maybe will get some takers this time -)]

Dear syndicate,

Not sure if there is a canonical way to do numbered paragraphs. In the
following, I use subsections to mimic numbered paragraphs:

===section-intext.tex===
\setuphead[section][style=\bfa,after={\blank[big]},before={\blank[big,medium]},color=walayahblue]
\setuphead[subsection][style=\bf,after={\blank[big]},before={\blank[big,medium]},color=walayahgreen,alternative=text,distance=0.28em]
\setuphead[subsubsection][style=\tf,after={\blank[big]},before={\blank[big,medium]},color=walayahred,alternative=text,distance=0.28em]

\starttext
\startsection[title=Section 1]
\startsubsection
\input ward
\stopsubsection

\startsubsection[title=Paragraph 2]
\input ward
\stopsubsection

\startsubsection
\startparagraph
\input ward
\stopparagraph
\stopsubsection
\stopsection
\stoptext
==

See attached output.

In paragraphs 1 and 2, there is too much distance between the subsection
number (subsection number + title in paragraph 2) and between the text.
The distance parameter is not appropriate here, it is the distance *after*
the section head that needs adjustment (even if the text portion of the
head (i.e., the section title) is empty).

Question 1: How do we fix the post-head distance?

Paragraph three shows that one apparently cannot mix this sectioning
approach with the \start-stopparagraph mechanism.

Question 2: Is there a way to mix \start-stopparagraph with the above
subsection approach to par numbering?

I suppose that as long as I maintain exactly one paragraph per subsection,
then structured output  (xml etc.) should look ok.

Question 3: Is there a wiser way to handle this kind of par numbering in
mkiv?

Thanks in advance!

Idris
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80512

section-intext.pdf
Description: Adobe PDF document
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___