andreikop / enki

A text editor for programmers
http://enki-editor.org
GNU General Public License v2.0
161 stars 38 forks source link

Feature: rainbow parentheses #80

Closed vi closed 11 years ago

vi commented 11 years ago

To be more Lisp-ready, text editor can support rainbow parentheses. It means matching pairs of parentheses should be displayed each using it's own colour.

Outermost parentheses can also be bolder.

andreikop commented 11 years ago

New code editor supports Closure highlighting, including rainbow parentheses. I'm using it since January, and planing to release first Beta in about 10 weeks.

vi commented 11 years ago

I see rainbow parthneses when I start Enki from "qutepart" branch.

andreikop commented 11 years ago

vi, have you tried to use qutepart (currently master) branch? I'm near to release it as next official, and interesting in your opinion

vi commented 11 years ago

Currently using "Version 12.08.5" as default Enki.

Will try to configure master Enki... How to do it properly preserving old Enki as well? Shall I use virtualenv?

andreikop commented 11 years ago

Hmm. I've never tried virtualenv, but should work.

You may also install qutepart to the system (./setup.py install), then run master enki from the sources (bin/enki)

vi commented 11 years ago

Doing something like this:

$ ./setup.py build
$ fakeroot checkinstall --pkgname local-qutepart -y -D --install=no --nodoc --fstrans --pkgversion 0.407.8b7781d2234 --exclude /home ./setup.py install
# dpkg -i local-qutepart_0.407.8b7781d2234-1_i386.deb

Trying to start bin/enki in e1cc36b84463e02e8f7593e26041fe699c2534c4.

CRITICAL:root:Traceback (most recent call last):
  File "/mnt/src/git/enki/bin/../enki/plugins/session.py", line 44, in _onRestoreSession
    core.workspace().openFile(filePath)
  File "/mnt/src/git/enki/bin/../enki/core/workspace.py", line 455, in openFile
    document = Document(self, filePath)
  File "/mnt/src/git/enki/bin/../enki/core/document.py", line 174, in __init__
    self._tryDetectSyntax()
  File "/mnt/src/git/enki/bin/../enki/core/document.py", line 178, in _tryDetectSyntax
    firstLine=self.qutepart.lines[0])
TypeError: detectSyntax() got an unexpected keyword argument 'firstLine'
CRITICAL:root:Traceback (most recent call last):
  File "bin/enki", line 256, in <module>
    sys.exit(main())
  File "bin/enki", line 222, in main
    core.workspace().createEmptyNotSavedDocument()
  File "/mnt/src/git/enki/bin/../enki/core/workspace.py", line 494, in createEmptyNotSavedDocument
    document = Document(self, filePath, createNew=True)
  File "/mnt/src/git/enki/bin/../enki/core/document.py", line 174, in __init__
    self._tryDetectSyntax()
  File "/mnt/src/git/enki/bin/../enki/core/document.py", line 178, in _tryDetectSyntax
    firstLine=self.qutepart.lines[0])
TypeError: detectSyntax() got an unexpected keyword argument 'firstLine'
Exception AttributeError: "'NoneType' object has no attribute 'actionManager'" in <bound method UISettingsManager.__del__ of <enki.core.uisettings.UISettingsManager object at 0x84dee3c>> ignored
andreikop commented 11 years ago

Have you pulled and installed the latest qutepart? Since first release enki will check, if compatible qutepart version is installed, but I don't do it now.

On Thu, Jun 6, 2013 at 4:25 PM, Vitaly Shukela notifications@github.comwrote:

Doing something like this:

$ ./setup.py build $ fakeroot checkinstall --pkgname local-qutepart -y -D --install=no --nodoc --fstrans --pkgversion 0.407.8b7781d2234 --exclude /home ./setup.py install

dpkg -i local-qutepart_0.407.8b7781d2234-1_i386.deb

Trying to start bin/enki in e1cc36bhttps://github.com/hlamer/enki/commit/e1cc36b84463e02e8f7593e26041fe699c2534c4 .

CRITICAL:root:Traceback (most recent call last): File "/mnt/src/git/enki/bin/../enki/plugins/session.py", line 44, in _onRestoreSession core.workspace().openFile(filePath) File "/mnt/src/git/enki/bin/../enki/core/workspace.py", line 455, in openFile document = Document(self, filePath) File "/mnt/src/git/enki/bin/../enki/core/document.py", line 174, in init self._tryDetectSyntax() File "/mnt/src/git/enki/bin/../enki/core/document.py", line 178, in _tryDetectSyntax firstLine=self.qutepart.lines[0]) TypeError: detectSyntax() got an unexpected keyword argument 'firstLine' CRITICAL:root:Traceback (most recent call last): File "bin/enki", line 256, in sys.exit(main()) File "bin/enki", line 222, in main core.workspace().createEmptyNotSavedDocument() File "/mnt/src/git/enki/bin/../enki/core/workspace.py", line 494, in createEmptyNotSavedDocument document = Document(self, filePath, createNew=True) File "/mnt/src/git/enki/bin/../enki/core/document.py", line 174, in init self._tryDetectSyntax() File "/mnt/src/git/enki/bin/../enki/core/document.py", line 178, in _tryDetectSyntax firstLine=self.qutepart.lines[0]) TypeError: detectSyntax() got an unexpected keyword argument 'firstLine' Exception AttributeError: "'NoneType' object has no attribute 'actionManager'" in <bound method UISettingsManager.del of <enki.core.uisettings.UISettingsManager object at 0x84dee3c>> ignored

— Reply to this email directly or view it on GitHubhttps://github.com/hlamer/enki/issues/80#issuecomment-19044654 .

vi commented 11 years ago

Qutepart is 8b7781d2234f737246440f2e3612284a3368d3f3, as mentioned in the log above.

andreikop commented 11 years ago

This commit has been done 2 month ago. Update to the master

On Thu, Jun 6, 2013 at 4:40 PM, Vitaly Shukela notifications@github.comwrote:

Qutepart is 8b7781dhttps://github.com/hlamer/enki/commit/8b7781d2234f737246440f2e3612284a3368d3f3, as mentioned in the log above.

— Reply to this email directly or view it on GitHubhttps://github.com/hlamer/enki/issues/80#issuecomment-19045480 .

vi commented 11 years ago

Installed the latest qutepart (0.440.695dede), master's enki started working.

First thoughts:

  1. "hot" startup time. Old enki: about 3 seconds, master enki: about 7 seconds;
  2. Additional black border is visible in qutepart enki;
  3. Memory usage (per ps_mem.py): old - about 23 MB; new - about 29 MB;
  4. C code and highlighting looking nicer in qutepart;
  5. No column editing / rectangular selection...
  6. Old enki: about 67 entries in keyboard shortcuts tree, cutepart enki: about 53 entries in the tree. Something's gone... "Edit" menu looks too small.
  7. Opening the same C file, placed cursor at top, holding "Down" button (so cursor is moving down and the text scrolling). Old enki: about 60% CPU usage; Qutepart enki: about 90% CPU usage.
  8. No Replace mode (Ins).

Will use master enki for some time, but currently like old one more (faster startup + column editing)...

vi commented 11 years ago

Maybe they can be combined? Enki starts in "lightweight editor" mode (without syntax highlight at all), then goes to qutepart mode...

andreikop commented 11 years ago
  1. "hot" startup time. Old enki: about 3 seconds, master enki: about 7 seconds;

Please subscribe to #83 (Watch thread menu at the bottom) so you will receive further updates. Comment issue there

  1. Additional black border is visible in qutepart enki;

Please subscribe to #84 and comment

  1. Memory usage (per ps_mem.py): old - about 23 MB; new - about 29 MB;

I think it is not a problem.

  1. C code and highlighting looking nicer in qutepart;

Yes, I also like more this colors

  1. No column editing / rectangular selection...

Please subscribe to #85 and comment

  1. Old enki: about 67 entries in keyboard shortcuts tree, cutepart enki: about 53 entries in the tree. Something's gone... "Edit" menu looks too small.

I'm happy about it. Simpler is better.

  1. Opening the same C file, placed cursor at top, holding "Down" button (so cursor is moving down and the text scrolling). Old enki: about 60% CPU usage; Qutepart enki: about 90% CPU usage.

Please subscribe to #87 and comment

  1. No Replace mode (Ins).

Please subscribe to #86 and comment

andreikop commented 11 years ago

I grouped the issues as qutepart-release milestone

vi commented 11 years ago

.9. Previous "Redo" shortcut was Ctrl+Y and was present in the main menu. Now it's Ctrl+Shift+Z and I can't find it in main menu...

andreikop commented 11 years ago

I've opened #88. Could you please open separate github issues. It is easier to comment and track it

andreikop commented 11 years ago

vi, give me your photo for http://enki-editor.org/team.html