ox-twbs icon indicating copy to clipboard operation
ox-twbs copied to clipboard

TOC not recognizing non-numbered sections

Open zhangda82 opened this issue 9 years ago • 7 comments

Hi Brandon,

I started using the TOC, and I saw another strange behavior: When I have #+OPTIONS: H:2 num:1 toc:t i.e., headline level (H:) > accepted number of section levels (num:), the TOC was generated, but the links of the non-numbered items on the TOC mess up. For example, try the following code for ox-twbs export and the behavior of links in the TOC. Thanks!

#+OPTIONS: H:2 num:1 toc:t
#+OPTIONS: \n:t
#+OPTIONS: ^:nil
#+OPTIONS: <:nil todo:t *:t ^:{} ::t |:t TeX:t

* Plan 
** 1 
** 2 
** 3 
** 4
* Summary 
** Important tasks/projects done this week 
** Drawbacks 
** Thoughts/Comments 
** Time usage

Thanks for looking into this.

Da

zhangda82 avatar Mar 07 '16 18:03 zhangda82

I created a document similar to what you describe, and it seemed to export ok. I put a bunch of content between each section to ensure table-of-contents links worked. Perhaps the behavior you are thinking is a bug, is just the somewhat unsatisfactory feeling of clicking on anchor links already visible?

Sorry if I'm misunderstanding! Here is link to example doc: http://clubctrl.com/org/prog/foo.html

marsmining avatar Mar 07 '16 21:03 marsmining

Can you try this org file instead? Also see the html file generated. Thanks!

Da

On Mon, Mar 7, 2016 at 4:08 PM, Brandon van Beekum <[email protected]

wrote:

I created a document similar to what you describe, and it seemed to export ok. I put a bunch of content between each section to ensure table-of-contents links worked. Perhaps the behavior you are thinking is a bug, is just the somewhat unsatisfactory feeling of clicking on anchor links already visible?

Sorry if I'm misunderstanding! Here is link to example doc: http://clubctrl.com/org/prog/foo.html

— Reply to this email directly or view it on GitHub https://github.com/marsmining/ox-twbs/issues/23#issuecomment-193449340.

zhangda82 avatar Mar 07 '16 21:03 zhangda82

I did, and it worked. Can you perhaps explain what the problem is more specifically?

marsmining avatar Mar 07 '16 21:03 marsmining

Thanks for the quick reply! I created a screen shot. When clicking "Drawbacks", the entire TOC was highlighted, and the cursor was at Section 1.1. [image: Inline image 1]

On Mon, Mar 7, 2016 at 4:21 PM, Brandon van Beekum <[email protected]

wrote:

I did, and it worked. Can you perhaps explain what the problem is more specifically?

— Reply to this email directly or view it on GitHub https://github.com/marsmining/ox-twbs/issues/23#issuecomment-193456740.

zhangda82 avatar Mar 07 '16 21:03 zhangda82

I couldn't see the screenshot, sorry! Perhaps try setting num:t and see if that helps. If you don't want headline numbering use whn:nil. I describe whn here.

marsmining avatar Mar 08 '16 07:03 marsmining

How about this time? Thanks for your
  help!

  Da


On 3/8/2016 2:11 AM, Brandon van Beekum
  wrote:


  I couldn't see the screenshot, sorry! Perhaps try setting num:t
    and see if that helps. If you don't want headline numbering use
    whn:nil. I describe whn here.
  —
    Reply to this email directly or view
      it on GitHub.

zhangda82 avatar Mar 08 '16 14:03 zhangda82

Can you share the org file header you used for generating http://clubctrl.com/org/prog/foo.html ? I want to figure out why my setting does not work. Thank you.

Da

zhangda82 avatar Mar 09 '16 23:03 zhangda82