Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC

Commits:

24 changed files:

Changes:

  • utils/haddock/doc/.gitignore
    1
    -.build-html
    \ No newline at end of file
    1
    +.build-html
    
    2
    +.build-latex
    
    3
    +!_static

  • utils/haddock/doc/Makefile
    1 1
     SPHINX_BUILD ?= sphinx-build
    
    2 2
     
    
    3
    -all : html
    
    3
    +all : html pdf
    
    4 4
     
    
    5 5
     .PHONY : html
    
    6
    +.PHONY : pdf
    
    6 7
     
    
    7 8
     html :
    
    8 9
     	$(SPHINX_BUILD) -b html . .build-html
    
    10
    +
    
    11
    +pdf :
    
    12
    +	$(SPHINX_BUILD) -b latex . .build-latex
    
    13
    +	cd .build-latex && make

  • utils/haddock/doc/_static/haddock-custom.css
    1
    +.result.admonition {
    
    2
    +  border: solid 3px #eee;
    
    3
    +  border-top: none;
    
    4
    +  background-color: transparent;
    
    5
    +  padding: 1px 0px 10px 10px;
    
    6
    +  margin: 0px 0px -20px 0px;
    
    7
    +  position: relative;
    
    8
    +  top: -18px;
    
    9
    +}
    
    10
    +
    
    11
    +.result.admonition p.admonition-title{
    
    12
    +  position: absolute;
    
    13
    +  visibility: hidden;
    
    14
    +}
    
    15
    +
    
    16
    +/* Use a small font size for code blocks so that they don't overflow. */
    
    17
    +pre {
    
    18
    +  font-size: 0.8em;
    
    19
    +}

  • utils/haddock/doc/conf.py
    ... ... @@ -31,6 +31,12 @@ pygments_style = 'tango'
    31 31
     
    
    32 32
     htmlhelp_basename = 'Haddockdoc'
    
    33 33
     
    
    34
    +html_static_path = ['_static']
    
    35
    +
    
    36
    +html_css_files = [
    
    37
    +    'haddock-custom.css',
    
    38
    +]
    
    39
    +
    
    34 40
     
    
    35 41
     # -- Options for LaTeX output ---------------------------------------------
    
    36 42
     
    

  • utils/haddock/doc/markup.rst
    ... ... @@ -1004,99 +1004,162 @@ Itemized and Enumerated Lists
    1004 1004
     
    
    1005 1005
     A bulleted item is represented by preceding a paragraph with either
    
    1006 1006
     “``*``” or “``-``”. A sequence of bulleted paragraphs is rendered as an
    
    1007
    -itemized list in the generated documentation, e.g.: ::
    
    1007
    +itemized list in the generated documentation, e.g.
    
    1008 1008
     
    
    1009
    -    -- | This is a bulleted list:
    
    1010
    -    --
    
    1011
    -    --     * first item
    
    1012
    -    --
    
    1013
    -    --     * second item
    
    1009
    +.. literalinclude:: snippets/Lists.hs
    
    1010
    +    :lines: 3-7
    
    1011
    +
    
    1012
    +.. admonition:: Result
    
    1013
    +    :class: result
    
    1014
    +
    
    1015
    +    .. only:: html
    
    1016
    +
    
    1017
    +        .. raw:: html
    
    1018
    +            :file: snippets/Snippet-List-Bulleted.html
    
    1019
    +
    
    1020
    +    .. only:: latex
    
    1021
    +
    
    1022
    +        .. raw:: latex
    
    1023
    +            :file: snippets/Snippet-List-Bulleted.tex
    
    1024
    +
    
    1025
    +.. warning::
    
    1026
    +
    
    1027
    +    Separate lists from any preceding markup with at least one blank line
    
    1028
    +    otherwise the list and its items will be rendered with the preceding
    
    1029
    +    content.
    
    1030
    +
    
    1031
    +.. literalinclude:: snippets/Lists.hs
    
    1032
    +    :lines: 10-12
    
    1033
    +
    
    1034
    +.. admonition:: Result
    
    1035
    +    :class: result
    
    1036
    +
    
    1037
    +    .. only:: html
    
    1038
    +
    
    1039
    +        .. raw:: html
    
    1040
    +            :file: snippets/Snippet-List-Not-Separated.html
    
    1041
    +
    
    1042
    +    .. only:: latex
    
    1043
    +
    
    1044
    +        .. raw:: latex
    
    1045
    +            :file: snippets/Snippet-List-Not-Separated.tex
    
    1014 1046
     
    
    1015 1047
     An enumerated list is similar, except each paragraph must be preceded by
    
    1016
    -either “``(n)``” or “``n.``” where n is any integer. e.g. ::
    
    1048
    +either “``(n)``” or “``n.``” where n is any integer. e.g.
    
    1017 1049
     
    
    1018
    -    -- | This is an enumerated list:
    
    1019
    -    --
    
    1020
    -    --     (1) first item
    
    1021
    -    --
    
    1022
    -    --     2. second item
    
    1050
    +.. literalinclude:: snippets/Lists.hs
    
    1051
    +    :lines: 15-19
    
    1023 1052
     
    
    1024
    -Lists of the same type don't have to be separated by a newline: ::
    
    1053
    +.. admonition:: Result
    
    1054
    +    :class: result
    
    1025 1055
     
    
    1026
    -    -- | This is an enumerated list:
    
    1027
    -    --
    
    1028
    -    --     (1) first item
    
    1029
    -    --     2. second item
    
    1030
    -    --
    
    1031
    -    -- This is a bulleted list:
    
    1032
    -    --
    
    1033
    -    --     * first item
    
    1034
    -    --     * second item
    
    1056
    +    .. only:: html
    
    1035 1057
     
    
    1036
    -You can have more than one line of content in a list element: ::
    
    1058
    +        .. raw:: html
    
    1059
    +            :file: snippets/Snippet-List-Enumerated.html
    
    1037 1060
     
    
    1038
    -    -- |
    
    1039
    -    -- * first item
    
    1040
    -    -- and more content for the first item
    
    1041
    -    -- * second item
    
    1042
    -    -- and more content for the second item
    
    1061
    +    .. only:: latex
    
    1062
    +
    
    1063
    +        .. raw:: latex
    
    1064
    +            :file: snippets/Snippet-List-Enumerated.tex
    
    1065
    +
    
    1066
    +Lists of the same type don't have to be separated by a newline:
    
    1067
    +
    
    1068
    +.. literalinclude:: snippets/Lists.hs
    
    1069
    +    :lines: 22-30
    
    1070
    +
    
    1071
    +.. admonition:: Result
    
    1072
    +    :class: result
    
    1073
    +
    
    1074
    +    .. only:: html
    
    1075
    +
    
    1076
    +        .. raw:: html
    
    1077
    +            :file: snippets/Snippet-List-Not-Newline.html
    
    1078
    +
    
    1079
    +    .. only:: latex
    
    1080
    +
    
    1081
    +        .. raw:: latex
    
    1082
    +            :file: snippets/Snippet-List-Not-Newline.tex
    
    1083
    +
    
    1084
    +You can have more than one line of content in a list element:
    
    1085
    +
    
    1086
    +.. literalinclude:: snippets/Lists.hs
    
    1087
    +    :lines: 33-37
    
    1088
    +
    
    1089
    +.. admonition:: Result
    
    1090
    +    :class: result
    
    1091
    +
    
    1092
    +    .. only:: html
    
    1093
    +
    
    1094
    +        .. raw:: html
    
    1095
    +            :file: snippets/Snippet-List-Multiline-Item.html
    
    1096
    +
    
    1097
    +    .. only:: latex
    
    1098
    +
    
    1099
    +        .. raw:: latex
    
    1100
    +            :file: snippets/Snippet-List-Multiline-Item.tex
    
    1043 1101
     
    
    1044 1102
     You can even nest whole paragraphs inside of list elements. The rules
    
    1045 1103
     are 4 spaces for each indentation level. You're required to use a
    
    1046
    -newline before such nested paragraphs: ::
    
    1047
    -
    
    1048
    -    {-|
    
    1049
    -    * Beginning of list
    
    1050
    -    This belongs to the list above!
    
    1104
    +newline before such nested paragraphs:
    
    1051 1105
     
    
    1052
    -        > nested
    
    1053
    -        > bird
    
    1054
    -        > tracks
    
    1106
    +.. literalinclude:: snippets/Lists.hs
    
    1107
    +    :lines: 40-61
    
    1055 1108
     
    
    1056
    -        * Next list
    
    1057
    -        More of the indented list.
    
    1109
    +.. admonition:: Result
    
    1110
    +    :class: result
    
    1058 1111
     
    
    1059
    -            * Deeper
    
    1112
    +    .. only:: html
    
    1060 1113
     
    
    1061
    -                @
    
    1062
    -                even code blocks work
    
    1063
    -                @
    
    1114
    +        .. raw:: html
    
    1115
    +            :file: snippets/Snippet-List-Nested-Item.html
    
    1064 1116
     
    
    1065
    -                * Deeper
    
    1117
    +    .. only:: latex
    
    1066 1118
     
    
    1067
    -                        1. Even deeper!
    
    1068
    -                        2. No newline separation even in indented lists.
    
    1069
    -    -}
    
    1119
    +        .. raw:: latex
    
    1120
    +            :file: snippets/Snippet-List-Nested-Item.tex
    
    1070 1121
     
    
    1071 1122
     The indentation of the first list item is honoured. That is, in the
    
    1072 1123
     following example the items are on the same level. Before Haddock
    
    1073 1124
     2.16.1, the second item would have been nested under the first item
    
    1074
    -which was unexpected. ::
    
    1125
    +which was unexpected.
    
    1075 1126
     
    
    1076
    -    {-|
    
    1077
    -        * foo
    
    1127
    +.. literalinclude:: snippets/Lists.hs
    
    1128
    +    :lines: 64-68
    
    1078 1129
     
    
    1079
    -        * bar
    
    1080
    -    -}
    
    1130
    +.. admonition:: Result
    
    1131
    +    :class: result
    
    1132
    +
    
    1133
    +    .. only:: html
    
    1134
    +
    
    1135
    +        .. raw:: html
    
    1136
    +            :file: snippets/Snippet-List-Indentation.html
    
    1137
    +
    
    1138
    +    .. only:: latex
    
    1139
    +
    
    1140
    +        .. raw:: latex
    
    1141
    +            :file: snippets/Snippet-List-Indentation.tex
    
    1081 1142
     
    
    1082 1143
     Definition Lists
    
    1083 1144
     ~~~~~~~~~~~~~~~~
    
    1084 1145
     
    
    1085
    -Definition lists are written as follows: ::
    
    1146
    +Definition lists are written as follows:
    
    1086 1147
     
    
    1087
    -    -- | This is a definition list:
    
    1088
    -    --
    
    1089
    -    --   [@foo@]: The description of @foo@.
    
    1090
    -    --
    
    1091
    -    --   [@bar@]: The description of @bar@.
    
    1148
    +.. literalinclude:: snippets/Lists.hs
    
    1149
    +    :lines: 71-75
    
    1150
    +
    
    1151
    +.. admonition:: Result
    
    1152
    +    :class: result
    
    1153
    +
    
    1154
    +    .. only:: html
    
    1092 1155
     
    
    1093
    -To produce output something like this:
    
    1156
    +        .. raw:: html
    
    1157
    +            :file: snippets/Snippet-List-Definition.html
    
    1094 1158
     
    
    1095
    -``foo``
    
    1096
    -    The description of ``foo``.
    
    1159
    +    .. only:: latex
    
    1097 1160
     
    
    1098
    -``bar``
    
    1099
    -    The description of ``bar``.
    
    1161
    +        .. raw:: latex
    
    1162
    +            :file: snippets/Snippet-List-Definition.tex
    
    1100 1163
     
    
    1101 1164
     Each paragraph should be preceded by the “definition term” enclosed in
    
    1102 1165
     square brackets and followed by a colon. Other markup operators may be
    

  • utils/haddock/doc/snippets/.gitignore
    1
    +*.html
    
    2
    +*.tex
    
    3
    +haddock-bundle.min.js
    
    4
    +haddock.sty
    
    5
    +linuwial.css
    
    6
    +main.tex
    
    7
    +meta.json
    
    8
    +quick-jump.css
    
    9
    +synopsis.png
    
    10
    +
    
    11
    +!Snippet*.html
    
    12
    +!Snippet*.tex

  • utils/haddock/doc/snippets/Lists.hs
    1
    +module Lists where
    
    2
    +
    
    3
    +-- | This is a bulleted list:
    
    4
    +--
    
    5
    +--     * first item
    
    6
    +--
    
    7
    +--     * second item
    
    8
    +data Bulleted
    
    9
    +
    
    10
    +-- | __Missing blank lines__ before a list:
    
    11
    +--     * first item
    
    12
    +--     * second item
    
    13
    +data Before
    
    14
    +
    
    15
    +-- | This is an, (n) n., enumerated list:
    
    16
    +--
    
    17
    +--     (1) first item
    
    18
    +--
    
    19
    +--     2. second item
    
    20
    +data Enumerated
    
    21
    +
    
    22
    +-- | This is an enumerated list, with items not separated by newlines:
    
    23
    +--
    
    24
    +--     (1) first item
    
    25
    +--     2. second item
    
    26
    +--
    
    27
    +-- This is a bulleted list, with items not separated by newlines:
    
    28
    +--
    
    29
    +--     * first item
    
    30
    +--     * second item
    
    31
    +data NotNewline
    
    32
    +
    
    33
    +-- |
    
    34
    +-- * first item
    
    35
    +-- and more content for the first item
    
    36
    +-- * second item
    
    37
    +-- and more content for the second item
    
    38
    +data MultilineItem
    
    39
    +
    
    40
    +{-|
    
    41
    +* Beginning of list
    
    42
    +This belongs to the list above!
    
    43
    +
    
    44
    +    > nested
    
    45
    +    > bird
    
    46
    +    > tracks
    
    47
    +
    
    48
    +    * Next list
    
    49
    +    More of the indented list.
    
    50
    +
    
    51
    +        * Deeper
    
    52
    +
    
    53
    +            @
    
    54
    +            even code blocks work
    
    55
    +            @
    
    56
    +
    
    57
    +            * Deeper
    
    58
    +
    
    59
    +                    1. Even deeper!
    
    60
    +                    2. No newline separation even in indented lists.
    
    61
    +-}
    
    62
    +data NestedItem
    
    63
    +
    
    64
    +{-|
    
    65
    +    * foo
    
    66
    +
    
    67
    +    * bar
    
    68
    +-}
    
    69
    +data Indentation
    
    70
    +
    
    71
    +-- | This is a definition list:
    
    72
    +--
    
    73
    +--   [@foo@]: The description of @foo@.
    
    74
    +--
    
    75
    +--   [@bar@]: The description of @bar@.
    
    76
    +data DefinitionList
    \ No newline at end of file

  • utils/haddock/doc/snippets/Makefile
    1
    +# \newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +HDK_BEGIN := \\\\newcommand{\\haddockbegindoc}{\\hfill\\\\\[1ex]}
    
    3
    +
    
    4
    +# \newcommand{\haddockverb}{\small}
    
    5
    +HDK_VERB := \\\\newcommand{\\haddockverb}{\\small}
    
    6
    +
    
    7
    +# \newcommand{\haddocktt}[1]{{\small \texttt{#1}}}
    
    8
    +HDK_TT := \\\\newcommand{\\haddocktt}[1]{{\\small \\\\texttt{\#1}}}
    
    9
    +
    
    10
    +all: \
    
    11
    +  Snippet-List-Bulleted.html \
    
    12
    +  Snippet-List-Bulleted.tex \
    
    13
    +  Snippet-List-Not-Separated.html \
    
    14
    +  Snippet-List-Not-Separated.tex \
    
    15
    +  Snippet-List-Enumerated.html \
    
    16
    +  Snippet-List-Enumerated.tex \
    
    17
    +  Snippet-List-Not-Newline.html \
    
    18
    +  Snippet-List-Not-Newline.tex \
    
    19
    +  Snippet-List-Multiline-Item.html \
    
    20
    +  Snippet-List-Multiline-Item.tex \
    
    21
    +  Snippet-List-Nested-Item.html \
    
    22
    +  Snippet-List-Nested-Item.tex \
    
    23
    +  Snippet-List-Indentation.html \
    
    24
    +  Snippet-List-Indentation.tex \
    
    25
    +  Snippet-List-Definition.html \
    
    26
    +  Snippet-List-Definition.tex
    
    27
    +
    
    28
    +clean:
    
    29
    +	rm -f Lists*.html
    
    30
    +
    
    31
    +Lists.html: Lists.hs
    
    32
    +	haddock --html $^
    
    33
    +
    
    34
    +Lists.tex: Lists.hs
    
    35
    +	haddock --latex $^
    
    36
    +
    
    37
    +# Using pandoc-3.1.3
    
    38
    +Lists-Pretty.html: Lists.html
    
    39
    +	pandoc $^ -o $@
    
    40
    +
    
    41
    +# Using tex-fmt-0.4.1
    
    42
    +# nix profile install github:wgunderwood/tex-fmt
    
    43
    +Lists-Pretty.tex: Lists.tex
    
    44
    +	cp $^ $@
    
    45
    +	tex-fmt $@
    
    46
    +
    
    47
    +Snippet-List-Bulleted.html: Lists-Pretty.html
    
    48
    +	sed -n '48,52p;53q' $^ > $@
    
    49
    +
    
    50
    +Snippet-List-Bulleted.tex: Lists-Pretty.tex
    
    51
    +	echo "$(HDK_BEGIN)" > $@
    
    52
    +	sed -n '18,26p;27q' $^ >> $@
    
    53
    +
    
    54
    +Snippet-List-Not-Separated.html: Lists-Pretty.html
    
    55
    +	sed -n '59,60p;61q' $^ > $@
    
    56
    +
    
    57
    +Snippet-List-Not-Separated.tex: Lists-Pretty.tex
    
    58
    +	echo "$(HDK_BEGIN)" > $@
    
    59
    +	sed -n '33,36p;37q' $^ >> $@
    
    60
    +
    
    61
    +Snippet-List-Enumerated.html: Lists-Pretty.html
    
    62
    +	sed -n '68,72p;73q' $^ > $@
    
    63
    +
    
    64
    +Snippet-List-Enumerated.tex: Lists-Pretty.tex
    
    65
    +	echo "$(HDK_BEGIN)" > $@
    
    66
    +	sed -n '43,51p;52q' $^ >> $@
    
    67
    +
    
    68
    +Snippet-List-Not-Newline.html: Lists-Pretty.html
    
    69
    +	sed -n '80,89p;90q' $^ > $@
    
    70
    +
    
    71
    +Snippet-List-Not-Newline.tex: Lists-Pretty.tex
    
    72
    +	echo "$(HDK_BEGIN)" > $@
    
    73
    +	sed -n '58,74p;75q' $^ >> $@
    
    74
    +
    
    75
    +Snippet-List-Multiline-Item.html: Lists-Pretty.html
    
    76
    +	sed -n '97,100p;101q' $^ > $@
    
    77
    +
    
    78
    +Snippet-List-Multiline-Item.tex: Lists-Pretty.tex
    
    79
    +	echo "$(HDK_BEGIN)" > $@
    
    80
    +	sed -n '81,90p;91q' $^ >> $@
    
    81
    +
    
    82
    +Snippet-List-Nested-Item.html: Lists-Pretty.html
    
    83
    +	sed -n '108,127p;128q' $^ > $@
    
    84
    +
    
    85
    +Snippet-List-Nested-Item.tex: Lists-Pretty.tex
    
    86
    +	echo "$(HDK_BEGIN)" > $@
    
    87
    +	echo "$(HDK_VERB)" >> $@
    
    88
    +	sed -n '97,141p;142q' $^ >> $@
    
    89
    +
    
    90
    +Snippet-List-Indentation.html: Lists-Pretty.html
    
    91
    +	sed -n '135,138p;139q' $^ > $@
    
    92
    +
    
    93
    +Snippet-List-Indentation.tex: Lists-Pretty.tex
    
    94
    +	echo "$(HDK_BEGIN)" > $@
    
    95
    +	sed -n '148,155p;156q' $^ >> $@
    
    96
    +
    
    97
    +Snippet-List-Definition.html: Lists-Pretty.html
    
    98
    +	sed -n '146,156p;157q' $^ > $@
    
    99
    +
    
    100
    +Snippet-List-Definition.tex: Lists-Pretty.tex
    
    101
    +	echo "$(HDK_BEGIN)" > $@
    
    102
    +	echo "$(HDK_TT)" >> $@
    
    103
    +	sed -n '162,170p;171q' $^ >> $@

  • utils/haddock/doc/snippets/Snippet-List-Bulleted.html
    1
    +<p>This is a bulleted list:</p>
    
    2
    +<ul>
    
    3
    +<li>first item</li>
    
    4
    +<li>second item</li>
    
    5
    +</ul>

  • utils/haddock/doc/snippets/Snippet-List-Bulleted.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +  {\haddockbegindoc
    
    3
    +    This is a bulleted list:\par
    
    4
    +    \vbox{
    
    5
    +      \begin{itemize}
    
    6
    +        \item
    
    7
    +          first item\par
    
    8
    +        \item
    
    9
    +          second item\par
    
    10
    +      \end{itemize}}}

  • utils/haddock/doc/snippets/Snippet-List-Definition.html
    1
    +<p>This is a definition list:</p>
    
    2
    +<dl>
    
    3
    +<dt><code>foo</code></dt>
    
    4
    +<dd>
    
    5
    +The description of <code>foo</code>.
    
    6
    +</dd>
    
    7
    +<dt><code>bar</code></dt>
    
    8
    +<dd>
    
    9
    +The description of <code>bar</code>.
    
    10
    +</dd>
    
    11
    +</dl>

  • utils/haddock/doc/snippets/Snippet-List-Definition.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +\newcommand{\haddocktt}[1]{{\small \texttt{#1}}}
    
    3
    +  {\haddockbegindoc
    
    4
    +    This is a definition list:\par
    
    5
    +    \vbox{
    
    6
    +      \begin{description}
    
    7
    +        \item[\haddocktt{foo}]\hfill \par
    
    8
    +          The description of \haddocktt{foo}.
    
    9
    +        \item[\haddocktt{bar}]\hfill \par
    
    10
    +          The description of \haddocktt{bar}.
    
    11
    +      \end{description}}}

  • utils/haddock/doc/snippets/Snippet-List-Enumerated.html
    1
    +<p>This is an, (n) n., enumerated list:</p>
    
    2
    +<ol>
    
    3
    +<li>first item</li>
    
    4
    +<li>second item</li>
    
    5
    +</ol>

  • utils/haddock/doc/snippets/Snippet-List-Enumerated.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +  {\haddockbegindoc
    
    3
    +    This is an, (n) n., enumerated list:\par
    
    4
    +    \vbox{
    
    5
    +      \begin{enumerate}
    
    6
    +        \item
    
    7
    +          first item\par
    
    8
    +        \item
    
    9
    +          second item\par
    
    10
    +      \end{enumerate}}}

  • utils/haddock/doc/snippets/Snippet-List-Indentation.html
    1
    +<ul>
    
    2
    +<li>foo</li>
    
    3
    +<li>bar</li>
    
    4
    +</ul>

  • utils/haddock/doc/snippets/Snippet-List-Indentation.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +  {\haddockbegindoc
    
    3
    +    \vbox{
    
    4
    +      \begin{itemize}
    
    5
    +        \item
    
    6
    +          foo\par
    
    7
    +        \item
    
    8
    +          bar\par
    
    9
    +      \end{itemize}}}

  • utils/haddock/doc/snippets/Snippet-List-Multiline-Item.html
    1
    +<ul>
    
    2
    +<li>first item and more content for the first item</li>
    
    3
    +<li>second item and more content for the second item</li>
    
    4
    +</ul>

  • utils/haddock/doc/snippets/Snippet-List-Multiline-Item.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +  {\haddockbegindoc
    
    3
    +    \vbox{
    
    4
    +      \begin{itemize}
    
    5
    +        \item
    
    6
    +          first item
    
    7
    +          and more content for the first item\par
    
    8
    +        \item
    
    9
    +          second item
    
    10
    +          and more content for the second item\par
    
    11
    +      \end{itemize}}}

  • utils/haddock/doc/snippets/Snippet-List-Nested-Item.html
    1
    +<ul>
    
    2
    +<li><p>Beginning of list This belongs to the list above!</p>
    
    3
    +<pre><code>nested
    
    4
    +bird
    
    5
    +tracks</code></pre>
    
    6
    +<ul>
    
    7
    +<li><p>Next list More of the indented list.</p>
    
    8
    +<ul>
    
    9
    +<li><p>Deeper</p>
    
    10
    +<pre><code>even code blocks work</code></pre>
    
    11
    +<ul>
    
    12
    +<li><p>Deeper</p>
    
    13
    +<ol>
    
    14
    +<li>Even deeper!</li>
    
    15
    +<li>No newline separation even in indented lists.</li>
    
    16
    +</ol></li>
    
    17
    +</ul></li>
    
    18
    +</ul></li>
    
    19
    +</ul></li>
    
    20
    +</ul>

  • utils/haddock/doc/snippets/Snippet-List-Nested-Item.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +\newcommand{\haddockverb}{\small}
    
    3
    +  {\haddockbegindoc
    
    4
    +    \vbox{
    
    5
    +      \begin{itemize}
    
    6
    +        \item
    
    7
    +          Beginning of list
    
    8
    +          This belongs to the list above!\par
    
    9
    +          \begin{quote}
    
    10
    +            {\haddockverb
    
    11
    +              \begin{verbatim}
    
    12
    +nested
    
    13
    +bird
    
    14
    +tracks
    
    15
    +            \end{verbatim}}
    
    16
    +          \end{quote}
    
    17
    +          \vbox{
    
    18
    +            \begin{itemize}
    
    19
    +              \item
    
    20
    +                Next list
    
    21
    +                More of the indented list.\par
    
    22
    +                \vbox{
    
    23
    +                  \begin{itemize}
    
    24
    +                    \item
    
    25
    +                      Deeper\par
    
    26
    +                      \begin{quote}
    
    27
    +                        {\haddockverb
    
    28
    +                          \begin{verbatim}
    
    29
    +even code blocks work
    
    30
    +                        \end{verbatim}}
    
    31
    +                      \end{quote}
    
    32
    +                      \vbox{
    
    33
    +                        \begin{itemize}
    
    34
    +                          \item
    
    35
    +                            Deeper\par
    
    36
    +                            \vbox{
    
    37
    +                              \begin{enumerate}
    
    38
    +                                \item
    
    39
    +                                  Even deeper!\par
    
    40
    +                                \item
    
    41
    +                                  No newline separation even in
    
    42
    +                                  indented lists.\par
    
    43
    +                              \end{enumerate}}
    
    44
    +                        \end{itemize}}
    
    45
    +                  \end{itemize}}
    
    46
    +            \end{itemize}}
    
    47
    +      \end{itemize}}}

  • utils/haddock/doc/snippets/Snippet-List-Not-Newline.html
    1
    +<p>This is an enumerated list, with items not separated by newlines:</p>
    
    2
    +<ol>
    
    3
    +<li>first item</li>
    
    4
    +<li>second item</li>
    
    5
    +</ol>
    
    6
    +<p>This is a bulleted list, with items not separated by newlines:</p>
    
    7
    +<ul>
    
    8
    +<li>first item</li>
    
    9
    +<li>second item</li>
    
    10
    +</ul>

  • utils/haddock/doc/snippets/Snippet-List-Not-Newline.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +  {\haddockbegindoc
    
    3
    +    This is an enumerated list, with items not separated by newlines:\par
    
    4
    +    \vbox{
    
    5
    +      \begin{enumerate}
    
    6
    +        \item
    
    7
    +          first item\par
    
    8
    +        \item
    
    9
    +          second item\par
    
    10
    +      \end{enumerate}}
    
    11
    +    This is a bulleted list, with items not separated by newlines:\par
    
    12
    +    \vbox{
    
    13
    +      \begin{itemize}
    
    14
    +        \item
    
    15
    +          first item\par
    
    16
    +        \item
    
    17
    +          second item\par
    
    18
    +      \end{itemize}}}

  • utils/haddock/doc/snippets/Snippet-List-Not-Separated.html
    1
    +<p><strong>Missing blank lines</strong> before a list: * first item *
    
    2
    +second item</p>

  • utils/haddock/doc/snippets/Snippet-List-Not-Separated.tex
    1
    +\newcommand{\haddockbegindoc}{\hfill\\[1ex]}
    
    2
    +  {\haddockbegindoc
    
    3
    +    \textbf{Missing blank lines} before a list:
    
    4
    +    * first item
    
    5
    +  * second item\par}