On Thu, Apr 15, 2010 at 04:52:58PM +0200, Pavel Sanda wrote: > Enrico Forestieri wrote: > > However, I think that we need \forward_search_dvi and \forward_search_pdf > > instead of simply \forward_search. > > was thinking about this, but concluded that user uses just one viewer > for such purposes. feel free to change this if you think otherwise.
Hmm... If you add a menu, you should be able to specify either "forward-search dvi" or "forward-search pdf", otherwise, without any argument, forward seach is only possible with dvi. So, I think that both \forward_search_dvi and \forward_search_pdf are needed and a menu should allow to select one or the other (maybe hiding a choice if the corresponding command is not defined). > > Then, there is another issue. Some applications require that the files are > > quoted. However, there is no way to embed a quote in a preference string. > > For example, SumatraPDF performs a forward search when it receives the > > DDE command [ForwardSearch("file.pdf","file.tex",142,0,0,1)], where the > > quotes are essential, but the following line is not correctly parsed: > > > > \forward_search "CMCDDE SUMATRA control > > [ForwardSearch(\"$$o\",\"$$t\",$$n,0,0,1)]" > > > > even escaping the inner quotes. This could be overcome by introducing $$T > > and $$O for having the files automatically quoted like this: > > > > command = subst(command, "$$T", "\\\"" + texname + "\\\""); > > command = subst(command, "$$O", "\\\"" + outname + "\\\""); > > also fine with me if you want to add them. intention was only to give > forward search the starting impetus, any other changes are welcome. Jean-Marc fixed it, so this is not necessary anymore. -- Enrico