ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Indent paragraph after \placefigure
@ 2011-03-26 22:37 Marco
  2011-03-26 23:15 ` Pontus Lurcock
  2011-03-27 17:45 ` Wolfgang Schuster
  0 siblings, 2 replies; 15+ messages in thread
From: Marco @ 2011-03-26 22:37 UTC (permalink / raw)
  To: ntg-context

How to indent the paragraph after a \placefigure?

Example:

\setupindenting [yes, medium]
\starttext
This line is indented as intended.

\placefigure[auto][fig:somefigure]{My graphic}{}

This is not, but I'd like it to be.

This line is fine.
\stoptext


Marco


___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Indent paragraph after \placefigure
  2011-03-26 22:37 Indent paragraph after \placefigure Marco
@ 2011-03-26 23:15 ` Pontus Lurcock
  2011-03-26 23:22   ` Marco
  2011-03-27 17:45 ` Wolfgang Schuster
  1 sibling, 1 reply; 15+ messages in thread
From: Pontus Lurcock @ 2011-03-26 23:15 UTC (permalink / raw)
  To: ntg-context

On Sat 26 Mar 2011, Marco wrote:

> How to indent the paragraph after a \placefigure?

http://wiki.contextgarden.net/Reference/en/setupindenting says that
\setupfloats[indentnext=yes] should give the desired result.
(I haven't tested it, though.)

Pont
___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Indent paragraph after \placefigure
  2011-03-26 23:15 ` Pontus Lurcock
@ 2011-03-26 23:22   ` Marco
  2011-03-27  0:15     ` Pontus Lurcock
  2011-03-27  7:12     ` Wolfgang Schuster
  0 siblings, 2 replies; 15+ messages in thread
From: Marco @ 2011-03-26 23:22 UTC (permalink / raw)
  To: ntg-context

On 2011-03-27 Pontus Lurcock <pont@talvi.net> wrote:

> On Sat 26 Mar 2011, Marco wrote:
> 
> > How to indent the paragraph after a \placefigure?
> 
> http://wiki.contextgarden.net/Reference/en/setupindenting says that
> \setupfloats[indentnext=yes] should give the desired result.
> (I haven't tested it, though.)

According to the manual \setupfloats[indentnext=yes] is the default behaviour.
But it's not working, same result here:

\setupindenting [yes, medium]
\setupfloats    [indentnext=yes]
\starttext
This line is indented as intended.

\placefigure[auto][fig:somefigure]{My graphic}{}

This is not, but I'd like it to be.

This line is fine.
\stoptext


Marco


___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Indent paragraph after \placefigure
  2011-03-26 23:22   ` Marco
@ 2011-03-27  0:15     ` Pontus Lurcock
  2011-03-27  0:22       ` Marco
  2011-03-27  7:12     ` Wolfgang Schuster
  1 sibling, 1 reply; 15+ messages in thread
From: Pontus Lurcock @ 2011-03-27  0:15 UTC (permalink / raw)
  To: ntg-context

Sorry, I think I misunderstood the problem the first time (since I
didn't actually run your example until now). \setupfloats[indentnext=yes]
(as I understand it) controls the behaviour after the float is actually
placed in the output, rather than after the \placefigure... in the
source.

I'd expect the blank line after the \placefigure to trigger
indentation for the next paragraph, but this doesn't happen. I now
remember seeing this problem while typesetting a thesis chapter. Going
back to my source file, I see I worked around it in the most obvious
way:

\setupindenting [yes, medium]
\setupfloats    [indentnext=yes]
\starttext
This line is indented as intended.

\placefigure[auto][fig:somefigure]{My graphic}{}

\indentation This is indented, but only because of the explicit command.

This line is fine.
\stoptext

Maybe there is a better solution, but I don't know it... hope this is
helpful anyway.

Regards,

Pont


On Sun 27 Mar 2011, Marco wrote:

> On 2011-03-27 Pontus Lurcock <pont@talvi.net> wrote:
> 
> > On Sat 26 Mar 2011, Marco wrote:
> > 
> > > How to indent the paragraph after a \placefigure?
> > 
> > http://wiki.contextgarden.net/Reference/en/setupindenting says that
> > \setupfloats[indentnext=yes] should give the desired result.
> > (I haven't tested it, though.)
> 
> According to the manual \setupfloats[indentnext=yes] is the default behaviour.
> But it's not working, same result here:
> 
> \setupindenting [yes, medium]
> \setupfloats    [indentnext=yes]
> \starttext
> This line is indented as intended.
> 
> \placefigure[auto][fig:somefigure]{My graphic}{}
> 
> This is not, but I'd like it to be.
> 
> This line is fine.
> \stoptext
> 
> 
> Marco
> 
___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Indent paragraph after \placefigure
  2011-03-27  0:15     ` Pontus Lurcock
@ 2011-03-27  0:22       ` Marco
  0 siblings, 0 replies; 15+ messages in thread
From: Marco @ 2011-03-27  0:22 UTC (permalink / raw)
  To: ntg-context

On 2011-03-27 Pontus Lurcock <pont@talvi.net> wrote:

> Sorry, I think I misunderstood the problem the first time (since I
> didn't actually run your example until now). \setupfloats[indentnext=yes]
> (as I understand it) controls the behaviour after the float is actually
> placed in the output, rather than after the \placefigure... in the
> source.
> 
> I'd expect the blank line after the \placefigure to trigger
> indentation for the next paragraph,but this doesn't happen.

Unfortunately not, no.

> I now remember seeing this problem while typesetting a thesis chapter. Going
> back to my source file, I see I worked around it in the most obvious way:

> \setupindenting [yes, medium]
> \setupfloats    [indentnext=yes]
> \starttext
> This line is indented as intended.
> 
> \placefigure[auto][fig:somefigure]{My graphic}{}
> 
> \indentation This is indented, but only because of the explicit command.
> 
> This line is fine.
> \stoptext
>
> Maybe there is a better solution,

I hope so. Scattering the source with explicit indentation requests is not
really desirable.


Marco


___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Indent paragraph after \placefigure
  2011-03-26 23:22   ` Marco
  2011-03-27  0:15     ` Pontus Lurcock
@ 2011-03-27  7:12     ` Wolfgang Schuster
  2011-03-27 12:18       ` Marco
  1 sibling, 1 reply; 15+ messages in thread
From: Wolfgang Schuster @ 2011-03-27  7:12 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 27.03.2011 um 00:22 schrieb Marco:

> On 2011-03-27 Pontus Lurcock <pont@talvi.net> wrote:
> 
>> On Sat 26 Mar 2011, Marco wrote:
>> 
>>> How to indent the paragraph after a \placefigure?
>> 
>> http://wiki.contextgarden.net/Reference/en/setupindenting says that
>> \setupfloats[indentnext=yes] should give the desired result.
>> (I haven't tested it, though.)
> 
> According to the manual \setupfloats[indentnext=yes] is the default behaviour.
> But it's not working, same result here:

It works when you drop the “auto” keyword.

Wolfgang

___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Indent paragraph after \placefigure
  2011-03-27  7:12     ` Wolfgang Schuster
@ 2011-03-27 12:18       ` Marco
  2011-03-27 21:14         ` Pontus Lurcock
  0 siblings, 1 reply; 15+ messages in thread
From: Marco @ 2011-03-27 12:18 UTC (permalink / raw)
  To: ntg-context

On 2011-03-27 Wolfgang Schuster <schuster.wolfgang@googlemail.com> wrote:

> 
> Am 27.03.2011 um 00:22 schrieb Marco:
> 
> > On 2011-03-27 Pontus Lurcock <pont@talvi.net> wrote:
> > 
> >> On Sat 26 Mar 2011, Marco wrote:
> >> 
> >>> How to indent the paragraph after a \placefigure?
> >> 
> >> http://wiki.contextgarden.net/Reference/en/setupindenting says that
> >> \setupfloats[indentnext=yes] should give the desired result.
> >> (I haven't tested it, though.)
> > 
> > According to the manual \setupfloats[indentnext=yes] is the default
> > behaviour. But it's not working, same result here:
> 
> It works when you drop the “auto” keyword.

Thanks. I don't really get the reason behind, but
it works.


Marco


___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Indent paragraph after \placefigure
  2011-03-26 22:37 Indent paragraph after \placefigure Marco
  2011-03-26 23:15 ` Pontus Lurcock
@ 2011-03-27 17:45 ` Wolfgang Schuster
  2011-03-27 20:09   ` Marco
  1 sibling, 1 reply; 15+ messages in thread
From: Wolfgang Schuster @ 2011-03-27 17:45 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 26.03.2011 um 23:37 schrieb Marco:

> How to indent the paragraph after a \placefigure?
> 
> Example:
> 
> \setupindenting [yes, medium]
> \starttext
> This line is indented as intended.
> 
> \placefigure[auto][fig:somefigure]{My graphic}{}
> 
> This is not, but I'd like it to be.
> 
> This line is fine.
> \stoptext

Not sure if there are side effects but adding \nonoindentation to these
two commands from strc-flt.mkiv help for the “auto” and “bottom” keywords.

- \def\somebottomfloat       [#1]{\someelsefloat[#1]}
- \def\someautofloat         [#1]{\someelsefloat[#1]}
+ \def\someautofloat         [#1]{\someelsefloat[#1]\nonoindentation}
+ \def\somebottomfloat       [#1]{\someelsefloat[#1]\nonoindentation}

Wolfgang

___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Indent paragraph after \placefigure
  2011-03-27 17:45 ` Wolfgang Schuster
@ 2011-03-27 20:09   ` Marco
  0 siblings, 0 replies; 15+ messages in thread
From: Marco @ 2011-03-27 20:09 UTC (permalink / raw)
  To: ntg-context

On 2011-03-27 Wolfgang Schuster <schuster.wolfgang@googlemail.com> wrote:

> Not sure if there are side effects but adding \nonoindentation to these
> two commands from strc-flt.mkiv help for the “auto” and “bottom” keywords.
> 
> - \def\somebottomfloat       [#1]{\someelsefloat[#1]}
> - \def\someautofloat         [#1]{\someelsefloat[#1]}
> + \def\someautofloat         [#1]{\someelsefloat[#1]\nonoindentation}
> + \def\somebottomfloat       [#1]{\someelsefloat[#1]\nonoindentation}

This works for me. Seems to be the best solution. Maye Hans can check if it
causes side effects and change it in the source if it's unlikely to cause
troubles.

Marco


___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Indent paragraph after \placefigure
  2011-03-27 12:18       ` Marco
@ 2011-03-27 21:14         ` Pontus Lurcock
  2011-03-27 21:49           ` Marco
  2011-03-27 22:53           ` Hans Hagen
  0 siblings, 2 replies; 15+ messages in thread
From: Pontus Lurcock @ 2011-03-27 21:14 UTC (permalink / raw)
  To: ntg-context

On Sun 27 Mar 2011, Marco wrote:

> > It works when you drop the “auto” keyword.
> 
> Thanks. I don't really get the reason behind, but it works.

When I drop the ‘auto’ keyword it defaults to ‘here’, which does give
the indentation (presumably because the figure now appears in the
output at the same place as the \placefigure in the input) but it
doesn't solve the problem for cases where the figure needs to be
somewhere other than ‘here’.

Pont
___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Indent paragraph after \placefigure
  2011-03-27 21:14         ` Pontus Lurcock
@ 2011-03-27 21:49           ` Marco
  2011-03-27 21:59             ` Pontus Lurcock
  2011-03-27 22:53           ` Hans Hagen
  1 sibling, 1 reply; 15+ messages in thread
From: Marco @ 2011-03-27 21:49 UTC (permalink / raw)
  To: ntg-context

On 2011-03-28 Pontus Lurcock <pont@talvi.net> wrote:

> On Sun 27 Mar 2011, Marco wrote:
> 
> > > It works when you drop the “auto” keyword.
> > 
> > Thanks. I don't really get the reason behind, but it works.
> 
> When I drop the ‘auto’ keyword it defaults to ‘here’, which does give
> the indentation (presumably because the figure now appears in the
> output at the same place as the \placefigure in the input) but it
> doesn't solve the problem for cases where the figure needs to be
> somewhere other than ‘here’.

Same here. But if you provide »top« for instance, then it works. Wolfgang came
up with a better solution, see his post in this thread. Maybe the patch will
go into the core.


Marco


___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Indent paragraph after \placefigure
  2011-03-27 21:49           ` Marco
@ 2011-03-27 21:59             ` Pontus Lurcock
  0 siblings, 0 replies; 15+ messages in thread
From: Pontus Lurcock @ 2011-03-27 21:59 UTC (permalink / raw)
  To: ntg-context

On Sun 27 Mar 2011, Marco wrote:

> Same here. But if you provide »top« for instance, then it works.

Looking at strc-flt.mkiv, the reason appears to be that the
\nonoindent which Wolfgang added to ‘bottom’ and ‘auto’ is alreday
present in ‘top’ and ‘margin’.

Pont
___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Indent paragraph after \placefigure
  2011-03-27 21:14         ` Pontus Lurcock
  2011-03-27 21:49           ` Marco
@ 2011-03-27 22:53           ` Hans Hagen
  2011-03-27 23:05             ` Marco
  2011-05-14 16:41             ` Steffen Wolfrum
  1 sibling, 2 replies; 15+ messages in thread
From: Hans Hagen @ 2011-03-27 22:53 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 27-3-2011 11:14, Pontus Lurcock wrote:
> On Sun 27 Mar 2011, Marco wrote:
>
>>> It works when you drop the “auto” keyword.
>>
>> Thanks. I don't really get the reason behind, but it works.
>
> When I drop the ‘auto’ keyword it defaults to ‘here’, which does give
> the indentation (presumably because the figure now appears in the
> output at the same place as the \placefigure in the input) but it
> doesn't solve the problem for cases where the figure needs to be
> somewhere other than ‘here’.

i can make that work but not now (mkiv-ing floats in later on the agenda)


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Indent paragraph after \placefigure
  2011-03-27 22:53           ` Hans Hagen
@ 2011-03-27 23:05             ` Marco
  2011-05-14 16:41             ` Steffen Wolfrum
  1 sibling, 0 replies; 15+ messages in thread
From: Marco @ 2011-03-27 23:05 UTC (permalink / raw)
  To: ntg-context

On 2011-03-28 Hans Hagen <pragma@wxs.nl> wrote:

> On 27-3-2011 11:14, Pontus Lurcock wrote:
> > On Sun 27 Mar 2011, Marco wrote:
> >
> >>> It works when you drop the “auto” keyword.
> >>
> >> Thanks. I don't really get the reason behind, but it works.
> >
> > When I drop the ‘auto’ keyword it defaults to ‘here’, which does give
> > the indentation (presumably because the figure now appears in the
> > output at the same place as the \placefigure in the input) but it
> > doesn't solve the problem for cases where the figure needs to be
> > somewhere other than ‘here’.
> 
> i can make that work but not now (mkiv-ing floats in later on the agenda)

Better later than never :)


Marco


___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Indent paragraph after \placefigure
  2011-03-27 22:53           ` Hans Hagen
  2011-03-27 23:05             ` Marco
@ 2011-05-14 16:41             ` Steffen Wolfrum
  1 sibling, 0 replies; 15+ messages in thread
From: Steffen Wolfrum @ 2011-05-14 16:41 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Hans Hagen


Am 28.03.2011 um 00:53 schrieb Hans Hagen:

> On 27-3-2011 11:14, Pontus Lurcock wrote:
>> On Sun 27 Mar 2011, Marco wrote:
>> 
>>>> It works when you drop the “auto” keyword.
>>> 
>>> Thanks. I don't really get the reason behind, but it works.
>> 
>> When I drop the ‘auto’ keyword it defaults to ‘here’, which does give
>> the indentation (presumably because the figure now appears in the
>> output at the same place as the \placefigure in the input) but it
>> doesn't solve the problem for cases where the figure needs to be
>> somewhere other than ‘here’.
> 
> i can make that work but not now (mkiv-ing floats in later on the agenda)


I can confirm the missing indent after \placetable[page]
After \placetable[page] there is also the page-header empty (no \getmarking[sectionnumber] nor \getmarking[section])

Steffen
___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

end of thread, other threads:[~2011-05-14 16:41 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-26 22:37 Indent paragraph after \placefigure Marco
2011-03-26 23:15 ` Pontus Lurcock
2011-03-26 23:22   ` Marco
2011-03-27  0:15     ` Pontus Lurcock
2011-03-27  0:22       ` Marco
2011-03-27  7:12     ` Wolfgang Schuster
2011-03-27 12:18       ` Marco
2011-03-27 21:14         ` Pontus Lurcock
2011-03-27 21:49           ` Marco
2011-03-27 21:59             ` Pontus Lurcock
2011-03-27 22:53           ` Hans Hagen
2011-03-27 23:05             ` Marco
2011-05-14 16:41             ` Steffen Wolfrum
2011-03-27 17:45 ` Wolfgang Schuster
2011-03-27 20:09   ` Marco

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 NNTP newsgroup(s).