Python Forum
Code folding in Sublime Text
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Code folding in Sublime Text
#1
Sublime Text automatically adds a fold/unfold block when detecting commands like:
if
while
def
try

I´d like to override this behaviour and define my own set of characters for folding/unfolding.
Exactly, I want #+ to indicate the beginning of a folding block and #- to indicate the end.

Is there a (not to complicated) way of achieving this in this editor?

Many thanks.
Reply


Messages In This Thread
Code folding in Sublime Text - by Mondata - Mar-12-2021, 06:44 AM
RE: Code folding in Sublime Text - by Larz60+ - Mar-12-2021, 09:35 AM
RE: Code folding in Sublime Text - by Mondata - Mar-12-2021, 04:16 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  while loop not working-I am using sublime text editor mma_python 4 1,172 Feb-05-2023, 06:26 PM
Last Post: deanhystad
  Folding in ATOM XavierPlatinum 5 1,251 Sep-11-2022, 09:21 PM
Last Post: XavierPlatinum
  Sublime Text Editor not recognizing Python elroberto 5 2,930 Jun-13-2022, 04:00 PM
Last Post: rob101
  How to link Sublime Text 3 Build system to Python 3.9 Using Windows 10 Fanman001 2 4,647 Mar-04-2021, 03:09 PM
Last Post: martpogs
  Sublime Text TechNitium 4 2,793 Jan-23-2021, 08:41 AM
Last Post: TechNitium
  sublime & intellisence luke83 0 1,645 Nov-20-2020, 08:26 PM
Last Post: luke83
  Sublime Text + Anaconda not indenting Python code correctly Maxximiliann 0 2,011 Jun-13-2020, 06:09 PM
Last Post: Maxximiliann
  switching from pycharm to sublime issue Drifter 2 2,026 Jun-09-2020, 09:19 PM
Last Post: Drifter
  Contextual pop-up menus in Sublime Text Mondata 4 2,468 Apr-08-2020, 06:32 PM
Last Post: buran
  Sublime Text 3 WinError 2 File Specified HelloWorld17 0 2,833 Apr-02-2020, 09:03 AM
Last Post: HelloWorld17

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020