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

Minimal calculator function for tofi #183

Open
766F6964 opened this issue Jul 29, 2024 · 1 comment
Open

Minimal calculator function for tofi #183

766F6964 opened this issue Jul 29, 2024 · 1 comment

Comments

@766F6964
Copy link

I would like to suggest adding a minimal calculator function to tofi.

I understand that the main purpouse of tofi is to be a minimal app launcher.
But I believe having an intermediate calculation feature for basic operations would be a very handy addition.

Sometimes, one just wants to quickly sum up 2 or 3 numbers. Of course they could just open a calculator application and type them in, but that would be much slower.
MacOS Finder has a similar feature, I believe?

For instance, typing a query like (4+10)*2 could display the result 28, perhaps highlighted slighlty differently to the right of the query.
I think such a feature wouldn’t detract from tofi's main function as an app launcher.
I think it would make it better. Also, no need to do anything super fancy here, the only basic operations I think that would make sense to support are:

  • Addition +
  • Multiplication *
  • Subtraction -
  • Division /
  • Power **
  • Parenthesis for precedence()

Any calculation more complex than that shouldn't be part of tofi and require launching a dedicated calculator app.
I think it would also make sense to not have this feature by default by hide it behind a cli flag, e.g. --calc, or something like that.

Thoughts?

@machitgarha
Copy link

This is nice to have, but there's already an issue opened for this: #172

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

No branches or pull requests

2 participants