mirror of
https://github.com/scratchfoundation/scratch-blocks.git
synced 2025-08-28 22:10:31 -04:00
Adjust separator height for hats
This commit is contained in:
parent
72816a2439
commit
3b2fa0fc73
1 changed files with 10 additions and 0 deletions
|
@ -703,6 +703,16 @@ Blockly.BlockSvg.prototype.renderFields_ =
|
|||
yOffset += Blockly.BlockSvg.GRID_UNIT;
|
||||
}
|
||||
|
||||
// If this is an extension hat block, adjust the height of the vertical
|
||||
// separator without adjusting the field height. The effect is to move
|
||||
// the bottom end of the line up one grid unit.
|
||||
if (this.isScratchExtension &&
|
||||
!this.previousConnection && this.nextConnection &&
|
||||
field instanceof Blockly.FieldVerticalSeparator) {
|
||||
field.setLineHeight(Blockly.BlockSvg.ICON_SEPARATOR_HEIGHT -
|
||||
Blockly.BlockSvg.GRID_UNIT);
|
||||
}
|
||||
|
||||
var translateX, translateY;
|
||||
var scale = '';
|
||||
if (this.RTL) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue