Hi, is there a way to change the color of matched parenthesis automatic selection in the IPython console?
I'm using a dark theme, and the white selection that the console is using along with the almost white text that my theme has is making me very difficult to recognize where my cursor is when I'm calling a procedure. Here you can see some screenshots:
It would be nice if the new feature of color scheme matching in the ipython console could cover matched parenthesis and selection text as well.
If there's a way by editing some config file, please let me know. It's kinda frustrating to guess if my cursor is already inside parenthesis or outside.
Or if I could disable matched parens in the ipython console would be nice too.
I'm using:
Spyder 3.2.0
IPython 6.1.0
Python 3.5.2
Ubuntu 16.04
I think that color is hard-coded in qtconsole, the package that we depend on to provide our IPython console. So we'd need to change things there.
We'll see what we can do about this in a future release of qtconsole.
@ccordoba12 I can look into this if you want since it is affecting me as well.
I was hoping for you to say that! Thanks!
Since this is a new feature, please remember to do your PR against master.
El 25/07/17 a las 08:35, Jean-Sébastien Gosselin escribió:
>
@ccordoba12 https://github.com/ccordoba12 I can look into this if
you want since it is affecting me as well.—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/spyder-ide/spyder/issues/4806#issuecomment-317739037,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAWS7W775g08uBoDIjuBDYl015ld636lks5sRe8RgaJpZM4Oh1yA.
@ccordoba12
Firstly, while working on this, I've discovered that unlike the rest of the Spyder application, the colour for highlighting the text is hard coded to light gray with a style sheet in the IPython console. It would be possible to simply remove everything related to selection_background_color
in create_qss_style, so that the highlighting is the same in the IPython console as for the rest of the application.
Secondly, it is possible to set the _matched bracket color_ in the IPython console to the color specified in the preferences directly in the ShellWidget since this property is exposed in the BracketMatcher of the qtconsole
. There is no need to change anything in the qtconsole, only in the ShellWidget.
That being said, the BracketMatcher
of the qtconsole
does not have the ability to highlight _unmatched bracket_ with a different colour like it is done in the editor. To add this functionality, then we would have to add it to the BracketMatcher
. I think this would not be too complicated since all the logic is already in the Editor.
There, PR addresses point 1 and 2 of my previous comment. @ccordoba12 should we do something about point 3?
Point 3 requires changes in qtconsole, not here. If you are willing to do them, please go for it :-)
@ccordoba12 I think I'm going to... :) so maybe we wait until you merge so I can change PR #4813 accordingly?
Edit: added link to the PR I was referring to
so I can change the PR accordingly?
What PR?
@ccordoba12 please, see edit to my previous comment.
Oh, don't worry, you can open a new PR for point 3. I think what we have in PR #4813 is good enough to merge it as it is.
@ccordoba12 Okidooki, here is the PR i've created for point 3 in the qtconsole repo: https://github.com/jupyter/qtconsole/pull/228
If it is accepted, we will only need to add one line to shell.py to link it with Spyder preferences.