Boost logo

Boost :

Subject: Re: [boost] [review][autoindex] AutoIndex review extended
From: Barend Gehrels (barend_at_[hidden])
Date: 2011-05-15 11:53:25


Hi John,

On 15-5-2011 11:43, John Maddock wrote:
>>> Not at present no.... I'm not really sure how one would even do
>>> that, there would have to be some kind of docbook XML container that
>>> was used to represent "don't index this block". Can you provide an
>>> example of a spurious entry? It could be that tweaking the scanning
>>> regular expressions used could fix this.
>>
>>
>> I understand. After more thought, maybe it is not so bad that the
>> samples are indexed. Because the indexed terms are really shown there
>> in their context.
>>
>> There were some spurious index terms as "p", "r", "for", probably
>> because of the samples, and they could be turned off as documented.
>>
>> Then there are spurious terms as "point_type" because in the example
>> I often typedef a point a "point_type", but that term also exists as
>> a regular, indexable, entry. They have either to be turned off
>> manually, or turned on in specific sections, or I've to rename them
>> to e.g. ptype in the examples (which might actually be better).
>
> Hmmm, the trouble is, assuming it's searching for something along the
> lines of
>
> typedef something point_type;
>
> Then that will occur both where you want it to be indexed (class
> definitions) and where you don't (example code).
>
> So that leaves you with two options - either a section constraint (see
> my comments below), or exclude that term altogether and add a manual
> index entry for it by escaping to XML and adding the necessary
> <indexterm>'s. I accept that's a touch hardcore though!

I would not prefer the last option indeed...

>
>> But turning them off for specific sections does not work for me,
>> probably I do something wrong. I define:
>>
>> point_type "" "(?!geometry.reference.adapted.register.*).*"
>>
>> to omit it from all sections starting with
>> reference.adapted.register, but the point_type still appears there. I
>> copied and pasted it from the doc. I added !debug regular-expression
>> , I don't see anything in the log. I'm not a regex-expert and don't
>> see what is wrong here.
>
> Nor do I, the debug info in the other mail suggests it should not be
> indexed, so I can't see what's wrong.... can you let me have your
> index-script file so I can try it here?

It is attached. I tried some other things, and don't get it working,
either by including those sections, or by excluding them.

Note that to build our documentation you will need some additional steps
(we convert from Doxygen to Qbk - the converted files are not in SVN),
if you want I can send off-list a zip with generated content such that
calling bjam is sufficient

>
>> Another question about this: is it possible to exclude a term twice?
>> So e.g.
>>
>> point_type "" "(?!geometry.reference.adapted.register.*).*"
>> point_type "" "(?!geometry.reference.exclude_also_from_this.*).*"
>
> Ah, you can do that, but it takes the union (logical or) of the two
> regexes, and that's not what you want here, which is more akin to a
> logical and.
>
>> Or do I have to write a more complex regex for this?
>
> Nod, something like:
>
> "(?!geometry.reference.adapted.register.*|geometry.reference.exclude_also_from_this.*).*"
>
>
> I guess I should make this clearer in the docs...

That would be useful.

Regards, Barend





Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk