all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* redisplay and expose_frame
@ 2018-07-22 12:44 Alan Third
  2018-07-22 14:37 ` Eli Zaretskii
  2018-07-23  9:58 ` YAMAMOTO Mitsuharu
  0 siblings, 2 replies; 6+ messages in thread
From: Alan Third @ 2018-07-22 12:44 UTC (permalink / raw)
  To: emacs-devel

Hi all,

I’m looking for a little bit of guidance as to how exactly Emacs draws
to a GUI frame.

The background here is that I’m working on splitting the NS port’s GUI
code into its own thread, and while working on that I noticed that
Apple have deprecated the method we use to draw, so I thought that
since I’m working with the code anyway, I may as well try to
‘modernise’ it.

The ‘new’ way of drawing to the screen works thus:

 1. When you want to update a portion of the screen you mark it as
    dirty.

 2. At some point you have to call [emacs-frame display], which does
    some set‐up and then calls drawRect with an argument that is a
    rectangle showing which parts of the screen need to be updated.

 3. *All* the drawing *must* occur in drawRect.

 4. done.

At the moment NS Emacs calls expose_frame from within drawRect which
works well, however it also does some drawing outside of drawRect, and
I strongly suspect that redisplay_internal must, somehow, call
expose_frame (or an equivalent), but I can’t see where.

Does Emacs explicitly draw to the screen as part of redisplay? If so,
where is it doing it?

Thanks!
-- 
Alan Third



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2018-08-04 16:19 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-22 12:44 redisplay and expose_frame Alan Third
2018-07-22 14:37 ` Eli Zaretskii
2018-07-23  9:58 ` YAMAMOTO Mitsuharu
2018-07-24 20:42   ` Alan Third
2018-07-25  9:33     ` YAMAMOTO Mitsuharu
2018-08-04 16:19       ` Alan Third

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.