Stay organized with collections
Save and categorize content based on your preferences.
blockly > blockRendering > Drawer > layoutField_
blockRendering.Drawer.layoutField_() method
Push a field or icon's new position to its SVG root.
Signature:
protected layoutField_(fieldInfo: Icon | Field): void;
Parameters
Parameter |
Type |
Description |
fieldInfo |
Icon | Field |
The rendering information for the field or icon. |
Returns:
void
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.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-09-18 UTC."],[[["The `layoutField_` method updates the SVG positioning of a field or icon within a Blockly block."],["It takes a single argument: `fieldInfo`, which contains rendering details for the field or icon being positioned."],["This method is used internally by the Drawer class during block rendering and is not intended for direct use by developers."]]],["The `layoutField_()` method, part of the `blockRendering.Drawer` class, is designed to update the position of a field or icon within its SVG root. It accepts a `fieldInfo` parameter, which can be either an `Icon` or a `Field` object, containing the necessary rendering information. This method then utilizes the `fieldInfo` to adjust the field or icon's position in the SVG. The method does not return any value.\n"]]