I have a text editor I'm working on. Using PyCharm. I have line number support (many thanks to Bryan Oakley!) and python syntax highlighting using IDLE Perculator. It works but some of the highlight code is hard to read. Oh yes, using tkinter for GUI support.
Can anyone point me at how to set the colors in IDLE? I use options-configure IDLE and some of the changes work in my project and some don't. For example, disabling the colors in my find funcion in the editor doesn't use the 'found' attribute when I alter the 'found' highlight colors. It only highlights what is found when I set the foreground and background colors.
I would prefer to edit a file so I know what it is highlighting, such as comments, strings, keywords, etc.
The IDLE Perculator works better than all of the highlight code I tested.
Just been trying to work out how to set the highlight colors to what I want. Either light or dark themes.
Found basic doc. for IDLE but nothing on how to figure out what is what. Only some settings take effect.
I found all of the idlelib source in the appdata folders and put it into my project folder. I know can set the backgrounds in the IDLE shell for the various keywords etc. Looks ok for a dark theme now. When I run or compile I get the colors I set in the IDE in my text (editor) widget. I still have to set the default text colors in my app. When I don't, I get black text on white background which looks terrible in the dark theme.
So a little more work...
I just installed Anaconda and running Spyder I cannot find the Object Inspector. Hitting Ctrl+I has no effect and in the View/Panes menu there is no item Object Inspector.
I have seen videos and tutorials that show the Object Inspector. What is happening?
The "Object Inspector" is now called "Help" (from Spyder version 3.0 onwards); see https://groups.google.com/forum/#!topic/spyderlib/pF7KmSKDFXc . However, the Ctrl-I shortcut has not been changed, so I'm not sure what's happening with that.
go to preferences > Help and enable the Automatic connections for Editor and restart the Spyder
This worked for me!!
Although it's given in the tutorials but I'll explain.
1) Object Inspector is now known as Help.
2) I'm using Spyder 3.6, here go to Tools-->Preferences-->Help-->Check on Editor in Automatic Connections
3) Select your parameter and Ctrl+I
That'll do it.
I had the same problem. I found the help and then discovered that I got a message saying No Documentation. I tried changing the setting from Rich Text to Plain Text and for some reason that worked and I'm able to use the Object Inspector.
Since they changed "Object Inspector" to "Help", as Jitse Niesen says, they might have changed the shortcut too. In my Mac version the shortcut for "Help" is Shift+Cmd+H so the combination you are looking for is probably Ctrl+H.
On mac using Spyder 3.3.1 run from Anaconda.
Cmd + I was not working for me at first to show the object inspector on the right pane for help on a particular function. So I typed in Cmd + , (which is to access preferences panel in any app on Mac), and went down to "Help" on the left side.
Then, I checked the boxes for "Editor" and "IPython Console" under the description that says
"This pane can automatically show an object's help information after a left parenthesis is written next to it. Below you can decide to which plugin you want to connect it to turn on this feature."
After checking these boxes and pressing OK, Cmd + I still did not work for getting the object information.
I restarted Spyder, closing it and reopening it from Anaconda navigator.
Now Cmd + I works and shows the information for whatever function I click on.
Hope this helps someone. I'm still not quite sure what happened here (since those checkboxes were for the left parenthesis function), but I still thought that sharing the steps will be useful to some people.
In Windows, Ctrl+Shift+H worked after making changes to preferences as suggested by Ibrahem
Go to preferences->Help and tick the option of showing object info on Editor , then ctrl+I will work with any object
One way to go about this is to go to View > Panes > Online Help. Then in the search box insert the module or package like so (sklearn.preprocessing.Imputer) and you will have all the docs related to the package.(**Shortest way: click on package....then Cmd + i )
Alternatively, right clicking the Object in the editor, select Go to Definition
Third way, in your console, type help(your class here) like help(Imputer) or just help() to get the interactive console then type your package there (sklearn.preprocessing.Imputer`).
Hope this help someone.
After pressing Ctrl+H , a help window will come in that in [Source] dropdown select Console
Please check the spelling of your command, if you type wrong spelling it wont display the help
Note that in Spyder version 3.2.4 under Tools>Preferences>Help>Automatic Connections it clearly now states: "This pane can automatically show an object's help information after a left parenthesis is written next to it. Below you can decide to which plugin you want to connect it to turn on this feature." Then you can select Editor and/or IPython Console.
When I tried this, placing a left parenthesis before the (term is the only way I could get the help to bring up an example and a definition.
Nothing worked from above. I can debug objects easy in Visual Studio Code, but I can not do it in Spyder 3.2.8 installed with Anaconda 5.2 for Windows. In IPython console during debugging I use following.
To inspect an object:
vars(my_object)
To list class objects:
[obj.name for obj in gc.get_objects() if isinstance(obj, my_class)]
This solution solved the problem and shows objects in Variable Explorer.
https://gitter.im/spyder-ide/public?at=5b69bac8e9ab53770ca018d0
Question:
How can I explore objects during debugging like I explore variables?
In IPython consle I use vars(my_object), this is a prompt way. I want a GUI way for Object like Variable explorer.
I want a GUI way for Object like Variable explorer.
Answer:
As a matter of fact, Spyder has one, exactly like the Variable Explorer: it's called...the Variable Explorer! If you can't see them, make sure Exclude unsupported data types is not selected under the "Gear" menu in the top right of the pane.
Most arbitrary objects should work, although there may occasionally be a few bugs for more esoteric ones. Even better support will be coming in Spyder 4.
Just left click on the top right corner, beside the close tab of editor and below the working directory tab
I tried it, and it successfully worked.
There are terminal and python console in pycharm, which are very convenient. But I found that the font size was too small to recognize in terminal or python console. How can change the font size in the terminal or python console?
In PyCharm 2016.3, the console font setting is squirrelled away under Settings > Editor > Colors & Fonts > Console Font:
Note: Changes to the colors and font are not visible immediately, you have to restart the terminal session to apply them. It's not enough to just hide and reopen the terminal. Just click the red cross button on the terminal's toolbar (Close Terminal Session) and reopen it. The same is valid also for the Python Console.
The location of console font changed in the latest versions of Pycharm.
Settings -> Editor -> Color Scheme -> Console Font
Go to File\Settings\Editor\Color & Fonts and choose save as to save currently used schema by a new name in order to make changes on a new schema. Then in mentioned direction go to console font and set size.
I thought it doesn't work for me either but the problem was that:
you have to close all terminal windows to see the spacing effect.
A simple google search would have lead you here.
You just need to create a personal scheme under settings >Editor > color and fonts.
Edit:Here this further explanation may help more.
1.In color and fonts choose save as and give a scheme name.
2.Go to console font and change size and primary font, which will be inaccessible if you didn't choose the personal scheme you created earlier.
PyCharm version: Community Edition 4.0.4
Is it possible to customize my color scheme for a python file in PyCharm such that certain statements are of darker color?
e.g. I want to make all statements starting with "logger" to be of gray color so that I can focus on my main code without having to wade through lot of info/debug statements.
I tried to find out if I can add new keyword in keywords1 keywords2 keywords3 keywords4 but can't find any such option. And on top of that, I can't find any way to alter colors for keyword1/2/3/4 individually.
I can't be the only one wanting to hide/dim logging statements!
There is no such feature in PyCharm 4.
I'm using the free version of wingIDE. I am trying to customize individual syntax highlighting colors (comments, strings, constants, normal text, etc). I see the generic color changes for 'background,selected text", etc, but nothing that lets me get down to specifics. Is this a limitation of the free version or is the option hidden deep in the UI? Thanks.
This is now available in the free version 6.0.8-2 (probably one or two releases after yours, PPTim...).
Go to Edit -> Preferences -> Editor -> Syntax Coloring. From here you can alter each type. I use the 'Solarized - Dark' color palette (set this in the User Interface menu, at the very top of the Preferences window) which can make open string highlights difficult to read. In the Syntax Coloring view, this is 'stringeol'. I've altered the background to Black Pearl. For a list of other colour names and descriptions, see the Wing IDE documentation.