Bug 434812 - Markdown LaTeX rendering issue
Summary: Markdown LaTeX rendering issue
Status: RESOLVED FIXED
Alias: None
Product: cantor
Classification: Applications
Component: general (show other bugs)
Version: 20.12.2
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Cantor Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-03-23 04:10 UTC by Jebin
Modified: 2022-01-09 10:39 UTC (History)
2 users (show)

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


Attachments
Rendered Markdown LaTeX (3.98 KB, image/png)
2021-03-23 04:10 UTC, Jebin
Details
Markdown text (7.55 KB, image/png)
2021-03-23 04:12 UTC, Jebin
Details
rendered output without the fix (19.41 KB, image/png)
2022-01-09 10:38 UTC, Alexander Semke
Details
rendered output with the fix (19.15 KB, image/png)
2022-01-09 10:38 UTC, Alexander Semke
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jebin 2021-03-23 04:10:01 UTC
Created attachment 136966 [details]
Rendered Markdown LaTeX

SUMMARY
The LaTeX inside markdown (both inline and separate line) gets rendered with wide gap between it and previous line.

STEPS TO REPRODUCE
1. Create/load a ipynb file with markdown containing latex.
2. Render the LaTeX.

OBSERVED RESULT
LaTeX rendered with huge wide gaps

EXPECTED RESULT
LaTeX rendered inline or separate line with normal spacing.

SOFTWARE/OS VERSIONS
Operating System: Fedora 33
KDE Plasma Version: 5.20.5
KDE Frameworks Version: 5.79.0
Qt Version: 5.15.2
Kernel Version: 5.10.19-200.fc33.x86_64
OS Type: 64-bit
Comment 1 Jebin 2021-03-23 04:12:18 UTC
Created attachment 136967 [details]
Markdown text

markdown text:

### Net Present Value
- $PV ~=~ \frac{b}{(1+r)^t-1}$
- $b ~=~  {p S\{t\} - k (1+r)^t}$
Comment 2 Alexander Semke 2022-01-09 10:34:16 UTC
Git commit dce028566d4f5b4ea31966cab2afd876b44d1159 by Alexander Semke.
Committed on 09/01/2022 at 10:33.
Pushed by asemke into branch 'master'.

Removed the border and reduced the margins of the LaTeX preview image.
FIXED-IN: 22.03

M  +2    -0    src/mathrendertask.cpp

https://invent.kde.org/education/cantor/commit/dce028566d4f5b4ea31966cab2afd876b44d1159
Comment 3 Alexander Semke 2022-01-09 10:38:14 UTC
Created attachment 145259 [details]
rendered output without the fix
Comment 4 Alexander Semke 2022-01-09 10:38:35 UTC
Created attachment 145260 [details]
rendered output with the fix
Comment 5 Alexander Semke 2022-01-09 10:39:27 UTC
(In reply to Jebin from comment #1)
> Created attachment 136967 [details]
> Markdown text
> 
> markdown text:
> 
> ### Net Present Value
> - $PV ~=~ \frac{b}{(1+r)^t-1}$
> - $b ~=~  {p S\{t\} - k (1+r)^t}$

I did a fix now and I added two screenshots for the comparison. Please check. Thanks for reporting this issue!