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] new globalFunctions settings #13

Closed
danilort opened this issue Dec 27, 2021 · 0 comments · Fixed by #27
Closed

[Feature] new globalFunctions settings #13

danilort opened this issue Dec 27, 2021 · 0 comments · Fixed by #27
Labels
enhancement New feature or request

Comments

@danilort
Copy link

Qalc 0.1.8

I suggest some add the settings qalc.globalFunctions, to define my functions, constants, units
which can be used globally (in each QALC file).

Example

settings

"qalc.globalFunctions": [
    "circleArea(x) = x^2 * pi",
    "hypotenuse(x,y) = sqrt(x^2 + y^2)",
    "catus(x,y) = sqrt(x^2 - y^2)"
],

myfile.qalc

circleArea(10)
hypotenuse(3, 4)
catus(5, 3)

output

immagine

@danilort danilort changed the title [Feature] new globalFunctions[] settings [Feature] new globalFunctions settings Dec 27, 2021
@nortakales nortakales added the enhancement New feature or request label Feb 17, 2022
luis-c465 added a commit to luis-c465/vs-code-qalc that referenced this issue May 19, 2023
This is a more general solution to the issue of global functions (nortakales#13)
which works near identically, but with the added benefit of
allowing the user to choose global variables as well.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants