If you press the “Transition & stop” button while the layout is running, then the restart button will not subsequently work. It seems that creating a transition before stopping the layout somehow prevents the layout from being restarted. (Possibly something to do with the fact they both use d3-timer
internally?)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s==x= && s==.er & xac.uc coer= && s==m--+m--+m--+m--=e && | |
s==xac.~o= && s=.+=<<x& evam=ee && | |
eva~ | |
x | |
s=c.=c= && s=x=xz&<<o=e && | |
xm | |
o | |
s=x=x = && s=x=<<xc& <<xo =e&& | |
x~ | |
xc |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
height: 512 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
width: 512 | |
height: 512 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
height: 512 | |
license: gpl-3.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
height: 40 | |
border: no |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
license: gpl-3.0 |
If you press the “Timer & stop” button while the layout is running, then the restart button will not subsequently work. It seems that creating a timer before stopping the layout prevents the layout from being restarted.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def col_index(col): | |
"""Take a spreadsheet-style column specifier, e.g. A, M, ZZ, | |
and convert it to a one-based column index: A=1, Z=26, AA=27, etc. | |
""" | |
if not col or set(col) - set("ABCDEFGHIJKLMNOPQRSTUVWXYZ"): | |
raise Exception("Bad column specifier: '" + col + "'") | |
return reduce(lambda x,c: 26 * x + ord(c) - 64, col, 0) | |
def col_letters(index): | |
"""Take a one-based column index and convert it to a |
Implementing the transition the long way round, using transition.tween
directly.
Click the circle to restart