Skip to main content
typos
Source Link

If you put a block of code after a bullet point it doesn't get formatted properly unless there's an intervening line of normal text. Just blank lines doesn't do any good. See my examples below, the first demonstrate the problem, the second and third potential ways to mitigate it; one of which doesn't always apply and the second of which is a kludge with side effects.

  • Example 1: bullet point with empty lines after it. This breaks the code block.

    //4 spaces of indent - should be code block but not

      //8 spaces of indent - should be code block and indented 4 spaces but is 
      //showing as no indent in the code, but tehthe block as a while indented to 
      //match the last bullet.
    

  • Example 2: bullet point

Normal text after the bullet, this makes everything work correctly. But there isn't always something to reasonably put here.

//4 spaces of indent - works this time

    //8 spaces of indent - works this time

  • Example 3: bullet point with an   on the following line as a kludge to work around the problem. This makes the code format correct, but increases the amount of displayed whilespacewhite space.

 

//4 spaces of indent - works this time

    //8 spaces of indent - works this time

If you put a block of code after a bullet point it doesn't get formatted properly unless there's an intervening line of normal text. Just blank lines doesn't do any good. See my examples below, the first demonstrate the problem, the second and third potential ways to mitigate it; one of which doesn't always apply and the second of which is a kludge with side effects.

  • Example 1: bullet point with empty lines after it. This breaks the code block.

    //4 spaces of indent - should be code block but not

      //8 spaces of indent - should be code block and indented 4 spaces but is 
      //showing as no indent in the code, but teh block as a while indented to 
      //match the last bullet.
    

  • Example 2: bullet point

Normal text after the bullet, this makes everything work correctly. But there isn't always something to reasonably put here.

//4 spaces of indent - works this time

    //8 spaces of indent - works this time

  • Example 3: bullet point with an   on the following line as a kludge to work around the problem. This makes the code format correct, but increases the amount of displayed whilespace.

 

//4 spaces of indent - works this time

    //8 spaces of indent - works this time

If you put a block of code after a bullet point it doesn't get formatted properly unless there's an intervening line of normal text. Just blank lines doesn't do any good. See my examples below, the first demonstrate the problem, the second and third potential ways to mitigate it; one of which doesn't always apply and the second of which is a kludge with side effects.

  • Example 1: bullet point with empty lines after it. This breaks the code block.

    //4 spaces of indent - should be code block but not

      //8 spaces of indent - should be code block and indented 4 spaces but is 
      //showing as no indent in the code, but the block as a while indented to 
      //match the last bullet.
    

  • Example 2: bullet point

Normal text after the bullet, this makes everything work correctly. But there isn't always something to reasonably put here.

//4 spaces of indent - works this time

    //8 spaces of indent - works this time

  • Example 3: bullet point with an   on the following line as a kludge to work around the problem. This makes the code format correct, but increases the amount of displayed white space.

 

//4 spaces of indent - works this time

    //8 spaces of indent - works this time
Post Closed as "Duplicate" by Ken White, Qantas 94 Heavy, Mureinik, zessx, user2555451
edited tags
Link
Martijn Pieters
  • 1.1m
  • 96
  • 930
  • 755
edited tags
Link
Oded StaffMod
  • 498.3k
  • 40
  • 279
  • 255
Source Link
Loading