T-527. JihadPaintLayers returns at once after the first paint when the widget has no invalid region,
no paint task pending and the refresh driver owes no view-manager flush: the layer tree is current
and a paint would only build the display list again (JIHAD_GPU_PAINT_ALWAYS=1 paints every time).
jihad_layout_set_displayport2 schedules a paint of the root scroll frame when the base moved
(SetDisplayPortMargins compares displayports computed with the new base on both sides).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
cavekit-gpu-rendering.md R6 / T-527. nsLayoutUtils::PaintFrame asks the root scroll frame's
DecideScrollableLayer with aAllowCreateDisplayPort, and for the root content document that set the
displayport base to the composition size at the origin, in CSS px, on every paint. So the base the
daemon sets with jihad_layout_set_displayport2 (what the card shows, at the compositor's shift, in
layout device px: patch 0059) never reached a paint: a zoomed-in card's displayport covered only
what the margins and the clamp into the scrollable rect happened to reach. With no margins (the
daemon's first paint after a zoom, what the card shows only) desktop Wikipedia at 2.33 painted 660
of the 531..861 CSS px the card showed and the rest of the view stayed white (frame dumps,
2026-10-25: the painted edge at 1536 screen px, the aligned width of a base 1116 px wide at
resolution 1). On the GPU path, once the daemon has set the root's base
(nsLayoutUtils::JihadKeepsDisplayPortBase: the frame carries the shown size), the paint keeps it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
T-524 (2026-10-24), found with the emulated finger on desktop Wikipedia (laid out 1116x1374, the card's
view 330 CSS px wide at a zoom of 2.33, 531 px from the engine's scroll, which has no sideways range):
1. GetDisplayPortFromMarginsData takes the root's base rect in layout device px: it scales it by the
parent's resolution (1 for the root content document) and divides base + margins by the cumulative
resolution. jihad_layout_set_displayport set the scroll port in CSS px as the base, so at 2.33 the
1116 px base became 479 CSS px and the 165 px margins 71: the displayport ended 550 px from the
engine's scroll, the card's right third was white at 2.33, two thirds at 2.71, all of it from 2.98.
jihad_layout_set_displayport2 takes where the card's view sits (the compositor's shift) and makes
the base what the card shows, at the shift, times the resolution, the margins times the resolution.
The old entry calls it with no shift. The daemon passes the shift and sets the displayport again when
the shift leaves the re-anchor margin or the zoom changes.
2. nsGfxScrollFrame divided the root content document's display-list clip by the resolution. Gecko's
composition size for that root is the widget's device px; the GPU path's (CalculateCompositionSizeForFrame's
Jihad branch) is the scroll port or what the card shows, in CSS px, so the clip became 479 CSS px wide
at 2.33 and a tap on anything beyond it hit only <html> (the infobox's links). The port is the clip on
the GPU path; the overscan rows are CSS px too.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
T-512: the GPU path's [jihad-gpu] diagnostics print only with JIHAD_GPU_LOG=1, or in a device round's
JIHAD_GPU_TIMELINE, JIHAD_GPU_VERIFY or JIHAD_GPU_DUMP_EVERY (one gate, gfx/2d/JihadGpuLog.h, exported
as mozilla/gfx/JihadGpuLog.h); failures and fallbacks print anyway. A daemon on the GPU path now logs
three startup lines from the engine instead of hundreds.
T-517: with JIHAD_GPU_TIMELINE a layer transaction that holds the compositor thread 3 ms or more is
logged with its parts (compositable ops and their tile uploads, layers updated, end), and every compose
job with its uploads: the express lane's frames queue behind the page's transactions.
The GPU path's frame now carries rows above and below what the card shows, so the card has content
to pan into between frames and while the main thread is busy (it showed grey past a view-sized
frame's edges). jihad_layout_set_overscan(docshell, top, bottom) sets them (CSS px) as a frame
property on the root scroll frame; with JIHAD_GPU_COMPOSITOR its clip in BuildDisplayList is widened
by them (over the resolution, as the composition size is).
T-502 (2026-10-18). Without APZ a scroll was a main-thread scroll: every step repainted the
newly exposed strip and re-uploaded the content layer. The daemon now sends the card's scroll
(jihad_offscreen_set_scroll) and AsyncCompositionManager applies it as an async transform on the
layer carrying the root content metrics, the way APZ would, with AlignFixedAndStickyLayers keeping
fixed and sticky layers still. For that, without APZ: root scroll metadata and the scrollport as a
scroll clip for a root scroll frame with a displayport (nsDisplayList, nsGfxScrollFrame), the
displayport set from layout (jihad_layout_set_displayport), and no intermediate surface for a
container under an axis-aligned scale+translate (Layers.cpp).
The Adreno 220 driver bins an FBO render by the current EGL surface's size: a 942-row frame in a
1400-row pbuffer lost its bottom 458 GL rows in some composites. The context's pbuffer is made the
frame's size (GLContextEGL::JihadUsePBufferOfSize) and the window targets with it. Scroll-only
frames (no composite request since the last composite) compose their bands stacked on their own
768x256 pbuffer and FBO, which stays current between band frames (the switch into it costs
11-13 ms); the rows kept are moved while the GPU works; one read takes the stack. A done-fd
(jihad_offscreen_set_done_fd) wakes the daemon the moment a job finishes. Nothing touches a job
after its hand-off.
Adds --disable-npapi as an additional build option. The default is still to build in NPAPI compatibility, but with this flag, it's finally possible to build without pulling in GTK2 on systems that don't have the package.
This essentially ifdefs everything associated with NPAPI, following various Mozilla removal bugs.
Ref: BZ 1682030, BZ 1251202, BZ 1217665, BZ 1687239
Based on selected bits of M-C 1461708:
- EventStateManager::CheckForAndDispatchClick() to early-return style
- split EventStateManager::CheckForAndDispatchClick() into:
EventCausesClickEvents, PostHandleMouseUp, DispatchClickEvents
- Move implementation of UIEvent::GetRangeParent() and UIEvent::RangeOffset() to nsLayoutUtils
ScrollbarStyles contains values of overflow, (over)scroll-behavior, etc.
The only one which is marginally related to scroll _bars_ is overflow, which can
be used to hide scrollbar (by making an element not scrollable) or enforce the
scrollbar to display.
It makes more sense to be called ScrollStyles as it's mainly concerning behavior
of scrolling, not scrollbars. Also, with the addition of scrollbar width
properties, the current name can be confusing.
This is just a clean port of 1322191 and follow-up 1325970. It really seems to add create a new way to access existing code relating to block formatting and floating elements rather than implementing new functionality, and it is mercifully straightforwards.
https://bugzilla.mozilla.org/show_bug.cgi?id=1547792
Aspect Ratio handling simplified by using floating point integers:
- Multiplication of value (or inverse value) to a known side for Scaling
- No unequal equal values such as "4/3" vs "8/6" vs "20/15"
- Truly "Empty" aspect ratios, even if one dimension is not 0
* Add a node property to access the ::before and ::after pseudo-elements
* Look for the frame for ::before and ::after pseudos
* Clean up pseudo-element props
* Simplify nsLayoutUtils callers, and make child iterators notice display: contents pseudos
Tag #1375
Part 1: Remove current table item, as it's never set.
Part 2: Get rid of generic table painting code, and handle each class separately.
Part 4: Hoist outline skipping into col(group) frame code.
Part 5: Skip box-shadow for table column and column groups.
Part 6: Store column and column group backgrounds separately, and then append them before the rest of the table contents.
Part 7: Pass rects in display list coordinates to AppendBackgroundItemsToTop.
Part 8: Create column and column group background display items as part of the cell's BuildDisplayList.
Part 9: Used cached values instead of calling nsDisplayListBuilder::ToReferenceFrame when possible, since it can be expensive when the requested frame isn't the builder's current frame.
Part 10: Make sure we build display items for table parts where only the normal position is visible, since we may need to create background items for ancestors at that position.
Part 11: Create an AutoBuildingDisplayList when we create background items for table columns and column groups, so that we initialize the invalidation state correctly.
List of relevant patches applied:
1398537 part 2 - [css-multicol] Implement percentages for 'column-gap' (Gecko part).
1434478 part 1 - [css-grid] Stop back-computing percentage grid gaps when the percentage basis is indefinite. Treat them as zero sized instead.
1434478 part 2 - Stop back-computing percentage padding/margin when the percentage basis is indefinite. Treat them as zero sized instead.
1434478 part 3 - Remove IntrinsicISizeOffsetData::hPctPadding/hPctMargin members since they are now unused.
1434478 part 4 - Factor out constants like NS_UNCONSTRAINEDSIZE so they can be used in headers without needing nsIFrame.h (idempotent patch).
1434478 part 5 - Create nsLayoutUtils::ResolveToLength for resolving CSS <length-percentage> (idempotent patch).
1434478 part 6 - Propagate a percentage basis to nsIFrame::IntrinsicISizeOffsets for resolving padding/margin.
This is needed only for CSS Grid since in other cases we're only using IntrinsicISizeOffsets in the inline-axis and the percentage basis is always indefinite for *intrinsic sizing*. When calculating the intrinsic size of grid items in the grid container's block axis however, we do have a definite size for the grid area in the inline-axis and it should be used per: https://drafts.csswg.org/css-grid/#algo-overview "2. Next, the track sizing algorithm resolves the sizes of the grid rows, using the grid column sizes calculated in the previous step." (Percentage padding/margin for grid items is always resolved against the grid area's inline-size nowadays.)
This creates a number of stubs and leaves some surrounding code that may be irrelevant (eg. recorded time stamps, status variables).
Stub resolution/removal should be a follow-up to this.