blockly > RenderedConnection > getOffsetInBlock
RenderedConnection.getOffsetInBlock() method
Get the offset of this connection relative to the top left of its block.
Signature:
getOffsetInBlock(): Coordinate;
Returns:
Coordinate
The offset of the connection.
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-09-18 UTC.
[null,null,["Last updated 2024-09-18 UTC."],[[["The `getOffsetInBlock()` method calculates the position of a connection point relative to the top-left corner of its containing block."],["It returns a `Coordinate` object representing the offset, providing X and Y coordinates for the connection's location."],["This method is part of the `RenderedConnection` class within Blockly, which deals with visual aspects of block connections."]]],[]]