all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Alan Third <alan@idiocy.org>
Cc: 30699@debbugs.gnu.org, aaronjensen@gmail.com
Subject: bug#30699: 26.0.91; buffer contents flicker on macOS frames when frames are resized
Date: Thu, 08 Mar 2018 21:15:37 +0200	[thread overview]
Message-ID: <83r2ounzty.fsf@gnu.org> (raw)
In-Reply-To: <20180307202603.GA31176@breton.holly.idiocy.org> (message from Alan Third on Wed, 7 Mar 2018 20:26:03 +0000)

> Date: Wed, 7 Mar 2018 20:26:03 +0000
> From: Alan Third <alan@idiocy.org>
> Cc: 30699@debbugs.gnu.org, aaronjensen@gmail.com
> 
> updateFrameSize in nsterm.m calls SET_FRAME_GARBAGED, which appears to
> just flag the frame for clearing.
> 
> My assumption was that redisplay first checks if the frame is garbaged
> and if so clears it, then redraws the contents of the frame.
> 
> I put the calls to NS(En|Dis)ableScreenUpdates at the start and end of
> redisplay_internal:
> 
> modified   src/xdisp.c
> @@ -13868,7 +13868,7 @@ redisplay_internal (void)
>    redisplaying_p = true;
>    block_buffer_flips ();
>    specbind (Qinhibit_free_realized_faces, Qnil);
> -
> +  ns_disable_screen_updates ();
>    /* Record this function, so it appears on the profiler's backtraces.  */
>    record_in_backtrace (Qredisplay_internal_xC_functionx, 0, 0);
>  
> @@ -14602,7 +14602,7 @@ redisplay_internal (void)
>  #endif
>    if (interrupt_input && interrupts_deferred)
>      request_sigio ();
> -
> +  ns_enable_screen_updates ();
>    unbind_to (count, Qnil);
>    RESUME_POLLING;
>  }
> 
> I realise this isn’t robust, but I was just testing it out.
> 
> I imagine my failure here is that ns_clear_frame isn’t called from
> redisplay at all, but somewhere else.

I believe it is called from clear_frame, which is called by
redraw_frame, which in turn is called by redraw_garbaged_frames.

The call to ns_enable_screen_updates is too late, I think: you must
enable screen updates before redisplay_internal calls update_frame,
because that's where we actually draw stuff on the screen.





  reply	other threads:[~2018-03-08 19:15 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-04 17:38 bug#30699: 26.0.91; buffer contents flicker on macOS frames when frames are resized Aaron Jensen
2018-03-04 20:27 ` Alan Third
2018-03-04 21:34   ` Alan Third
2018-03-05  2:06     ` Aaron Jensen
2018-03-05  3:27       ` Eli Zaretskii
2018-03-05  5:21         ` Aaron Jensen
2018-03-05 16:01           ` Eli Zaretskii
2018-03-05 16:21             ` Aaron Jensen
2018-03-05 18:00               ` Eli Zaretskii
2018-03-05 19:23                 ` Alan Third
2018-03-05 19:53                   ` Eli Zaretskii
2018-03-06 22:55                     ` Alan Third
2018-03-07 17:26                       ` Eli Zaretskii
2018-03-07 20:26                         ` Alan Third
2018-03-08 19:15                           ` Eli Zaretskii [this message]
2018-03-09 12:09                             ` Alan Third
2018-03-09 13:32                               ` Eli Zaretskii
2018-03-09 23:24                                 ` Alan Third
2018-03-10  0:25                                   ` Alan Third
2018-03-10  1:18                                     ` Aaron Jensen
2018-03-10  8:30                                     ` Eli Zaretskii
2018-03-10 23:07                                       ` Alan Third
2018-03-11 16:29                                         ` Eli Zaretskii
2018-03-12  0:46                                           ` Alan Third
2018-03-12 16:39                                             ` Eli Zaretskii
2018-03-12 23:42                                               ` Alan Third
2018-03-13 12:19                                                 ` Alan Third
2018-03-13 16:56                                                   ` Eli Zaretskii
2018-03-13 20:18                                                     ` Alan Third
2018-03-13 15:34                                             ` Aaron Jensen
2018-03-14 15:08                                               ` Alan Third
2018-03-19 15:15                                                 ` Alan Third
2018-03-19 15:27                                                   ` Eli Zaretskii
2018-03-19 17:19                                                     ` Alan Third
2018-03-20 21:50                                                       ` Aaron Jensen
2018-03-20 23:22                                                         ` Aaron Jensen
2018-03-21  6:32                                                         ` Eli Zaretskii
2018-03-21 16:27                                                           ` Aaron Jensen
2018-03-10  8:15                                   ` Eli Zaretskii
2018-03-05  7:55     ` Aaron Jensen
2018-03-05 16:12       ` Eli Zaretskii
2018-03-06 23:00       ` Alan Third
2018-03-07 17:26         ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83r2ounzty.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=30699@debbugs.gnu.org \
    --cc=aaronjensen@gmail.com \
    --cc=alan@idiocy.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.