Foldable code in gedit

How to collapse a function, class or method in gedit. I managed to install all the plugins for gedit, but could not find any plugin for it.

+4
source share
3 answers

In gedit 3, I am now using my own plugin plugin, which others have been talking about. This is not perfect, but for me it’s still good. https://github.com/aeischeid/gedit-folding

+7
source

for ubuntu 10.04 this folding plugin works:

http://code.google.com/p/gedit-folding/downloads/list

set it for the user by setting it to

~/.gnome2/gedit/plugins/ 

or for the system

 /usr/lib/gedit-2/plugins/ 
0
source

I just found this updated version of gedit-folding:
http://code.google.com/p/gedit-folding/issues/detail?id=4

Just download folding.py and folding.gedit-plugin and save them in ~/.local/share/gedit/plugins , then turn on “Simple somersault” under “Edit”> “Settings”> “Plugins”.

To use, go to the beginning of the block and press Alt + Z. I gave it a quick test with Python, Javascript and HTML files, and it seems to have destroyed most of the blocks, except for multi-line lines and comments.

It's not perfect, but it's better than nothing, I think.

Update: I just tested it with badly indented code. Bending seems to be based only on indentation.

0
source

Source: https://habr.com/ru/post/1447261/


All Articles