forked from AuroraMiddleware/gtk
API: Export gtk_container_snapshot_child()
It's equivalent to gtk_container_propagate_draw() and then one is public, too.
This commit is contained in:
parent
22a657004b
commit
c4065b9ee0
@ -735,6 +735,7 @@ gtk_container_child_notify
|
||||
gtk_container_child_notify_by_pspec
|
||||
gtk_container_forall
|
||||
gtk_container_propagate_draw
|
||||
gtk_container_snapshot_child
|
||||
gtk_container_get_focus_chain
|
||||
gtk_container_set_focus_chain
|
||||
gtk_container_unset_focus_chain
|
||||
|
@ -3269,6 +3269,26 @@ gtk_container_propagate_draw (GtkContainer *container,
|
||||
cairo_restore (cr);
|
||||
}
|
||||
|
||||
/**
|
||||
* gtk_container_snapshot_child:
|
||||
* @container: a #GtkContainer
|
||||
* @child: a child of @container
|
||||
* @snapshot: $GtkSnapshot as passed to the container. In particular, no
|
||||
* calls to gtk_snapshot_translate_2d() should have been applied by the
|
||||
* parent.
|
||||
*
|
||||
* When a container receives a call to the snapshot function, it must send
|
||||
* synthetic #GtkWidget::snapshot calls to all children. This function
|
||||
* provides a convenient way of doing this. A container, when it receives
|
||||
* a call to its #GtkWidget::snapshot function, calls
|
||||
* gtk_container_snapshot_child() once for each child, passing in
|
||||
* the @snapshot the container received.
|
||||
*
|
||||
* gtk_container_snapshot_child() takes care of translating the origin of
|
||||
* @snapshot, and deciding whether the child needs to be snapshot. It is a
|
||||
* convenient and optimized way of getting the same effect as calling
|
||||
* gtk_widget_snapshot() on the child directly.
|
||||
**/
|
||||
void
|
||||
gtk_container_snapshot_child (GtkContainer *container,
|
||||
GtkWidget *child,
|
||||
|
@ -142,6 +142,10 @@ GDK_AVAILABLE_IN_ALL
|
||||
void gtk_container_propagate_draw (GtkContainer *container,
|
||||
GtkWidget *child,
|
||||
cairo_t *cr);
|
||||
GDK_AVAILABLE_IN_3_90
|
||||
void gtk_container_snapshot_child (GtkContainer *container,
|
||||
GtkWidget *child,
|
||||
GtkSnapshot *snapshot);
|
||||
|
||||
GDK_AVAILABLE_IN_ALL
|
||||
void gtk_container_set_focus_chain (GtkContainer *container,
|
||||
|
@ -43,10 +43,6 @@ void _gtk_container_maybe_start_idle_sizer (GtkContainer *container);
|
||||
void gtk_container_get_children_clip (GtkContainer *container,
|
||||
GtkAllocation *out_clip);
|
||||
|
||||
void gtk_container_snapshot_child (GtkContainer *container,
|
||||
GtkWidget *child,
|
||||
GtkSnapshot *snapshot);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GTK_CONTAINER_PRIVATE_H__ */
|
||||
|
@ -45,7 +45,6 @@
|
||||
#include "gtkwidgetpath.h"
|
||||
#include "gtkboxgadgetprivate.h"
|
||||
#include "gtkbuiltiniconprivate.h"
|
||||
#include "gtkcontainerprivate.h"
|
||||
#include "gtkcsscustomgadgetprivate.h"
|
||||
#include "gtkcssstylepropertyprivate.h"
|
||||
#include "gtksizerequest.h"
|
||||
|
Loading…
Reference in New Issue
Block a user