[('text',
  '\n'
  'Alternating text and code\n'
  '=========================\n'
  '\n'
  'Sphinx-Gallery is capable of transforming Python files into rST files\n'
  'with a notebook structure. For this to be used you need to respect some '
  'syntax\n'
  'rules. This example demonstrates how to alternate text and code blocks and '
  'some\n'
  'edge cases. It was designed to be compared with the\n'
  ':download:`source Python script <plot_parse.py>`.',
  1),
 ('text',
  'This is the first text block and directly follows the header docstring '
  'above.\n',
  14),
 ('code', '\nimport numpy as np\n\n', 15),
 ('code',
  '\n'
  "# a block separator (line of #'s) allows you to create two separate code "
  'blocks\n'
  'A = 1\n'
  '\n'
  'import matplotlib.pyplot as plt\n'
  '\n',
  19),
 ('text',
  'You can easily alternate between code and text blocks **and** separate\n'
  'sequential blocks of code (above) and text (below). Note that separated\n'
  'text blocks only shows as a new lines between text, in the rendered '
  'output.\n',
  26),
 ('text',
  "You can separate blocks using either a single line of ``#``'s (>=20 "
  'columns)\n'
  'or ``#%%``. For compatibility reasons ``# %%`` (with a space) can also be '
  'used\n'
  'but we recommend only using ``#%%`` for consistency. All future \n'
  "'block splitters' used in the source ``.py`` document will be ``#%%``.\n",
  31),
 ('code',
  '\n'
  'def dummy():\n'
  '    """This should not be part of a \'text\' block\'"""\n'
  '\n'
  '    #############################################\n'
  '    # Comment inside code to remain in code block\n'
  '    pass\n'
  '\n'
  "# this should not be part of a 'text' block\n"
  '\n',
  35),
 ('text',
  '####################################################################\n'
  '\n'
  'The above syntax makes a line cut in Sphinx. Note the space between the '
  'first\n'
  "``#`` and the line of ``#``'s.\n",
  46),
 ('text',
  '.. warning::\n'
  '    The next kind of comments are not supported and become too hard to '
  'escape\n'
  "    so just don't code like this::\n"
  '\n'
  '        def dummy2():\n'
  '            """Function docstring"""\n'
  '        ####################################\n'
  '        # This comment \n'
  '        #%%\n'
  '        # and this comment inside python indentation\n'
  '        # breaks the block structure and is not\n'
  '        # supported\n'
  '            dummy2\n'
  '\n',
  53),
 ('code',
  '\n'
  '"""Free strings are not supported. They will be rendered as a code '
  'block"""\n'
  '\n',
  67),
 ('text',
  'New lines can be included in your text block and the parser\n'
  'is capable of retaining this important whitespace to work with Sphinx.\n'
  'Everything after a block splitter and starting with ``#`` then one space,\n'
  'is interpreted by Sphinx-Gallery to be a rST text block. Keep your text\n'
  'block together using ``#`` and a space at the beginning of each line.\n'
  '\n'
  'rST header within text block\n'
  '^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n',
  71),
 ('code', "\nprint('one')\n\n", 79),
 ('code', '\n# another way to separate code blocks shown above\nB = 1\n\n', 84),
 ('text',
  'Last text block.\n'
  '\n'
  "That's all folks !\n"
  '\n'
  '.. literalinclude:: plot_parse.py\n'
  '\n'
  '\n',
  89)]