#[allow(clippy::match_same_arms)] // enum/value mapping/dispatch table: one arm per input variant
fn grid_auto_columns_to_taffy(val: LayoutGridAutoColumnsValue) -> Vec<taffy::TrackSizingFunction> {
#[allow(clippy::match_same_arms)] // enum/value mapping/dispatch table: one arm per input variant
#[allow(clippy::cast_possible_truncation, clippy::cast_sign_loss)] // bounded layout/render numeric
fn grid_line_to_taffy(line: &azul_css::props::layout::grid::GridLine) -> GridPlacement<String> {
LayoutAlignSelf::Auto => None, /* Auto means inherit from parent's align-items (for non-abspos; abspos auto computes to itself per spec) */
let (padding_width, padding_height, border_width, border_height, border_left, border_top) =
ContentSizeOrigin::BorderBox => (border_left + padding_width, border_top + padding_height),
#[allow(clippy::match_same_arms)] // enum/value mapping/dispatch table: one arm per input variant
MultiValue::Exact(LayoutOverflow::Auto) => taffy::Overflow::Scroll, /* Auto acts like scroll for layout */
#[allow(clippy::field_reassign_with_default)] // struct built incrementally / test setup; a struct literal is not clearer here
let em_size = crate::solver3::getters::get_element_font_size(styled_dom, id, node_state);
MultiValue::Exact(v) => Some(layout_align_content_to_taffy(CssPropertyValue::Exact(v))),
fn should_suppress_cross_intrinsic(&self, node_idx: usize, style: &Style) -> (bool, bool) {
let text_cache_ptr = core::ptr::from_mut::<crate::font_traits::TextLayoutCache>(text_cache);
fn get_core_container_style(&self, node_id: taffy::NodeId) -> Self::CoreContainerStyle<'_> {
let (parent_border_left, parent_border_top, parent_padding_left, parent_padding_top) = {
let mut result = compute_cached_layout(self, node_id, inputs, |tree, node_id, inputs| {
fn compute_non_flex_layout(&mut self, node_idx: usize, inputs: LayoutInput) -> LayoutOutput {
let (node_padding_width, node_padding_height, node_border_width, node_border_height) = self
fn cache_get(&self, node_id: taffy::NodeId, input: &LayoutInput) -> Option<LayoutOutput> {
fn get_flexbox_child_style(&self, child_node_id: taffy::NodeId) -> Self::FlexboxItemStyle<'_> {
fn get_grid_container_style(&self, node_id: taffy::NodeId) -> Self::GridContainerStyle<'_> {
// enum/value mapping/dispatch table: one arm per input variant (or cross-type bindings that can't
// enum/value mapping/dispatch table: one arm per input variant (or cross-type bindings that can't
#[allow(clippy::match_same_arms)] // enum/value mapping/dispatch table: one arm per input variant