3

I just installed miktex/texmaker and run an example from here http://mally.stanford.edu/~sr/computing/latex-example.html .But the lines that connect the tree don't show up like in the example. How do I fix that? Thanks

\documentclass[12pt]{article}
\usepackage{lingmacros}
\usepackage{tree-dvips}
\begin{document}

\section*{Notes for My Paper}

Don't forget to include examples of topicalization. They look like this:

{\small \enumsentence{Topicalization from sentential subject:\ \shortex{7}{a John$_i$ [a & kltukl & [el & {\bf l-}oltoir & er & ngii$_i$ & a Mary]]} { & {\bf R-}clear & {\sc comp} & {\bf IR}.{\sc 3s}-love & P & him & } {John, (it's) clear that Mary loves (him).}} }

\subsection*{How to handle topicalization}

I'll just assume a tree structure like (\ex{1}).

{\small \enumsentence{Structure of A$'$ Projections:\ [2ex] \begin{tabular}[t]{cccc} & \node{i}{CP}\ [2ex] \node{ii}{Spec} & &\node{iii}{C$'$}\ [2ex] &\node{iv}{C} & & \node{v}{SAgrP} \end{tabular} \nodeconnect{i}{ii} \nodeconnect{i}{iii} \nodeconnect{iii}{iv} \nodeconnect{iii}{v} } }

\subsection*{Mood}

Mood changes when there is a topic, as well as when there is WH-movement. \emph{Irrealis} is the mood when there is a non-subject topic or WH-phrase in Comp. \emph{Realis} is the mood when there is a subject topic or WH-phrase.

\end{document}

The log

LOG FILE :
This is pdfTeX, Version 3.141592653-2.6-1.40.23 (MiKTeX 21.10) (preloaded format=pdflatex 2021.11.4) 4 NOV 2021 18:32
entering extended mode
**./rtbrberbt.tex
(rtbrberbt.tex
LaTeX2e <2021-06-01> patch level 1
L3 programming layer <2021-10-18>
(C:\Users\kosta\AppData\Local\Programs\MiKTeX\tex/latex/base\article.cls
Document Class: article 2021/02/12 v1.4n Standard LaTeX document class
(C:\Users\kosta\AppData\Local\Programs\MiKTeX\tex/latex/base\size12.clo
File: size12.clo 2021/02/12 v1.4n Standard LaTeX file (size option)
)
\c@part=\count182
\c@section=\count183
\c@subsection=\count184
\c@subsubsection=\count185
\c@paragraph=\count186
\c@subparagraph=\count187
\c@figure=\count188
\c@table=\count189
\abovecaptionskip=\skip47
\belowcaptionskip=\skip48
\bibindent=\dimen138
)
(C:\Users\kosta\AppData\Local\Programs\MiKTeX\tex/latex/tree-dvips\lingmacros.s
ty
\c@enums=\count190
\widelabel=\dimen139
\c@tempcnt=\count191
\c@enumsi=\count192
\eeindent=\dimen140
)
(C:\Users\kosta\AppData\Local\Programs\MiKTeX\tex/latex/tree-dvips\tree-dvips.s
ty
tree-dvips version .91 of May 16, 1995
\nodemargin=\dimen141
\treelinewidth=\dimen142
\dashlength=\dimen143
\arrowwidth=\dimen144
\arrowlength=\dimen145
\arrowinset=\dimen146
\pos@t=\toks16
\pos@b=\toks17
\pos@l=\toks18
\pos@r=\toks19
\pos@tl=\toks20
\pos@tr=\toks21
\pos@bl=\toks22
\pos@br=\toks23
\@arrow=\count193
\@tempdimc=\dimen147
)
(C:\Users\kosta\AppData\Local\Programs\MiKTeX\tex/latex/l3backend\l3backend-pdf
tex.def
File: l3backend-pdftex.def 2021-10-18 L3 backend support: PDF output (pdfTeX)
\l__color_backend_stack_int=\count194
\l__pdf_internal_box=\box50
) (rtbrberbt.aux)
\openout1 = `rtbrberbt.aux'.
LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for TS1/cmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 4.
LaTeX Font Info: ... okay on input line 4.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <10.95> on input line 17.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <8> on input line 17.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <6> on input line 17.
[1
Non-PDF special ignored!
<special> header=tree-dvips91.pro
{C:/Users/kosta/AppData/Local/MiKTeX/pdftex/config/pdftex.map}
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
Non-PDF special ignored!
<special> ps:@beginspec/nodemargin 2.0 pt def 0.3 pt setlinewidth [] 0 setd...
] (rtbrberbt.aux) )
Here is how much of TeX's memory you used:
546 strings out of 478907
9282 string characters out of 2851892
306961 words of memory out of 3000000
18488 multiletter control sequences out of 15000+600000
408634 words of font info for 44 fonts, out of 8000000 for 9000
1141 hyphenation exceptions out of 8191
33i,9n,41p,151b,272s stack positions out of 5000i,500n,10000p,200000b,80000s
<C:/Users/kosta/AppData/Local/Programs/MiKTeX/fonts/type1/pu
blic/amsfonts/cm/cmbx10.pfb><C:/Users/kosta/AppData/Local/Programs/MiKTeX/fonts
/type1/public/amsfonts/cm/cmbx12.pfb><C:/Users/kosta/AppData/Local/Programs/MiK
TeX/fonts/type1/public/amsfonts/cm/cmcsc10.pfb><C:/Users/kosta/AppData/Local/Pr
ograms/MiKTeX/fonts/type1/public/amsfonts/cm/cmmi8.pfb><C:/Users/kosta/AppData/
Local/Programs/MiKTeX/fonts/type1/public/amsfonts/cm/cmr10.pfb><C:/Users/kosta/
AppData/Local/Programs/MiKTeX/fonts/type1/public/amsfonts/cm/cmr12.pfb><C:/User
s/kosta/AppData/Local/Programs/MiKTeX/fonts/type1/public/amsfonts/cm/cmsy8.pfb>
<C:/Users/kosta/AppData/Local/Programs/MiKTeX/fonts/type1/public/amsfonts/cm/cm
ti12.pfb>
Output written on rtbrberbt.pdf (1 page, 96221 bytes).
PDF statistics:
46 PDF objects out of 1000 (max. 8388607)
0 named destinations out of 1000 (max. 500000)
1 words of extra memory for PDF output out of 10000 (max. 10000000)
Alan Munn
  • 218,180
  • note that \bf and \sc have not been defined by default and been deprecated since 1994, that may not be the best example of current best practice that you found. – David Carlisle Nov 04 '21 at 15:25
  • this is pstricks so did you use latex. latex dvips, ps2pdf, and not pdflatex when you processed the document? – David Carlisle Nov 04 '21 at 15:26
  • I get this output from latex, latex, dvips, ps2pdf from the code that you post. If you do not get that, show the log file that you get and we should be able to debug. – David Carlisle Nov 04 '21 at 15:29
  • @DavidCarlisle i edited the log,is it correct ? – MechanicX Nov 04 '21 at 16:34
  • @DavidCarlisle im using texmaker and at the run button the default is quick built but i tried a few others ,latex,and its the same pdf without the lines of the tree. – MechanicX Nov 04 '21 at 16:38
  • yes as I guessed you are using pdflatex, you need to use latex with pstricks. (see the first line of the log) – David Carlisle Nov 04 '21 at 16:39
  • @DavidCarlisle how do i change it to pstricks ? i installed a pstricks package from miktex console.You said the example is outdated,so maybe latex is working just fine and ill find some other way for those lines if i need them ? – MechanicX Nov 04 '21 at 16:45
  • you are using pstricks but you need to run latex not pdflatex on the file, I just asked in chat if there are any texmaker users around who can tell you the menu option (I don't use that editor) https://chat.stackexchange.com/transcript/message/59525290#59525290 – David Carlisle Nov 04 '21 at 16:47
  • @DavidCarlisle is the there a better option than textmaker ? i found it on a beginner tutorial – MechanicX Nov 04 '21 at 16:48
  • texmaker seems quite popular. I have used the same editor, emacs, for over 30 years, for all editing not just tex, but I don't necessarily recommend that to a new tex user. – David Carlisle Nov 04 '21 at 16:50
  • @DavidCarlisle i found latex, dvips, ps2pdf in settings,now when i click quick build it works fine the lines show up.Default for quick build was pdflatex. – MechanicX Nov 04 '21 at 16:50
  • yeh!............ – David Carlisle Nov 04 '21 at 16:51
  • @DavidCarlisle ill put a clear solution on the question.Thanks for helping.What do you use instead of textmaker ? – MechanicX Nov 04 '21 at 16:53
  • I posted an answer. As I said I use emacs but it is not a tex-specific editor it is a general coding editor. – David Carlisle Nov 04 '21 at 16:54
  • @DavidCarlisle didnt see it sorry,thanks for the help – MechanicX Nov 04 '21 at 16:56
  • in general please don't put solutions into the question you can post a self-answer. It is much easier for later readers to follow the post if the question/answer structure is preserved – David Carlisle Nov 04 '21 at 17:01
  • @DavidCarlisle fixed it.i just thought there wouldnt be a solution since we solved it in the comments – MechanicX Nov 04 '21 at 17:13
  • Welcome to TeX.se. If you are just beginning to do linguistics in LaTeX, there are much more modern methods for what you're doing, which will serve you much better. I recommend starting here: LaTeX Workshop for Linguists by Adam Liter. – Alan Munn Nov 04 '21 at 19:15

2 Answers2

4

The example is using pstricks package to draw the lines. pstricks requires a PostScript based system so you need to use latex - dvips - ps2pdf to process the document, not pdflatex which is teh default in most editors.

Using that pipeline you should get

David Carlisle
  • 757,742
2

This is not really an answer to the specific question, but the lingmacros package is really old, as is tree-dvips and there are much better methods for dealing with both linguistic examples and trees. Here's how I would do your example code using more up-to-date methods.

See e.g.

For a very good introduction on using LaTeX for linguistics see Adam Liter's handout for a course he gave at the LSA Annual Meeting.

 

\documentclass[12pt]{article}
\usepackage[linguistics]{forest}
\usepackage{gb4e}
\noautomath % turn off use of _ and ^ outside of math mode
\AtBeginEnvironment{exe}{\automath} % turn on use of _ and ^ inside examples
\newcommand*\1{$'$} % command for prime in trees (saves typing)

\begin{document}

\section*{Notes for My Paper}

Don't forget to include examples of topicalization. They look like this:

\begin{exe} \ex{Topicalization from sentential subject:} \sn{\gll John_i [ a kltukl [ el \textbf{l-}oltoir er ngii_i a Mary ]]\ John {} {} \textbf{R-}clear {} \textsc{comp} \textbf{IR}.\textsc{3s}-love P him {} Mary\ \glt John, (it's) clear that Mary loves (him)} \label{subj-topic} \end{exe}

\subsection*{How to handle topicalization}

I'll just assume a tree structure like (\ref{tree}).

\begin{exe} \ex{\begin{forest} [CP [Spec] [C\1 [C] [SAgrP] ]]] \end{forest} } \label{tree} \end{exe} \subsection*{Mood}

Mood changes when there is a topic, as well as when there is WH-movement. \emph{Irrealis} is the mood when there is a non-subject topic or WH-phrase in Comp. \emph{Realis} is the mood when there is a subject topic or WH-phrase. \end{document}

output of code

Alan Munn
  • 218,180