Formula book fails to insert power operation

Issue #571 closed
Pol Welter created an issue

In the current version there seems to be a bug when trying to insert a formula with a power operation. Instead of inserting ^, it displays %5e2. Try for example the quadratic equation, or any of the electrical power formulas.

I built SpeedCrunch master (as of Aug 26 2015) using QT 5.4 and MinGW.

Comments (11)

  1. Tey'

    FWIW, this issue seems related to Qt5 builds because it does not appear when built with Qt4.8.7. I can confirm it happens with Qt5.5.0 when built with MinGW, but I don't know if it happens also on Linux.

  2. Tey'

    Can you try the attached patch with Qt5.4 please? I know it fixes this issue for Qt5.5, but I have the feeling it uses a flag which is not defined in previous Qt5 versions.

    Note that this is not a git patch, so git might not like it (but the changes are easy to do manually anyway).

    The cause of the issue is that the QUrl::toString() behaviour has changed since Qt4, and it does not decode some percent-encoded characters now (and the ^ character is encoded that way in the formula book).

  3. Tey'

    Thanks for the confirmation Pol. The QUrl::DecodeReserved flag seems to exist since Qt5.3 at least, so I guess it's okay.

    @HelderCorreia: I'm the assignee but it does not give me any control over this issue, so close it when the PR is accepted please.

  4. Helder Correia repo owner

    @Teyut I just gave you Write permissions, you should be able to modify issues now, I believe.

  5. Log in to comment