aboutsummaryrefslogtreecommitdiffstats
path: root/etc/PROBLEMS
diff options
context:
space:
mode:
authorPo Lu2022-11-18 09:08:59 +0800
committerPo Lu2022-11-18 09:09:10 +0800
commit32e29afe64897c2ba821e1c2edc2b7d2eb74e70f (patch)
treee2e1ef06d23f5654c9e435019d4e6e560f8bf2b4 /etc/PROBLEMS
parent682b068ba712075cea34d8bc790620ba82169d6c (diff)
downloademacs-32e29afe64897c2ba821e1c2edc2b7d2eb74e70f.tar.gz
emacs-32e29afe64897c2ba821e1c2edc2b7d2eb74e70f.zip
Add knob to make `mouse-position' faster on X
* etc/PROBLEMS (Improving performance with slow X connections): Add new advice. * src/xterm.c (XTmouse_position): Add alternative implementations for slow connections. (syms_of_xterm): Add new variable to enable them. * src/xterm.h (struct x_display_info): Update commentary.
Diffstat (limited to 'etc/PROBLEMS')
-rw-r--r--etc/PROBLEMS56
1 files changed, 40 insertions, 16 deletions
diff --git a/etc/PROBLEMS b/etc/PROBLEMS
index aaecc41f6e8..2169ed0f80b 100644
--- a/etc/PROBLEMS
+++ b/etc/PROBLEMS
@@ -1640,16 +1640,21 @@ X expects to find it.
1640 1640
1641*** Improving performance with slow X connections. 1641*** Improving performance with slow X connections.
1642 1642
1643There are several ways to improve this performance, any subset of which can 1643There are several ways to improve this performance, any subset of
1644be carried out at the same time: 1644which can be carried out at the same time:
1645 1645
16461) If you don't need X Input Methods (XIM) for entering text in some 16461) Use the "--with-x-toolkit=no" build of Emacs. By not relying on
1647 any toolkit (exhibiting potentially slow behavior), it has been
1648 made very fast over networks exhibiting high latency, but suitable
1649 bandwidth.
1650
16512) If you don't need X Input Methods (XIM) for entering text in some
1647 language you use, you can improve performance on WAN links by using 1652 language you use, you can improve performance on WAN links by using
1648 the X resource useXIM to turn off use of XIM. This does not affect 1653 the X resource useXIM to turn off use of XIM. This does not affect
1649 the use of Emacs's own input methods, which are part of the Leim 1654 the use of Emacs's own input methods, which are part of the Leim
1650 package. 1655 package.
1651 1656
16522) If the connection is very slow, you might also want to consider 16573) If the connection is very slow, you might also want to consider
1653 switching off scroll bars, menu bar, and tool bar. Adding the 1658 switching off scroll bars, menu bar, and tool bar. Adding the
1654 following forms to your .emacs file will accomplish that, but only 1659 following forms to your .emacs file will accomplish that, but only
1655 after the initial frame is displayed: 1660 after the initial frame is displayed:
@@ -1665,26 +1670,45 @@ be carried out at the same time:
1665 Emacs.menuBar: off 1670 Emacs.menuBar: off
1666 Emacs.toolBar: off 1671 Emacs.toolBar: off
1667 1672
16683) Use ssh to forward the X connection, and enable compression on this 16734) Use ssh to forward the X connection, and enable compression on this
1669 forwarded X connection (ssh -XC remotehostname emacs ...). 1674 forwarded X connection (ssh -XC remotehostname emacs ...).
1670 1675
16714) Use lbxproxy on the remote end of the connection. This is an interface 1676 Keep in mind that this does not help with latency problems, only
1672 to the low bandwidth X extension in most modern X servers, which 1677 andwidth ones.
1673 improves performance dramatically, at the slight expense of correctness 1678
1674 of the X protocol. lbxproxy achieves the performance gain by grouping 16795) Use lbxproxy on the remote end of the connection. This is an
1675 several X requests in one TCP packet and sending them off together, 1680 interface to the low bandwidth X extension in some outdated X
1676 instead of requiring a round-trip for each X request in a separate 1681 servers, which improves performance dramatically, at the slight
1677 packet. The switches that seem to work best for emacs are: 1682 expense of correctness of the X protocol. lbxproxy achieves the
1678 -noatomsfile -nowinattr -cheaterrors -cheatevents 1683 performance gain by grouping several X requests in one TCP packet
1679 Note that the -nograbcmap option is known to cause problems. 1684 and sending them off together, instead of requiring a round-trip
1680 For more about lbxproxy, see: 1685 for each X request in a separate packet. The switches that seem to
1686 work best for emacs are: -noatomsfile -nowinattr -cheaterrors
1687 -cheatevents Note that the -nograbcmap option is known to cause
1688 problems. For more about lbxproxy, see:
1681 http://www.x.org/archive/X11R6.8.0/doc/lbxproxy.1.html 1689 http://www.x.org/archive/X11R6.8.0/doc/lbxproxy.1.html
1682 1690
16835) If copying and killing is slow, try to disable the interaction with the 1691 Keep in mind that lbxproxy and the LBX extension are now obsolete.
1692
16936) If copying and killing is slow, try to disable the interaction with the
1684 native system's clipboard by adding these lines to your .emacs file: 1694 native system's clipboard by adding these lines to your .emacs file:
1695
1685 (setq interprogram-cut-function nil) 1696 (setq interprogram-cut-function nil)
1686 (setq interprogram-paste-function nil) 1697 (setq interprogram-paste-function nil)
1687 1698
16997) If selecting text with the mouse is slow, the main culprit is
1700 likely `select-active-regions', coupled with a program monitoring
1701 the clipboard on the X server you are connected to. Try turning
1702 that off.
1703
1704 However, over networks with moderate to high latency, with no
1705 clipboard monitor running, the bottleneck is likely to be
1706 `mouse-position' instead. Set the variable
1707 `x-use-fast-mouse-position' to either any non-nil value, or to the
1708 symbol `really-fast' if that is still too slow. Doing so will also
1709 cause Emacs features that relies on accurate mouse position
1710 reporting to stop working reliably.
1711
1688*** Emacs gives the error, Couldn't find per display information. 1712*** Emacs gives the error, Couldn't find per display information.
1689 1713
1690This can result if the X server runs out of memory because Emacs uses 1714This can result if the X server runs out of memory because Emacs uses