0

This question comes from the fact that I try to recreate an already existing java docs document for learning purposes which has multiple levels of indentations where the next level of indentation has a different marking than the first one. I am trying to recreate this behavior.

It should look like this:

enter image description here

This is a refinement on this already answered question How to create multiple levels of indentation in Javadoc?

So far I only know how to create the bold black dots. Nesting does not changes the markings appearance, only creates the indentation.

<ul>
   <li> Example executions: </li>
</ul>
Community
  • 1
  • 1
Joop
  • 3,706
  • 34
  • 55
  • Have you tried nesting the second `
      ` *within* the `
    • ` element, as suggested in the comments of the answer you linked?
    – Joffrey Feb 06 '15 at 18:42
  • Of course, but as I said it only results in indenting but not any difference in appearance of the mark. – Joop Feb 06 '15 at 18:44
  • I just tried and it does change the mark. Look at my answer. – Joffrey Feb 06 '15 at 18:45

2 Answers2

1

You just need to properly nest within the <li> element:

<ul>
    <li>Try this:
        <ul>
             <li>And this</li>
        <ul>
    </li>
</ul>

Which gives this result by default:

enter image description here

As opposed to:

<ul>
    <li>Try this:</li>
    <ul>
         <li>And this</li>
    <ul>
</ul>

Which does not change the type of mark.

Joffrey
  • 32,348
  • 6
  • 68
  • 100
  • Don't know why but for javadoc 7 this does not work for me using Linux and creating the javadoc through the terminal. – Joop Feb 06 '15 at 18:48
  • It seems weird to me. How do you read the generated html files? – Joffrey Feb 06 '15 at 18:51
  • With chrome? I simply just click on one of the generated .html files and navigate through there. I literally copy and pasted your example and put it in javadoc /** etc style. It did the same as I had before. I also expected it to auto change the mark when indenting.. but it didn't for me. – Joop Feb 06 '15 at 19:03
1

You can use CSS for this and give the <ul> or <ol> tag the attribute style="list-style-type:YOURTYPE. This way you can specify the appearence.

<ul>
    <li> Foo </li>
    <ul style="list-style-type:circle">
        <li> Bar </li>
    </ul>
</ul>

For unordered lists there are the following possibilities:

disc Default. A filled circle.

circle An unfilled circle.

square A filled square.

If you are going to use ordered lists as well, a search engine will do the work and tell you all possibilities for the style.

Community
  • 1
  • 1
Marco
  • 330
  • 3
  • 12