Giter VIP home page Giter VIP logo

Comments (8)

larskotthoff avatar larskotthoff commented on May 21, 2024

Thanks for your report -- when I try to run your code I get

(./gnuplottex/test-gnuplottex-fig1.tex
! Undefined control sequence.
l.82     \definecolor
                 {tbcol}{rgb}{1,1,1}%

How exactly are you compiling this, and what's your TeX installation?

from gnuplottex.

dflvunoooooo avatar dflvunoooooo commented on May 21, 2024

Thank you for your quick answer. I am using texlive with texstudio and compiling with XeLatex and shell escape for gnuplottex on linux. Otherwise there is nothing special.

I don't see, where the error regarding a color is coming from.

Edit: Ah, wait a minute. Even more minimalistic:

\documentclass{scrreport}

\usepackage[siunitx, subfolder]{gnuplottex}

\begin{document}
	
\begin{figure}
	\centering
	\begin{gnuplot}[terminal=cairolatex]
		plot sin(x) title "$\sin(x)$"
	\end{gnuplot}
	\caption{This is a simple example using the cairolatex-terminal.}
	\label{pic:cairolatex}
\end{figure}

\end{document}

from gnuplottex.

larskotthoff avatar larskotthoff commented on May 21, 2024

Ok, it works if I include the xcolor package and exclude the siunitx option, which caused another error. Then everything works fine and the plot is produced.

Are you running this on Linux, Windows, Mac OS?

from gnuplottex.

dflvunoooooo avatar dflvunoooooo commented on May 21, 2024

If I add the xcolor option like this usepackage[xcolor]{gnuplottex}, it raises the error Unknown option "xcolor" for package "gnuplottex". \ProcessOptions\relax. I didn't have an error for siunitx.

I run it under linux. Here is a picture of all three created files.

Screenshot_20231204_110607

from gnuplottex.

larskotthoff avatar larskotthoff commented on May 21, 2024

Ah, ok, I needed to include a space in the file name. I can reproduce the bug.

It looks like the conversion of the figure actually works, just the check whether the file exists fails. There's multiple levels of quoting going on here and I'm not sure how to fix this. For now, I'd recommend to simply not have spaces in your file names.

And xcolor is a separate package, not an option.

from gnuplottex.

dflvunoooooo avatar dflvunoooooo commented on May 21, 2024

xcolor is a package and you mentioned that. I miss read that.

Yes, it is working if no spaces are used in the filename.

Edit: It is working if I rename both files with the "" in the name and remove those. So the problem seems to be, that the filename is not recognised because of the "". Do you know where they are added?

from gnuplottex.

larskotthoff avatar larskotthoff commented on May 21, 2024

The quotes are added automatically by TeX. And yes, the problem is just handling the quoting at different levels in the code.

from gnuplottex.

tobiasBora avatar tobiasBora commented on May 21, 2024

For references, I solved it in my project via this solution in my project https://github.com/leo-colisson/robust-externalize , not sure if you got the same issue: https://tex.stackexchange.com/questions/418670/avoid-quotation-marks-when-using-jobname-or-currfilename

from gnuplottex.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.