Skip to main content

Crate kozan_core

Crate kozan_core 

Source
Expand description

kozan-core — Core DOM engine for Kozan.

§Module structure (mirrors Chrome)

  • dom — DOM types: Node, EventTarget, Element, Handle, Document, Text
  • events — Event system: Event, dispatch, listeners, path
  • html — HTML elements: HtmlElement, HtmlDivElement, HtmlButtonElement

Re-exports§

pub use styling::values;
pub use dom::traits::ContainerNode;
pub use dom::traits::Element;
pub use dom::traits::HasHandle;
pub use dom::traits::Node;
pub use events::EventTarget;
pub use html::HtmlElement;
pub use html::MediaElement;
pub use html::FormControlElement;
pub use html::TextControlElement;
pub use html::IntrinsicSizing;
pub use html::ReplacedElement;
pub use dom::attribute::Attribute;
pub use dom::attribute::AttributeCollection;
pub use dom::document::Document;
pub use dom::element_data::ElementData;
pub use dom::handle::Handle;
pub use dom::node::NodeFlags;
pub use dom::node::NodeType;
pub use dom::text::Text;
pub use dom::text::TextData;
pub use html::HtmlAudioElement;
pub use html::HtmlBodyElement;
pub use html::HtmlDivElement;
pub use html::HtmlParagraphElement;
pub use html::HtmlSpanElement;
pub use html::AnchorData;
pub use html::HtmlAnchorElement;
pub use html::ButtonData;
pub use html::HtmlButtonElement;
pub use html::CanvasData;
pub use html::HtmlCanvasElement;
pub use html::FormData;
pub use html::HtmlFormElement;
pub use html::HeadingData;
pub use html::HtmlHeadingElement;
pub use html::HtmlImageElement;
pub use html::ImageData;
pub use html::HtmlInputElement;
pub use html::InputData;
pub use html::InputType;
pub use html::HtmlLabelElement;
pub use html::LabelData;
pub use html::HtmlSelectElement;
pub use html::SelectData;
pub use html::HtmlTextAreaElement;
pub use html::TextAreaData;
pub use html::HtmlVideoElement;
pub use html::VideoData;
pub use events::Event;
pub use events::EventContext;
pub use events::ListenerId;
pub use events::ListenerOptions;
pub use events::BlurEvent;
pub use events::ClickEvent;
pub use events::ContextMenuEvent;
pub use events::DblClickEvent;
pub use events::FocusEvent;
pub use events::FocusInEvent;
pub use events::FocusOutEvent;
pub use events::KeyDownEvent;
pub use events::KeyUpEvent;
pub use events::MouseDownEvent;
pub use events::MouseOutEvent;
pub use events::MouseOverEvent;
pub use events::MouseUpEvent;
pub use events::ResizeEvent;
pub use events::ScrollEvent;
pub use events::mouse_event::MouseEnterEvent;
pub use events::mouse_event::MouseLeaveEvent;
pub use events::mouse_event::MouseMoveEvent;
pub use events::wheel_event::WheelEvent;
pub use input::ButtonState;
pub use input::InputEvent;
pub use input::KeyCode;
pub use input::Modifiers;
pub use input::MouseButton;

Modules§

compositor
Compositor — GPU-thread owner of the layer tree and scroll state.
dom
DOM types — like Chrome’s core/dom/.
events
Event system — Chrome’s event architecture adapted for Rust.
html
HTML element types — like Chrome’s core/html/.
input
Input event types — the engine’s public input API.
layout
Layout engine — computes size and position for every element.
lifecycle
Document lifecycle — state machine enforcing phase ordering.
paint
Paint system — converts the fragment tree into draw commands.
scroll
Scroll system — independent subsystems mirroring Chrome’s cc/ architecture.
style_structs
Property struct groups — access computed values by category. Usage: computed_values.get_box().clone_display() The module where all the style structs are defined.
styling
Styling system — powered by Mozilla’s Stylo CSS engine.
widget
Widget — the engine’s top-level entry point for rendering contexts.

Structs§

Arc
Arc wrapper used by Stylo. An atomically reference counted shared pointer
ComputedValues
Computed style values for an element. All CSS properties accessible via property struct getters (e.g. cv.get_box().clone_display()). The struct that Servo uses to represent computed values.
PropertyDeclarationBlock
A parsed CSS declaration block (inline styles, stylesheet rules). Overridden declarations are skipped.
RawId
A raw generational identifier. 8 bytes, Copy, Send + Sync.

Derive Macros§

DeriveElement
Derive Node, ContainerNode, and Element traits for an element type.
DeriveEvent
Generate getters and setters on an element type from its data struct.
DeriveNode
Derive the Node trait for a newtype wrapper around Handle.
Props