Constructor

ConstantProvider

new ConstantProvider()

An object that provides constants for rendering blocks in the sample.

Extends
Blockly.blockRendering.ConstantProvider

Properties

CORNER_RADIUS

unknown

Rounded corner radius.

Inherited from
Blockly.blockRendering.ConstantProvider#CORNER_RADIUS

EMPTY_STATEMENT_INPUT_HEIGHT

constant

unknown

The height of an empty statement input. Note that in the old rendering this varies slightly depending on whether the block has external or inline inputs. In the new rendering this is consistent. It seems unlikely that the old behaviour was intentional.

Inherited from
Blockly.blockRendering.ConstantProvider#EMPTY_STATEMENT_INPUT_HEIGHT

INSIDE_CORNERS

unknown

An object containing sizing and path information about inside corners

Inherited from
Blockly.blockRendering.ConstantProvider#INSIDE_CORNERS

JAGGED_TEETH

unknown

An object containing sizing and path information about collapsed block indicators.

Inherited from
Blockly.blockRendering.ConstantProvider#JAGGED_TEETH

JAGGED_TEETH_HEIGHT

constant

Height of SVG path for jagged teeth at the end of collapsed blocks.

Inherited from
Blockly.blockRendering.ConstantProvider#JAGGED_TEETH_HEIGHT

JAGGED_TEETH_WIDTH

constant

Width of SVG path for jagged teeth at the end of collapsed blocks.

Inherited from
Blockly.blockRendering.ConstantProvider#JAGGED_TEETH_WIDTH

NOTCH

unknown

An object containing sizing and path information about notches.

Inherited from
Blockly.blockRendering.ConstantProvider#NOTCH

OUTSIDE_CORNERS

unknown

An object containing sizing and path information about outside corners.

Inherited from
Blockly.blockRendering.ConstantProvider#OUTSIDE_CORNERS

PUZZLE_TAB

unknown

An object containing sizing and path information about puzzle tabs.

Inherited from
Blockly.blockRendering.ConstantProvider#PUZZLE_TAB

START_HAT

unknown

An object containing sizing and path information about start hats

Inherited from
Blockly.blockRendering.ConstantProvider#START_HAT

Methods

init

package

init()

Initialize shape objects based on the constants set in the constructor.

Inherited from
Blockly.blockRendering.ConstantProvider#init

makeInsideCorners

package

makeInsideCorners() returns Object

Inherited from
Blockly.blockRendering.ConstantProvider#makeInsideCorners
Returns

An object containing sizing and path information about inside corners.

makeJaggedTeeth

package

makeJaggedTeeth() returns Object

Inherited from
Blockly.blockRendering.ConstantProvider#makeJaggedTeeth
Returns

An object containing sizing and path information about collapsed block indicators.

makeNotch

package

makeNotch() returns Object

Inherited from
Blockly.blockRendering.ConstantProvider#makeNotch
Returns

An object containing sizing and path information about notches.

makeOutsideCorners

package

makeOutsideCorners() returns Object

Inherited from
Blockly.blockRendering.ConstantProvider#makeOutsideCorners
Returns

An object containing sizing and path information about outside corners.

makePuzzleTab

package

makePuzzleTab() returns Object

Inherited from
Blockly.blockRendering.ConstantProvider#makePuzzleTab
Returns

An object containing sizing and path information about puzzle tabs.

makeStartHat

package

makeStartHat() returns Object

Inherited from
Blockly.blockRendering.ConstantProvider#makeStartHat
Returns

An object containing sizing and path information about start hats.

shapeFor

package

shapeFor(connection) returns Object

Get an object with connection shape and sizing information based on the type of the connection.

Parameter

connection

The connection to find a shape object for

Value must not be null.

Inherited from
Blockly.blockRendering.ConstantProvider#shapeFor
Returns

The shape object for the connection.