Subject: Re: bug#51473: [PATCH] Enable xwidget scrolling optimizations, and other xwidgets improvements

From: Po Lu <[email-masked]>
Date: Sun, 07 Nov 2021 20:03:04 +0800

Eli Zaretskii <[email-masked]> writes:

> The printed representation of xwidget objects should be documented in
> the ELisp manual, under the "Editing Types" section.  In fact, we lack
> a subsection there for xwidgets; it should be added.
>
> Thanks.

Will this work?

>From e90ed4c7d3e92ce6a3fd8d89b450c9b660ff2e08 Mon Sep 17 00:00:00 2001
From: Po Lu <[email-masked]>
Date: Sun, 7 Nov 2021 20:02:06 +0800
Subject: [PATCH] Document the xwidget type

* doc/lispref/elisp.texi: Add Xwidget Type to the menu.
* doc/lispref/objects.texi (Editing Types): Add Xwidget Type to the
menu.
(Xwidget Type): New node.
---
 doc/lispref/elisp.texi   |  1 +
 doc/lispref/objects.texi | 14 ++++++++++++++
 2 files changed, 15 insertions(+)

diff --git a/doc/lispref/elisp.texi b/doc/lispref/elisp.texi
index d0bfd8c901..1c0b0fa1b5 100644
--- a/doc/lispref/elisp.texi
+++ b/doc/lispref/elisp.texi
@@ -365,6 +365,7 @@ Top
 * Keymap Type::             What function a keystroke invokes.
 * Overlay Type::            How an overlay is represented.
 * Font Type::               Fonts for displaying text.
+* Xwidget Type::            Embeddable widgets.
 
 Numbers
 
diff --git a/doc/lispref/objects.texi b/doc/lispref/objects.texi
index 0551bb5673..1c1f463af2 100644
--- a/doc/lispref/objects.texi
+++ b/doc/lispref/objects.texi
@@ -1535,6 +1535,7 @@ Editing Types
 * Keymap Type::         What function a keystroke invokes.
 * Overlay Type::        How an overlay is represented.
 * Font Type::           Fonts for displaying text.
+* Xwidget Type::        Embeddable widgets.
 @end menu
 
 @node Buffer Type
@@ -1860,6 +1861,19 @@ Font Type
 @samp{#<font-entity>} respectively.  @xref{Low-Level Font}, for a
 description of these Lisp objects.
 
+@node Xwidget Type
+@subsection Xwidget Type
+
+  An @dfn{xwidget} is a special display element, such as a web
+browser, that can be embedded inside a buffer.  Each window such an
+xwidget is be displayed in will also have an xwidget view, which on
+X-Windows corresponds to a single X window used to display the widget.
+
+Neither of these objects are readable; their print syntaxes look like
+@samp{#<xwidget>} and @samp{#<xwidget-view>}, respectively.  Lisp
+programmers should not be interested in the functionality of xwidget
+views.  @xref{Xwidgets}, for a more detailed description of xwidgets.
+
 @node Circular Objects
 @section Read Syntax for Circular Objects
 @cindex circular structure, read syntax
-- 
2.31.1