Struct layout_2020::display_list::DisplayList
source · pub struct DisplayList {
pub wr: DisplayListBuilder,
pub compositor_info: CompositorDisplayListInfo,
pub spatial_tree_count: u64,
}
Expand description
Where the information that’s used to build display lists is stored. This includes both a wr::DisplayListBuilder for building up WebRender-specific display list information and a CompositorDisplayListInfo used to store information used by the compositor, such as a compositor-side scroll tree.
Fields§
§wr: DisplayListBuilder
The wr::DisplayListBuilder used to collect display list items.
compositor_info: CompositorDisplayListInfo
The information about the WebRender display list that the compositor consumes. This curerntly contains the out-of-band hit testing information data structure that the compositor uses to map hit tests to information about the item hit.
spatial_tree_count: u64
A count of the number of SpatialTree nodes pushed to the WebRender display list. This is merely to ensure that the currently-unused SpatialTreeItemKey produced for every SpatialTree node is unique.
Implementations§
source§impl DisplayList
impl DisplayList
sourcefn get_next_spatial_tree_item_key(&mut self) -> SpatialTreeItemKey
fn get_next_spatial_tree_item_key(&mut self) -> SpatialTreeItemKey
Produce a new SpatialTreeItemKey. This is currently unused by WebRender, but has to be unique to the entire scene.
pub fn build_stacking_context_tree( &mut self, fragment_tree: &FragmentTree, debug: &DebugOptions, ) -> StackingContext
fn push_reference_frame( &mut self, origin: LayoutPoint, parent_scroll_node_id: &ScrollTreeNodeId, transform_style: TransformStyle, transform: PropertyBinding<LayoutTransform>, kind: ReferenceFrameKind, ) -> ScrollTreeNodeId
fn pop_reference_frame(&mut self)
fn define_scroll_frame( &mut self, parent_scroll_node_id: &ScrollTreeNodeId, parent_clip_chain_id: &ClipChainId, external_id: ExternalScrollId, content_rect: LayoutRect, clip_rect: LayoutRect, scroll_sensitivity: ScrollSensitivity, ) -> (ScrollTreeNodeId, ClipChainId)
fn define_sticky_frame( &mut self, parent_scroll_node_id: &ScrollTreeNodeId, frame_rect: LayoutRect, margins: SideOffsets2D<Option<f32>, LayoutPixel>, vertical_offset_bounds: StickyOffsetBounds, horizontal_offset_bounds: StickyOffsetBounds, ) -> ScrollTreeNodeId
source§impl DisplayList
impl DisplayList
sourcepub fn new(
viewport_size: LayoutSize,
content_size: LayoutSize,
pipeline_id: PipelineId,
epoch: Epoch,
root_scroll_sensitivity: ScrollSensitivity,
) -> Self
pub fn new( viewport_size: LayoutSize, content_size: LayoutSize, pipeline_id: PipelineId, epoch: Epoch, root_scroll_sensitivity: ScrollSensitivity, ) -> Self
Create a new DisplayList given the dimensions of the layout and the WebRender pipeline id.
pub fn define_clip_chain<I>( &mut self, parent: ClipChainId, clips: I, ) -> ClipChainId
source§impl DisplayList
impl DisplayList
sourcepub fn build(
&mut self,
context: &LayoutContext<'_>,
fragment_tree: &FragmentTree,
root_stacking_context: &StackingContext,
) -> bool
pub fn build( &mut self, context: &LayoutContext<'_>, fragment_tree: &FragmentTree, root_stacking_context: &StackingContext, ) -> bool
Build the display list, returning true if it was contentful.
Auto Trait Implementations§
impl Freeze for DisplayList
impl RefUnwindSafe for DisplayList
impl Send for DisplayList
impl Sync for DisplayList
impl Unpin for DisplayList
impl UnwindSafe for DisplayList
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more