summaryrefslogtreecommitdiff
path: root/src/window.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/window.c')
-rw-r--r--src/window.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/window.c b/src/window.c
index afb8f75537b..c8fcb3a607f 100644
--- a/src/window.c
+++ b/src/window.c
@@ -6575,9 +6575,12 @@ and redisplay normally--don't erase and redraw the frame. */)
in case scroll_margin is buffer-local. */
this_scroll_margin = window_scroll_margin (w, MARGIN_IN_LINES);
- /* Don't use redisplay code for initial frames, as the necessary
- data structures might not be set up yet then. */
- if (!FRAME_INITIAL_P (XFRAME (w->frame)))
+ /* Don't use the display code for initial frames, as the necessary
+ data structures might not be set up yet then. Also don't use it
+ for buffers with very long lines, as it tremdously slows down
+ redisplay, especially when lines are truncated. */
+ if (!FRAME_INITIAL_P (XFRAME (w->frame))
+ && !current_buffer->long_line_optimizations_p)
{
specpdl_ref count = SPECPDL_INDEX ();