Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Force Preview to reload a document' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Force Preview to reload a document
Authored by: paperwings on Jan 05, '06 07:46:40AM

Texshop has its place, but some of us *nix converts still like to do things from the command line. I personally still prefer vim as an editor, as (with some experience, of course) I can do pretty much anything and more with vim that I can with a gui editor. Refreshing Preview would be ideal for using pdflatex or dvipdf. For now, X11+xdvi works well (pressing ^r or just changing the page in xdvi refreshes).



[ Reply to This | # ]
Clarification on TeXShop with external editors
Authored by: Han Solo on Jan 05, '06 08:38:22AM
The command line has its place, but you should try the GUI some time. I know the thought of interacting with the GUI is painful for those of us with Unix backgrounds (been there, done that) but it's, like, a main advantage of the Mac. ;) If you're not a fan of the TeXShop editor itself — which has some nice (La)TeX-specific customizations that do not require a Ph.D. in Comp Sci to install — may I recommend TextMate?

As for gustou's comment, I think the suggestion is to configure TeXShop to be your PDF viewer application. This feature is built into TeXShop: take a look under Preferences. Then one can use Vim or Emacs or any other cool retro 1980s-style editor — or TextMate, BBEdit, etc. for that matter — to "interact" with TeXShop-cum-viewer, and reloading of updated PDF output from (La)TeX works fine... no AppleScript hacks necessary. (Which is not to denigrate this otherwise useful hint.)

[ Reply to This | # ]

Clarification on TeXShop with external editors
Authored by: simonpie on Jan 05, '06 08:53:51AM

I would like to add to this that texshop is a real pdfpreviewer for latex coder whilst preview is not. Texshop offers the magnifying glass on double and tripple click which is a must for anyone who writes mathematics. And texshop does syncronise well with emacs or carbon emacs. Texshop is also much faster than preview, another must for large document and compulsive recompilers like myself.



[ Reply to This | # ]
Except that it does not work...
Authored by: hamarkus on Jan 05, '06 09:44:09AM

TeXShop does not update pdf files that are changed by an external application.

Opening a pdf file from Matlab with TeXShop (via 'system('open -a Texshop filename.pdf')) does not cause TeXShop to update the display. One first has to close the pdf file in TeXShop for any changes to become visible.

I wish I knew the (shell) command to close the file directly from Matlab.



[ Reply to This | # ]
Trying to use the script from Matlab
Authored by: hamarkus on Jan 05, '06 10:03:04AM

Just out of fun, I tried to open a pdf file from Matlab with this script:

system('open Reload_Preview_Document.scpt filename.pdf');

It opens first the script editor and then the pdf file in Acrobat, seconds later both programs collapse.



[ Reply to This | # ]
Except that it does not work...
Authored by: Spartacus on Jan 10, '06 02:18:43PM

And what is pdflatex, if not an external application?



[ Reply to This | # ]
Except that it does not work...
Authored by: ehmsen on Dec 02, '06 06:49:33AM

Try opening the preferences, select the Preview tab and check the box "Automatic Preview Update" under "External Editor" :-)



[ Reply to This | # ]
Clarification on TeXShop with external editors
Authored by: vocaro on Jan 05, '06 06:35:05PM

The command line has its place, but you should try the GUI some time.

The GUI is not sufficient for LaTeX users like myself who rely on fine-tuned Makefiles for their workflow. Mine checks all the dependencies, generates a PDF, and then displays it in one shot. Using the GUI as you suggest would add an unnecessary extra step to this process.



[ Reply to This | # ]