I've been using term-mode (called by (term)) more frequently lately
to run some shell subprocesses, and something is bothering me.
The problem is that some of these processes have a text UI, and they interact very poorly with Emacs' constantly varying window sizes. Is there a way to set a fixed width/height for the term subprocess? The actual window width doesn't have to be fixed, I just want the shell subprocess to work with constant dimensions.
You can override the definition of term-window-width like so:
(defun term-window-width () 80)
This won't affect the size of the emacs window, but the term process will always think the window is 80 columns wide. You may also want to turn on line truncation in your term-mode-hook:
(add-hook 'term-mode-hook
(lambda () (setq truncate-lines t)))
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With