MathEditor icon indicating copy to clipboard operation
MathEditor copied to clipboard

How can I get result of calculations?

Open iosappsdevelopers opened this issue 5 years ago • 3 comments

For display formulas can use "MTEditableMathLabel" but how can I get it's result ? for example if I enter label.mathList.stringValue 5^{2}, how can I get it's output.. Please help me out with suitable sample if possible. @kostub

iosappsdevelopers avatar Sep 05 '20 10:09 iosappsdevelopers

If you are using Swift, you can do - MTMathListBuilder.mathList(toString: uiView.mathList) where uiView is your MTEditableMathLabel.

Have you been able to prefill the editor with a math formula? I want to have a placeholder to show a formula example but can't seem to figure out how. @kostub

uguess-tamrakar avatar Sep 08 '20 02:09 uguess-tamrakar

Thanks, @uguess-tamrakar . But using this "MTMathListBuilder.mathList(toString: uiView.mathList)" I am not getting result of calculation. Do you know how can I get calculation result of this?

iosappsdevelopers avatar Sep 23 '20 14:09 iosappsdevelopers

Thanks, @uguess-tamrakar . But using this "MTMathListBuilder.mathList(toString: uiView.mathList)" I am not getting result of calculation. Do you know how can I get calculation result of this?

Huh, it seem you can use a AI API like ChatGPT or build math solver your own

lieudd avatar Mar 19 '24 08:03 lieudd