abrochard / emacs-habitica

Emacs Extension for Habitica
GNU General Public License v3.0
77 stars 23 forks source link

Fixes status screen negative size and rewards all being in the same line. #11

Closed jamiguet closed 6 years ago

jamiguet commented 6 years ago

When in habitica status bar the current value is higher than the maximum the client computes a negative length for the status string resulting in screen not rendering correctly. The situation is possible for the mana status in which then end of task or a spell can assign extra mana which may be removed at cron. It is hence a valid situation for a status in which the current is higher than the maximum.

The current fix resolves this situation. by just taking as max the highest of both values.

jamiguet commented 6 years ago

The second commit fixes the issue in which the rewards are all in the same line. It just appends a \n at the end of each reward entry. This enable reward purchase as the rewards become each an actionable org item

abrochard commented 6 years ago

Looks good. Thanks for your contribution!

jamiguet commented 6 years ago

My pleasure ;-)

-- Juan Amiguet Vercher Practising theorist All-round geek Polyglot polymath

+41(0)774867913

On Sun, Sep 24, 2017 at 5:57 PM, Adrien Brochard notifications@github.com wrote:

Looks good. Thanks for your contribution!

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/abrochard/emacs-habitica/pull/11#issuecomment-331719199, or mute the thread https://github.com/notifications/unsubscribe-auth/ABQNxzE_syHoV0tcpscw6Q_0V86JYRz3ks5slnvxgaJpZM4Ph4iT .