CountPlacementCells
function · ui · primitive
- Address
0x509dd0· 72 bytes, up to0x509e17- Meaning
- Returns the product of two cell counts, each a truncated ratio plus one
- Confidence
- verified, proof one
- Finding
- ui/smartrect#the-placement-search
- Test
ui::glue_509_509dd0_ratio_product
Finding: The placement search in ui: the screen rectangle placement
A rectangle is moved to the first free place a breadth-first search finds, trying four pushes per
candidate in an order chosen by where the rectangle sits on the screen. The search starts from the
rectangle clamped inside the screen. It tries up to ⌊K1/width⌋+1 times ⌊K2/height⌋+1
candidates, takes the oldest first, and answers the first one a push leaves unchanged. If none does,
or the search runs dry, it answers the rectangle it was given.
The derivation is in the doc.
Callers 1
Callees 3
- __ftol crt
- MultiplyByScreenScaleX screencoord
- MultiplyByScreenScaleY screencoord
Calls and jumps by a bare address, from tables/calls.tsv.