Roger Binns schrieb:
>> The label should be
>> 
>> .. _mylabel:
>> 
>> Perhaps this is why it did not work. 
> 
> I hand typed the email and forgot the underscore.  My real doc had the
> underscore.
> 
>> Apart from that, there should be no
>> difference at all between a code block and a code block in a blockquote.
> 
> Perhaps HTML output will illustrate the problem.  If I have:
> 
> .. _mylabel:
> 
> .. code-block:: python
> 
>    foo
> 
> Then the output is:
> 
> <div class="highlight"><pre>...foo...</pre></div>
> 
> ie mylabel is not a link target even though I referenced it elsewhere.
> If I do this:
> 
> .. _mylabel:
> 
>    .. code-block:: python
> 
>        foo
> 
> Then the output is:
> 
> <blockquote id="mylabel">
>   <div class="highlight"><pre>...foo...</pre></div>
> </blockquote>
> 
> My "complaint" is that code blocks have to be indented to be labelled,
> and that if you do so then the HTML uses blockquote which effectively
> uses an inch on either side of the page as border which looks ugly and
> also causes problems for long code lines.

I see. I'm sorry I didn't try it out before giving you a false hint :)

This is a bug -- the highlighted <div> should get the same id attribute
as the blockquote if not indented. It should be fixed in SVN now.

Georg


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to