2012-03-03 19 views
5

当我从Emacs编译Latex时,如何防止打开* tex-shell *缓冲区?它把窗户分成两半,我总是用C-x 1立即摆脱它。当从Emacs编译Latex时停止打开tex-shell

该解决方案可能与

(setq special-display-buffer-names ("*tex-shell*")) 

这使得新的缓冲区占据整个框架,而不只是一半(不是我想要的)的。

我尝试以下,但它有乳胶无影响:

(defadvice compilation-start 
    (around inhidbit-display (command &optional mode name-function highlight-regexp)) 
    (flet (display-buffer) (fset 'display-buffer 'ignore) ad-do-it)) 
(ad-activate 'compilation-start) 
(ad-deactivate 'compilation-start) 
+0

你使用AUCTeX吗? – 2012-03-04 18:21:09

+0

我不这么认为。该模式是“LaTeX”。实际上,我在OS X上只有这个问题。在Ubuntu上,模式是“LaTeX/P”,tex-shell没有打开。 – zoo 2012-03-04 23:49:03

+0

'C-h m'说你在什么主要模式? – 2012-03-05 15:30:55

回答

1

那么,你真的应该使用AUCTeX因为它是好多了。然而,如果你输入C-hC-k然后一个按键序列Emacs会告诉你什么会运行。在这种情况下,对于C-cC-f,它的tex-file所以你将不得不建议tex-file,或者可能(挖掘一点来源)tex-start-shell

0

我用下面的defun定义:

(defun tex-without-changing-windows() 
    (interactive) 
    (save-buffer) 
    (save-window-excursion (tex-file))) 

我把它绑定到C-c C-f更换tex-file