Background/Situation
The Structure tool window (View | Tool Windows | Structure) lists the classes, methods, and properties of the file that is open in the editor. For a Python class, many icons in this list can carry a small orange dot. Icons can be purple or red, and some names are gray, for example __init__, __eq__, and __repr__. These marks can look like errors in the project structure.
Question
What do the orange dots, icon colors, and gray names in the PyCharm Structure tool window mean, and how can inherited members be hidden?
Answer
The icons, marks, and colors describe each element and do not report errors in the project.
| What is shown | Meaning |
|---|---|
| Purple icon with the letter "p" | Property, for example __class__ in the built-in object class |
| Red icon with the letter "m" | Method |
| Small orange lock on top of an icon (looks like an orange dot) | The name starts with an underscore, for example _helper, __init__, or __eq__. PyCharm adds the lock to such names, including special methods. |
| Gray name | Member inherited from a parent class. Every Python class inherits the methods of the built-in object class, so names like __init__ and __repr__ appear when inherited members are shown. |
The Common section of the PyCharm 2025.2 Icon reference lists these icons and marks. The same section describes a blue bubble for names that begin and end with two underscores. Methods such as __init__ and __eq__ show the orange lock instead.
To hide inherited members, open the Structure tool window. In PyCharm 2024.2 and later, click View Options in the tool window header. Then click Inherited to turn the option off. In PyCharm 2024.1 and earlier, click Show Inherited on the tool window toolbar.
Structure tool window, File structure popup (PyCharm 2026.2 documentation) describes the other view options.
No option hides only special (dunder) methods while keeping other inherited members. Option to hide magic methods in structure view tracks this feature request.
Comments
0 comments
Please sign in to leave a comment.