ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <pragma@wxs.nl>
To: ntg-context@ntg.nl
Subject: Re: Prefix for figure number lost in unnumbered subsection
Date: Wed, 13 May 2015 23:13:52 +0200	[thread overview]
Message-ID: <5553BE90.8070807@wxs.nl> (raw)
In-Reply-To: <CALBOmsYO5SpBvDZi7keAmS07mcqLzY4N8t4qnDcUuBr-eVNM1w@mail.gmail.com>

On 5/13/2015 10:25 PM, Mojca Miklavec wrote:

> Thank you. This solves the problem, but isn't current behaviour
> (without "incrementnumber=no") some kind of a bug?

maybe, but more a side effect i think .. the incrementnumber is the 
official way to have an unumbered section (in fact 'subject's are the way)

> - Once a figure gets a number like "3.4", isn't it a bug if the
> reference to that figure says "Figure 4"?
> - (I find it a bit problematic that figures are numbered "1.1", "2", "1.3".)

there is a bit of history behind this:

- in mkii we stored the numbers like 1:2:3:4 in the utility file
- so in order to get less prefixes in for isntance a list we had to 
parse that number
- which was possible because we knew the level
- but then getting pieces colors or in an other font was kind of tricky 
(but diable)
- the same for converted numbers
- for mixed usage there was no way to distinguish rendering

but in mkiv, we do it different:

- each number is stored along with the used prefix so we can exactly 
match them
- but we can also configure them differently as we have all information 
available
- of course overloaded numbers are also handled

> While I could at least understand why implementing the second thing
> properly might be a bit more challenging, I don't understand why a
> reference would ever be allowed to change the original label.

well, you think so, but all you can't imagine get requested ... the same 
for the way prefixes are dealt with; we have documents with several 
interwoven number systems and we can have more or less suffixes in 
different sections of a document, image, reference .. whatever, so 
whenever a number is requested there is now full control over the prefix 
(what components to use) as well as the number (what components to show) 
.. indeed complex

not much different from users mixing fonts that don't match well

> I'm experiencing a similar problem with figures in appendices (I
> already reported it, but I need to find that mail).

there are quite some example posts by wolfgang .. there are also some 
examples in the test suite

> And there's another tiny problem that's partially a consequence of a
> human mistake. If a reference is missing, \in[reference] would print
> "??". But if one accidentally tries to reference some unnumbered
> subsubsection, \in doesn't print anything to even remotely indicate an
> error. (The origin of the error was initially referencing
> subsubsections in one chapter, then removing numbers of subsubsections
> for the sake of another chapter and it took a while until the problem
> was spotted.)

maybe some day i'll add a bit more tracing but keep in mind that when 
one user asks for ?? another asks for nothing (the log can show some 
info too, and there is actually a truckload of trackers to help you)

\enabletrackers[*refer*]
\enabletrackers[*destin*]


> Mojca
>
>
>>> On Fri, May 8, 2015 at 5:36 PM, Mojca Miklavec wrote:
>>>>
>>>> Hi,
>>>>
>>>> Consider the following example where I wanted to remove subsubsection
>>>> numbers (as one ends with way too many numbers otherwise). The figure
>>>> numbering is screwed up, I get:
>>>> - Figure 1.1
>>>> - Figure 2
>>>> - Figure 1.3
>>>>
>>>> \setuphead
>>>>       [subsubsection]
>>>>       [number=no]
>>>> \starttext
>>>> \chapter{Chapter A}
>>>> \section{Section B}
>>>> \subsection{Subsection C}
>>>> \placefigure[force]{correct prefix}{test}
>>>> \subsubsection{Subsubsection D}
>>>> \placefigure[force]{no prefix number}{test}
>>>> \subsection{Subsection E}
>>>> \placefigure[force]{correct prefix}{test}
>>>> \stoptext
>>>>
>>>> How to fix that?
>>>>
>>>> Thank you,
>>>>       Mojca
>>>
>>>
>>> ___________________________________________________________________________________
>>> 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
>>>
>>> ___________________________________________________________________________________
>>>
>>
>>
>> --
>>
>> -----------------------------------------------------------------
>>                                            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
>> ___________________________________________________________________________________
> ___________________________________________________________________________________
> 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
> ___________________________________________________________________________________
>


-- 

-----------------------------------------------------------------
                                           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
___________________________________________________________________________________

      reply	other threads:[~2015-05-13 21:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-08 15:36 Mojca Miklavec
2015-05-13  8:38 ` Mojca Miklavec
2015-05-13 10:04   ` Hans Hagen
2015-05-13 20:25     ` Mojca Miklavec
2015-05-13 21:13       ` Hans Hagen [this message]

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5553BE90.8070807@wxs.nl \
    --to=pragma@wxs.nl \
    --cc=ntg-context@ntg.nl \
    /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.
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).