fhackenberger / ktikz

KtikZ provides a nice user interface for making pictures using TikZ.
Other
355 stars 34 forks source link

KtikZ inserts text after EOF #30

Closed genodeftest closed 4 years ago

genodeftest commented 6 years ago

Quite often when saving a tikz file from KtikZ, it inserts text after the end of the document.

Simplified example document, content before opening the document with KtikZ and also how it is being displayed in KTikZ:

\begin{tikzpicture}
    \draw (0, 0) -- (0, 1);
\begin{tikzpicture}

When saving the document using KTikZ, it is modified in a way that starting from some point in the document, any text is written to disk twice. Example file on disk:

\begin{tikzpicture}
    \draw (0, 0) -- (0, 1);
\begin{tikzpicture}
aw (0, 0) -- (0, 1);
\begin{tikzpicture}

I'm using these software versions on Fedora 28: ktikz-0.12-2.fc28.x86_64 qt5-qtbase-5.10.1-6.fc28.x86_64 kf5-kio-core-libs-5.47.0-2.fc28.x86_64 tex-preview-12.1-4.fc28.noarch glibc-2.27-19.fc28.x86_64

jfmcarreira commented 6 years ago

Thanks for the feedback. This happen in the past I thought I fixed it. I think it might be KF5 porting issues.

bonanza123 commented 5 years ago

I can confirm that this bug still exists in v0.12

sdnr commented 5 years ago

I can confirm that this bug still exists in v0.12

Me too

AndreaDiPietro92 commented 5 years ago

I can confirm that this bug still exists in v0.12

Me too

Kubuntu 19.04 Ktikz : 0.12 KDE Frameworks 5.62.0 Qt 5.12.2 (compilato con 5.12.2)

SBasalaev commented 5 years ago

The file simply does not get truncated. If you remove something from the file and save it you can see that its size does not change. If you reopen it then, there will be garbage from the old version after the supposed end of file.

jfmcarreira commented 4 years ago

I merged a PR which might fix this problem. Closing for now.

youcann commented 3 years ago

Since this bug is in release 0.12, are you planning on releasing a new version soon? I have this bug on all my machines running Ubuntu and Manjaro.

jfmcarreira commented 3 years ago

Did you tried to build the "master" branch to see if the problem is solved?

youcann commented 3 years ago

The bug only occurs sporadically in the 0.12 release (most often after i copied and pasted together several pgfplot files). The build of the current master seems to be fine. That's why i would love to see a release based on the current state.