Bug 262689 - Cannot delete variable
Summary: Cannot delete variable
Status: RESOLVED FIXED
Alias: None
Product: kalgebra
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: LO wishlist
Target Milestone: ---
Assignee: Aleix Pol
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-09 20:05 UTC by Kai Uwe Broulik
Modified: 2013-05-29 00:41 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kai Uwe Broulik 2011-01-09 20:05:08 UTC
Version:           unspecified (using KDE 4.5.95) 
OS:                Linux

You cannot delete a variable. There is no context menu entry for that or anything.

Reproducible: Always
Comment 1 Szczepan Hołyszewski 2013-05-28 18:38:18 UTC
Still unfixed after 2.5 years. Is this program maintained? I learned that KmPlot isn't, so I turned to KAlgebra... and immediately ran into this issue when I tried to do anything non-trivial.
Comment 2 Aleix Pol 2013-05-28 18:40:38 UTC
It's maintained, but it's a wish and a feature that I don't understand why it's necessary and that can break the logic in many ways.

Can you please ellaborate on why you consider it's needed?
Comment 3 Szczepan Hołyszewski 2013-05-28 18:57:20 UTC
... because I decided to add a variable and then changed my mind, or wanted it to be named differently, or decided to take a different approach at designing the function and all the old parameters are no longer needed and just pollute the variable list, or, plainly and simply, I want software to just OBEY. It's a matter of principle: if you can add it, you should be able to remove it, for any value of "it".
Comment 4 Aleix Pol 2013-05-28 19:01:18 UTC
Yes... well but definitions are for defining constants.

If you want parameters, you should be using lambdas, as in:
f:=(x,y,z)->x*y*z
Comment 5 Szczepan Hołyszewski 2013-05-28 19:06:42 UTC
(In reply to comment #4)
> Yes... well but definitions are for defining constants.

That's an "it" too. And how would that break the logic? Let me guess: there is no dependency tracking, so the only safe assumption is that everything is used, right? If that's the case, then I'd say the logic is broken as it is, so there is no further harm (other than an extra try/catch here and there) in telling users they must manage dependencies themselves, warning them that there's no Undo, and allowing them to delete things.
Comment 6 Szczepan Hołyszewski 2013-05-28 19:20:21 UTC
Oh, and functions cannot be deleted either. Is KAlgebra a tool for mathematical geniuses (who don't need it anyway, because they can just close their eyes  and imagine being in a rollercoaster riding on Riemann'z zeta along Re(z)=1/2), or is it a tool for people who do some trial and error? If the latter, how can such a person deal with the accumulation of debris from "errors"? Is there any way other than restarting KAlgebra?
Comment 7 Szczepan Hołyszewski 2013-05-28 20:00:38 UTC
OK, as far as I am concerned, nevermind. Between this and bug 153078... not only can't I delete the functions I defined (this bug), but I cannot actually *use* them in graphs either (that bug). Back to searching for alternatives...
Comment 8 Aleix Pol 2013-05-29 00:41:56 UTC
Git commit 975c02eeb86b5fb243a1e062682c6a17a93c4af4 by Aleix Pol.
Committed on 29/05/2013 at 02:41.
Pushed by apol into branch 'master'.

Make it possible to remove variables

Only in case there's no other variables that depend on this one.

M  +25   -3    src/varedit.cpp
M  +4    -1    src/varedit.h

http://commits.kde.org/kalgebra/975c02eeb86b5fb243a1e062682c6a17a93c4af4