#255 Add an option to display a solid line after folded code

closed-fixed
None
3
2008-08-28
2008-08-27
MCh
No

Right now, when some code is folded, it gobbles an empty line at the end of the section. For example,

\begin{figure}
\includegraphics{...}
\end{figure}

Some text...

gets folded as:

\begin{figure}
Some text...

However, I think it would be better and improve readability (maybe as an option?) if it would leave the empty line after "\end{figure}" and get folded as:

\begin{figure}

Some text...

Regards,

Martin.

Discussion

  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-27

    Logged In: YES
    user_id=2166098
    Originator: NO

    Just add a comment after the environment:

    \begin{figure}
    \end{figure}
    %

    text...

    Works fine for me. An alternative would be to display a horizontal line below the fold point. Other than that, there are plans to modify Scintilla's folding behavior.

     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-27

    Logged In: YES
    user_id=2166098
    Originator: NO

    Sorry, I meant there are *no* plans to modify Scintilla.

     
  • MCh

    MCh - 2008-08-27

    Logged In: YES
    user_id=1582270
    Originator: YES

    Ok. So I think a horizontal line (or an empty line?) would improve readability.

    Regards,

    Martin.

     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-27
    • priority: 5 --> 3
     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-27

    Logged In: YES
    user_id=2166098
    Originator: NO

    The feature has been added to the official feature list.

    Thank you for your report.

     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-27
    • summary: Leave empty line of folded code --> Add an option to display a line after folded code
     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-27
    • summary: Add an option to display a line after folded code --> Add an option to display a solid line after folded code
     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-28
    • assigned_to: nobody --> sergiudotenco
     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-28
    • status: open --> closed
     
  • Sergiu Dotenco

    Sergiu Dotenco - 2008-08-28
    • status: closed --> closed-fixed
     
  • Matthis Thorade

    Matthis Thorade - 2011-01-28

    Sorry for digging up this old issue, but the behavior is still the same in TXC 2.0 Alpha3 and I would agree to the original poster that it would be nicer and more reader-friendly not to "eat up" all the empty lines.
    I would consider adding comments a workaround only.

    Notepad++ is also Scintilla based and code folding there only folds the lines from \begin{figure} to \end{figure}, leaving the empty lines untouched and displays a horizontal line, making folded parts easy to find.

    Cheers

     
  • Sergiu Dotenco

    Sergiu Dotenco - 2011-01-28

    Did you try unchecking the Compact option in the Editor settings?

     
  • Matthis Thorade

    Matthis Thorade - 2011-01-31

    Hi,
    thank you very much, that solved the problem and I am sorry for not finding that option myself (I just found the checkbox for displaying the solid lines, but I did not understand that the 'Compact' option controls the behavior regarding empty lines for code folding).
    So now I have my empty lines and a solid line, making me an even happier TXC user than ever :-)

    TXC has options to display a solid line before or after the folded code. The default folding behavior in SciTe is that it shows a solid line instead of the code, so that the folded result looks like

    \begin{figure}
    ------------------------------------------------------------------------------------------
    \end{figure}

    Would it be hard to make this behavior possile in TXC as well?

     


Anonymous

Cancel  Add attachments





Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks