Stay organized with collections Save and categorize content based on your preferences.

blockly > blockRendering > TopRow

blockRendering.TopRow class

An object containing information about what elements are in the top row of a block as well as sizing information for the top row. Elements in a top row can consist of corners, hats, spacers, and previous connections. After this constructor is called, the row will contain all non-spacer elements it needs.

Signature:

export declare class TopRow extends Row 

Extends: Row

Remarks

The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the TopRow class.

Properties

Property Modifiers Type Description
ascenderHeight number How much the row extends up above its capline.
connection PreviousConnection | null The previous connection on the block, if any.
hasPreviousConnection boolean Whether the block has a previous connection.

Methods

Method Modifiers Description
endsWithElemSpacer()
hasRightSquareCorner(_block) Returns whether or not the top row has a right square corner.
measure()
startsWithElemSpacer()