我正在尝试使用 TeXLipse 将 Eclipse 的所有强大功能设置为我的 Latex 编辑器。一切似乎都运行良好(用 SumatraPDF 测试)但 Pdf4Eclipse,我完全想要“边写边更新”的感觉。
到目前为止,我通过询问 Google 得出的结论是:
Pdf4Eclipse 在 Texlipse 中不能被选为 Viewer,它应该被选为 Eclipse 中的默认查看器,通过点击:
窗口 > 首选项:常规 > 编辑器 > 文件关联;选择 *.pdf 并选择 Pdf4Eclipse - 但它不存在。
虽然它已安装,但它在首选项设置中有一个条目。所以问题是:为什么它不在那里,我做错了什么)-:
编辑:错误日志(请注意我的初始学习曲线和最后安装命令的绝望垃圾邮件):
!SESSION 2012-10-08 18:42:10.267 -----------------------------------------------
eclipse.buildId=M20120914-1800
java.version=1.7.0_07
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=de_DE
Command-line arguments: -os win32 -ws win32 -arch x86_64
!ENTRY net.sourceforge.texlipse 4 4 2012-10-08 18:44:59.172
!MESSAGE Could not start previewer 'itexmac'. Please make sure you have entered the correct path and filename in the viewer preferences.
!STACK 0
java.io.IOException: Cannot run program "" (in directory "C:\Users\Felix\workspace\test"): CreateProcess error=2, Das System kann die angegebene Datei nicht finden
at java.lang.ProcessBuilder.start(Unknown Source)
at java.lang.Runtime.exec(Unknown Source)
at net.sourceforge.texlipse.viewer.ViewerManager.execute(ViewerManager.java:555)
at net.sourceforge.texlipse.viewer.ViewerManager.execute(ViewerManager.java:377)
at net.sourceforge.texlipse.viewer.ViewerManager.preview(ViewerManager.java:133)
at net.sourceforge.texlipse.viewer.TexLaunchConfigurationDelegate.launch(TexLaunchConfigurationDelegate.java:68)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:855)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:704)
at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:1047)
at org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1251)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)
Caused by: java.io.IOException: CreateProcess error=2, Das System kann die angegebene Datei nicht finden
at java.lang.ProcessImpl.create(Native Method)
at java.lang.ProcessImpl.<init>(Unknown Source)
at java.lang.ProcessImpl.start(Unknown Source)
... 11 more
!ENTRY net.sourceforge.texlipse 4 4 2012-10-08 18:48:07.453
!MESSAGE Could not start previewer 'itexmac'. Please make sure you have entered the correct path and filename in the viewer preferences.
!STACK 0
java.io.IOException: Cannot run program "" (in directory "C:\Users\Felix\workspace\test"): CreateProcess error=2, Das System kann die angegebene Datei nicht finden
at java.lang.ProcessBuilder.start(Unknown Source)
at java.lang.Runtime.exec(Unknown Source)
at net.sourceforge.texlipse.viewer.ViewerManager.execute(ViewerManager.java:555)
at net.sourceforge.texlipse.viewer.ViewerManager.execute(ViewerManager.java:377)
at net.sourceforge.texlipse.viewer.ViewerManager.preview(ViewerManager.java:133)
at net.sourceforge.texlipse.viewer.TexLaunchConfigurationDelegate.launch(TexLaunchConfigurationDelegate.java:68)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:855)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:704)
at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:1047)
at org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1251)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)
Caused by: java.io.IOException: CreateProcess error=2, Das System kann die angegebene Datei nicht finden
at java.lang.ProcessImpl.create(Native Method)
at java.lang.ProcessImpl.<init>(Unknown Source)
at java.lang.ProcessImpl.start(Unknown Source)
... 11 more
!ENTRY org.eclipse.equinox.p2.operations 4 0 2012-10-08 18:58:11.796
!MESSAGE Operation details
!SUBENTRY 1 org.eclipse.equinox.p2.operations 4 10050 2012-10-08 18:58:11.796
!MESSAGE Cannot complete the request. See the error log for details.
!SUBENTRY 1 org.eclipse.equinox.p2.operations 2 10005 2012-10-08 18:58:11.796
!MESSAGE "PDF4Eclipse" will be ignored because it is already installed.
!ENTRY org.eclipse.equinox.p2.operations 4 0 2012-10-08 18:58:11.799
!MESSAGE Operation details
!SUBENTRY 1 org.eclipse.equinox.p2.operations 4 10050 2012-10-08 18:58:11.799
!MESSAGE Cannot complete the request. See the error log for details.
!SUBENTRY 1 org.eclipse.equinox.p2.operations 2 10005 2012-10-08 18:58:11.799
!MESSAGE "PDF4Eclipse" will be ignored because it is already installed.'
编辑 10.10.2012:
我在 Win XP(而不是 Vista)上使用另一个 Eclipse 版本 3.8 而不是 4.2(两个平台运行时二进制版本)验证了这种行为。启动期间未生成错误日志。也许我应该在 github.org 上提交错误报告?
最佳答案
我有同样的问题(我猜也是一样。我的问题是当我在 texlipse 中双击一个 pdf 文件时,它总是在外部查看器中打开,在我的例子中是 pdf-Xchange),刚刚解决了。这是我的解决方案和对您问题的回答:
在“窗口”>“首选项”:“常规”>“编辑器”>“文件关联”中,对于 *.pdf,“关联编辑器”框架中显示的是“PDF 查看器(默认)”。这实际上是pdf4eclipse。您无需添加任何内容。如果单击“添加”,您将无法添加 pdf4eclipse。
那么问题实际上是您的 texlipse 已经选择了外部 pdf 查看器。现在转到“窗口”>“Texlipse”>“查看器设置”,在“查看器配置”中,我想您会看到一个 pdf 查看器。只需删除它,现在一切都会变得完美。在 texlipse 中双击 pdf 文件将在 pdf4eclipse 中打开它。
如果你有和我一样的问题,那就是它。