blockly > IPositionable > getBoundingRectangle
Methode IPositionable.getBoundingRectangle()
Gibt das Begrenzungsrahmen des UI-Elements in Pixeleinheiten relativ zum Blockly-Injection-Div zurück.
Unterschrift:
getBoundingRectangle(): Rect | null;
Gibt zurück:
Rekt | null
Der Begrenzungsrahmen der UI-Elemente. Null, wenn der Begrenzungsrahmen von anderen UI-Elementen ignoriert werden soll.
Sofern nicht anders angegeben, sind die Inhalte dieser Seite unter der Creative Commons Attribution 4.0 License und Codebeispiele unter der Apache 2.0 License lizenziert. Weitere Informationen finden Sie in den Websiterichtlinien von Google Developers. Java ist eine eingetragene Marke von Oracle und/oder seinen Partnern.
Zuletzt aktualisiert: 2024-10-11 (UTC).
[null,null,["Zuletzt aktualisiert: 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"]]