blockly > IPositionable > getBoundingRectangle
Metoda IPositionable.getBoundingRectangle()
Zwraca prostokąt ograniczający element interfejsu podany w jednostkach pikseli względem elementu div wstrzykiwania Blockly.
Podpis:
getBoundingRectangle(): Rect | null;
Zwroty:
Prostokąt | wartość null
Ramka ograniczająca elementy interfejsu. Wartość „null”, jeśli ramka ograniczająca ma być ignorowana przez inne elementy interfejsu.
O ile nie stwierdzono inaczej, treść tej strony jest objęta licencją Creative Commons – uznanie autorstwa 4.0, a fragmenty kodu są dostępne na licencji Apache 2.0. Szczegółowe informacje na ten temat zawierają zasady dotyczące witryny Google Developers. Java jest zastrzeżonym znakiem towarowym firmy Oracle i jej podmiotów stowarzyszonych.
Ostatnia aktualizacja: 2024-10-11 UTC.
[null,null,["Ostatnia aktualizacja: 2024-10-11 UTC."],[[["The `getBoundingRectangle()` method provides the coordinates and dimensions of an IPositionable element within the Blockly workspace."],["It returns a `Rect` object containing the element's bounding box information or `null` if it should be disregarded by other UI elements."]]],["The `getBoundingRectangle()` method, part of the `IPositionable` interface, calculates and returns the bounding rectangle of a UI element. This rectangle is defined in pixel units relative to the Blockly injection div. The method's return value is either a `Rect` object representing the bounding box or `null` if the bounding box should be ignored. This information allows other UI elements to determine their position.\n"]]