Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

This is the code generated by Geogebra, and when I try to compile the code with TeXmaker, using LaTeX, I get a pdf with a small picture. Please, understand that I don't have any knowledge of PSTricks, and I just want to be able to put the pictures I make with Geogebra into LaTeX.

The intent was to draw a quadrangle.

Please, help me fix this code.

\documentclass[10pt]{article}
\usepackage{pstricks-add}
\pagestyle{empty}
\begin{document}
    \newrgbcolor{ffqqtt}{1 0 0.2}
    \psset{xunit=1.0cm,yunit=1.0cm,algebraic=true,dimen=middle,dotstyle=o,dotsize=3pt 0,linewidth=0.8pt,arrowsize=3pt 2,arrowinset=0.25}
    \begin{pspicture*}(-5.89,-1.06)(7.25,5.78)
        \psline[linecolor=ffqqtt](2.04,0.22)(0.75,3.33)
        \psline[linecolor=ffqqtt](-3.26,0.3)(2.69,2.23)
        \psline[linecolor=ffqqtt](0.75,3.33)(2.69,2.23)
        \psline(2.69,2.23)(6.32,0.16)
        \psline[linecolor=ffqqtt](0.75,3.33)(-3.26,0.3)
        \psline[linecolor=ffqqtt](-3.26,0.3)(2.04,0.22)
        \psline[linecolor=ffqqtt](2.04,0.22)(2.69,2.23)
        \psline(3.8,5.64)(0.75,3.33)
        \psline(3.8,5.64)(2.69,2.23)
        \psline(2.04,0.22)(6.32,0.16)
        \begin{scriptsize}
            \psdots[dotstyle=*,linecolor=blue](3.8,5.64)
            \rput[bl](3.87,5.57){\blue{$D$}}
            \psdots[dotstyle=*,linecolor=red](-3.26,0.3)
            \rput[bl](-3.56,0.5){\red{$A$}}
            \psdots[dotstyle=*,linecolor=blue](6.32,0.16)
            \rput[bl](6.19,-0.16){\blue{$B$}}
            \psdots[dotstyle=*,linecolor=red](0.75,3.33)
            \rput[bl](0.54,3.44){\red{$C$}}
            \psdots[dotstyle=*,linecolor=red](2.04,0.22)
            \rput[bl](1.94,-0.21){\red{$E$}}
            \psdots[dotstyle=*,linecolor=red](2.69,2.23)
            \rput[bl](3.13,2.21){\red{$F$}}
        \end{scriptsize}
    \end{pspicture*}
\end{document}
share|improve this question
    
1493 characters are used. –  Oh my ghost Feb 22 at 12:27
    
@TheLastError I don't understand 1493 characters used? –  MaoYiyi Feb 22 at 13:07

3 Answers 3

Without using Geogebra that generates inefficient PSTricks code.

\documentclass[pstricks,border=25pt,12pt]{standalone}
\usepackage{pst-eucl}
\psset{PointSymbol=none,linejoin=2}
\begin{document}
\begin{pspicture}(8,5)
    \pstGeonode[PosAngle={180,0,135,45,-90}]{A}(8,0){B}(3,3){C}([nodesep=6]{C}A){D}([nodesep=5]{B}A){E}
    \pstInterLL[PosAngle=45]{E}{D}{C}{B}{F}
    \psline(C)(D)(F)(B)(E)\psline[linecolor=red](A)(E)(F)(C)(A)(F)(E)(C)
\end{pspicture}
\end{document}

enter image description here

share|improve this answer
    
403 characters are used. –  Oh my ghost Feb 22 at 12:27
    
It is hard for me to think of the projections I need for class, without having something to draw them with, as I would like to be able to just code the answers, I am not that smart. –  MaoYiyi Feb 22 at 13:09

Maybe it won't be big enough to suit your needs, but if you remove the lines

\begin{scriptsize}

and

\end{scriptsize}

you will obtain bigger letters. Either way, it compiles here without problems and indeed I obtain a normal-sized quadrangle.

enter image description here

share|improve this answer
    
What I get is as if everything was stacked upon itself in one small 1mm X 1mm cube. I am using texmaker. I click the latex option to build and then click view pdf. –  MaoYiyi Feb 22 at 7:52
    
It works fine here with texmaker too. What happens if you try to compile and view by the quickest way (press F1)? –  fpast Feb 22 at 8:15

run that document with xelatex or configure TeXmaker to use the sequencelatex->dvips->ps2pdf when you use quickbuild, which can be set via Options->Configure TeXmaker->Quick Build`. In the right menu choose the latex/dvips/ps2pdf sequence

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.