-
Notifications
You must be signed in to change notification settings - Fork 2
Description
It would be helpful to be able to automatically add identifying tags to blocks as the grid of blocks is created. The user would need to specify a starting integer and optional prefix string. The user would also indicate the starting block, direction, and pattern of numbering. An incremental value could be supplied for cases that increment by a value other than 1.
One pattern I would refer to as snaking and would start numbering in any one of four corners with block "n" following in the direction of numbering with "n+1", "n+2", etc. Upon reaching the end of the row (left or right end) or column (top or bottom), the block in the adjacent column or row would be tagged with the next incremental number and numbering of blocks would continue in that row or column in reverse order to the numbering in the first row or column. As an example, if we have a grid 3 x 8 and numbering starts in the bottom right corner traversing an entire row before numbering the second row, (from left to right, top to bottom) the blocks in the first row would be numbered 24 23 22 21 20 19 18 17, the second row 9 10 11 12 13 14 15 16, and the third row would be 8 7 6 5 4 3 2 1.
The alternate pattern when finished tagging the first row (or column) would give the next incremental number to the block adjacent to the FIRST numbered block instead of the last numbered block. Applying this pattern to the same example of a 3 x 8 block with numbering starting in the bottom right corner, the blocks in the first row would be the same, 24 23 22 21 20 19 18 17, the second row would be 16 15 14 13 12 11 10 9, and the third row would be the same, 8 7 6 5 4 3 2 1.
While I have given examples of two patterns of numbering, each of them could start in any of four corners and given a starting corner, head in either of two directions.