1<?xml version="1.0" encoding="utf-8"?>
2<page xmlns="http://projectmallard.org/1.0/" type="topic" style="task" id="synctex-search" xml:lang="wa">
3
4  <info>
5    <link type="guide" xref="index#synctex" group="fifth"/>
6    <desc>Flip between Atril and <app>pluma</app>.</desc>
7    <revision pkgversion="1.25" version="0.1" date="2021-03-13" status="final"/>
8    <credit type="author">
9      <name>Tiffany Antopolski</name>
10      <email>tiffany@antopolski.com</email>
11    </credit>
12    <license>
13      <p>Creative Commons Share Alike 3.0</p>
14    </license>
15
16  </info>
17
18<title>Search with SyncTeX</title>
19<p>
20   After you <link xref="synctex-compile">compile your TeX file with SyncTeX</link>, you will be able to search.  SyncTeX even supports forward and backward search from an included file.
21</p>
22
23<section id="forward-search">
24    <title>Forward search: from TeX to PDF (from <app>pluma</app> to Atril)</title>
25     <p>
26     Forward search allows you to click on a specific section of TeX source code, and jump to the associated position in the PDF.  To perform forward search:
27 </p>
28<steps>
29<item>
30<p>
31  Click on a line in the TeX file.
32</p>
33</item>
34<item>
35<p>
36  In <app>pluma</app>, click <guiseq><gui>Tools</gui> <gui>Forward Search</gui></guiseq>. The corresponding line in the PDF will be outlined in red.
37</p>
38<p>
39Alternatively, you can press <keyseq><key>Ctrl</key><key>Alt</key><key>F</key></keyseq>, or <keyseq><key>Ctrl</key>left click</keyseq>. The corresponding line in the PDF will be outlined in red.
40</p>
41</item>
42</steps>
43<note>
44<p>
45   If the corresponding PDF file is not open, performing a forward search will open the PDF in Atril.
46</p>
47</note>
48<p>
49 If you have a complex project with several TeX files you can put
50</p>
51<code>% mainfile: mainfile.tex</code>
52<p>
53either in the first or last three lines of each included TeX file, and forward search will work. Backward search should always work, even if you don't add the modeline.
54</p>
55
56</section>
57
58<section id="backward-search">
59    <title>Backward search: from PDF to TeX (from Atril to <app>pluma</app>)</title>
60     <p>
61 Backward search allows you to click on a specific line in the PDF file, and jump to the associated line in the TeX source code.
62</p>
63<p>
64You can perform a backward search by pressing <keyseq><key>Ctrl</key>left click</keyseq> in Atril. The corresponding line in the TeX source code will be highlighted.
65     </p>
66</section>
67
68</page>
69