]> git.lyx.org Git - features.git/commitdiff
Fix forward search with okular
authorJuergen Spitzmueller <spitz@lyx.org>
Mon, 27 Aug 2012 06:45:21 +0000 (08:45 +0200)
committerJuergen Spitzmueller <spitz@lyx.org>
Mon, 27 Aug 2012 06:45:21 +0000 (08:45 +0200)
lib/doc/Additional.lyx
lib/doc/de/Additional.lyx
src/frontends/qt4/GuiPrefs.cpp
src/frontends/qt4/GuiView.cpp
status.20x

index 3387f6890dd0d188b116096cec2649b07d2ae982..c894003d3e650db96cb38858bea8695fbb36ebfc 100644 (file)
@@ -7040,7 +7040,21 @@ $$t
 
 \end_inset
 
-: name of the (temporary) exported .tex file
+: name of the (temporary) exported .tex file (without path)
+\end_layout
+
+\begin_layout Itemize
+\noindent
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+$$f
+\end_layout
+
+\end_inset
+
+: name of the (temporary) exported .tex file (including path)
 \end_layout
 
 \begin_layout Itemize
index f07cbbe3a8f01a3aface5e0085e009abc017b56c..c9d29cc2ca3580299e4292d4fc23f7abb45335ea 100644 (file)
@@ -7444,7 +7444,25 @@ $$t
 
 \end_inset
 
-: name of the (temporary) exported .tex file
+: name of the (temporary) exported .tex file (without path)
+\end_layout
+
+\begin_layout Itemize
+\noindent
+
+\lang english
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+
+\lang english
+$$f
+\end_layout
+
+\end_inset
+
+: name of the (temporary) exported .tex file (including path)
 \end_layout
 
 \begin_layout Itemize
index 8038fc13195b8eed49d661a159d104cbb8c537d6..1413ada3bd4aa85be3534bbef74cbae2e14b515c 100644 (file)
@@ -406,13 +406,13 @@ PrefOutput::PrefOutput(GuiPreferences * form)
        dviCB->addItem("");
        dviCB->addItem("xdvi -sourceposition '$$n:\\ $$t' $$o");
        dviCB->addItem("yap -1 -s \"$$n $$t\" $$o");
-       dviCB->addItem("okular --unique \"file:$$o#src:$$n $$t\"");
+       dviCB->addItem("okular --unique \"$$o#src:$$n $$f\"");
        dviCB->addItem("synctex view -i $$n:0:$$t -o $$o -x \"evince -i %{page+1} $$o\"");
        pdfCB->addItem("");
        pdfCB->addItem("CMCDDE SUMATRA control [ForwardSearch(\\\"$$o\\\",\\\"$$t\\\",$$n,0,0,1)]");
        pdfCB->addItem("SumatraPDF -reuse-instance $$o -forward-search $$t $$n");
        pdfCB->addItem("synctex view -i $$n:0:$$t -o $$o -x \"xpdf -raise -remote $$t.tmp $$o %{page+1}\"");
-       pdfCB->addItem("okular --unique \"file:$$o#src:$$n $$t\"");
+       pdfCB->addItem("okular --unique \"$$o#src:$$n $$f\"");
        pdfCB->addItem("synctex view -i $$n:0:$$t -o $$o -x \"evince -i %{page+1} $$o\"");
        pdfCB->addItem("/Applications/Skim.app/Contents/SharedSupport/displayline $$n $$o $$t");
 }
index ac9061f6953a9338e9da424950855e2557922556..bf01917dc0283997095f808711ddd2dc784c0871 100644 (file)
@@ -3538,6 +3538,8 @@ void GuiView::dispatch(FuncRequest const & cmd, DispatchResult & dr)
                                        doc_buffer->absFileName(),
                                                "tex")).mangledFileName()
                                : doc_buffer->latexName();
+                       string const fulltexname = 
+                               support::makeAbsPath(texname, doc_master->temppath()).absFileName();
                        string const mastername =
                                removeExtension(doc_master->latexName());
                        FileName const dviname(addName(path.absFileName(),
@@ -3573,6 +3575,7 @@ void GuiView::dispatch(FuncRequest const & cmd, DispatchResult & dr)
                        string texrow = convert<string>(row);
 
                        command = subst(command, "$$n", texrow);
+                       command = subst(command, "$$f", fulltexname);
                        command = subst(command, "$$t", texname);
                        command = subst(command, "$$o", outname);
 
index 8c492b4b45e49e8ea24abe9284d0c814f6956a44..a60ee00eb5cc95c38cd7900e7860fdf9c42386e1 100644 (file)
@@ -31,7 +31,6 @@ What's new
 - Add explicit dvilualatex output format.
 
 
-
 * TEX2LYX IMPROVEMENTS
 
 - The polyglossia/XeTeX language commands are now supported (bug 8212).
@@ -103,6 +102,10 @@ What's new
 
 - Fix suppression of language package.
 
+- Fix forward search with the Okular viewer. If you were affected by this,
+  please change the forward search command in Preferences > Output to
+  okular --unique "$$o#src:$$n $$f" (as provided now in the dropdown list).
+
 
 * USER INTERFACE