Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Toolbar button to clear the console #22326

Open
jondo opened this issue Aug 6, 2024 · 6 comments
Open

Feature: Toolbar button to clear the console #22326

jondo opened this issue Aug 6, 2024 · 6 comments

Comments

@jondo
Copy link
Contributor

jondo commented Aug 6, 2024

Let me suggest to have a "clear console" button in the IPython Console toolbar.

Reason: ctrl+L is not discoverable, and more work to use when the focus is not there already.

This would be similar to the "broom" button of RStudio:
RStudio-broom

(Filed against Spyder 5.5.4.)

@ccordoba12
Copy link
Member

Hey @jondo, thanks for reporting. I think this is a good idea, but we already have several extra buttons in the IPython console tabbar:

imagen

So, I don't know an extra button makes sense because it'll reduce even more the space for tabs (RStudio doesn't have this problem because it only supports a single console).

What do you think?

@jondo
Copy link
Contributor Author

jondo commented Aug 9, 2024

Hi Carlos! Thank you for considering this. In my personal use case, I rarely have more than four consoles open at a time, which would still fit with the additional button. Otherwise I would simply use the console switcher button at the left, or make the console wider. In addition to that, I always have the variable explorer visible, which also has the "Remove all variables" button, so I do not need it in the console window. Also, for me the buttons could be less far apart.

Of course this is just my personal situation, which could be totally different for someone else. Do you know anything about the distribution of used configurations?

@PhilipYip1988
Copy link

I initially thought that the remove all variables button in the ipython console, was to clear the console as it seems natural to have this button there.

It might be better to group the functionality of the remove all variables button on the variable explorer with the remove all variables on the ipython console. i.e. when the dialog box shows

All user-defined variables will be removed. Are you sure you want to proceed?

to have an option to remove variables from all consoles or a select console.

@ccordoba12
Copy link
Member

ccordoba12 commented Aug 14, 2024

Hi Carlos! Thank you for considering this. In my personal use case, I rarely have more than four consoles open at a time, which would still fit with the additional button. Otherwise I would simply use the console switcher button at the left, or make the console wider. In addition to that, I always have the variable explorer visible, which also has the "Remove all variables" button, so I do not need it in the console window. Also, for me the buttons could be less far apart.

Ok, I think those are good reasons to remove the Remove all variables button and add instead the Clear console one.

I initially thought that the remove all variables button in the ipython console, was to clear the console as it seems natural to have this button there.

Thanks for chiming in @PhilipYip1988. That's a good point too.

when the dialog box shows
to have an option to remove variables from all consoles or a select console.

That's a very interesting suggestion, but it's different from this one. So, could you open a new issue about it? Thanks!

@ccordoba12
Copy link
Member

Note: I'm leaving this for Spyder 6.1 because it requires a change in our UI, so we can't include it in a bugfix release.

@athompson673
Copy link
Contributor

Could I add the suggestion that it also be an entry in the "hamburger menu" / context menu / menubar menu? As a side note, these three menus seem like they each have a random assortment of some or even most, but not all the actions associated with the console. It seems like they should all be the same menu with all the available console actions.

main menubar menu:
image

console text area context menu:
image

console top bar context menu:
image

hamburger menu:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants