need to reorder blocks with a margin on the left side

16 views
Skip to first unread message

MozartPanda

unread,
Nov 23, 2021, 10:14:03 AM11/23/21
to Blockly
Hello blockly community whenever I use the method WorkspaceSvg.CleanUp() it reorders all my blocks which is fine, but with no margin on the left side of my screen/view which looks kinda ugly. Is there a way to fix this easily?

Beka Westberg

unread,
Nov 23, 2021, 2:39:56 PM11/23/21
to blo...@googlegroups.com
Hello!

I think the easiest thing to do is to reimplement the logic found here, but add an offset to the x-coord on this line, to give you the margin on the left.

I hope that helps! If you have any further questions please reply!
--Beka

On Tue, Nov 23, 2021 at 10:14 AM MozartPanda <gregor....@gmail.com> wrote:
Hello blockly community whenever I use the method WorkspaceSvg.CleanUp() it reorders all my blocks which is fine, but with no margin on the left side of my screen/view which looks kinda ugly. Is there a way to fix this easily?

--
You received this message because you are subscribed to the Google Groups "Blockly" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blockly+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/blockly/1399a287-52c6-4c2a-ba82-634b60a48875n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages