Skip to content

Conversation

@mhagger
Copy link
Owner

@mhagger mhagger commented Jul 14, 2020

As discussed here, add integers along the top and left edges of diagrams showing the column and row indexes corresponding to the diagram entries, and add the names of the two branch tips at the end of the axes:

       0    5   10  13
       |    |    |  |
   0 - ************** - main
       *............|
       *............|
       *............|
       *............|
   5 - *............|
       *............|
   7 - *------------+
       |
     branch

For the top axis, it can be a little bit awkward to keep the index of the final column from running into the index of the last multiple-of-five column. To solve this, I've:

  • Right-justified most column indexes, but left-justified the last one.

  • Added an extra space and change the tick mark into / if the last column is adjacent to the last multiple-of-five column, like so:

           0    5   10 11
           |    |    | /
       0 - ************ - main
           *??????????|
           *??????????|
           *??????????|
           *??????????|
       5 - *----------+
           |
         branch
    

Fixes: #155

/cc @abitrolly: What do you think of this alternative?

mhagger added 3 commits July 14, 2020 15:02
This lets us modify `Block.write()` more freely.
Show integers corresponding to the row and column indexes of diagrams.
For example,

       0    5   9
       |    |   |
   0 - **********
       *........|
       *...-----+
       *..|#?????
       *..|??????
   5 - *..|??????
   6 - *--+??????
@abitrolly
Copy link
Contributor

It is an improvement over what is available now. Although still inconvenient to my linking, as requires unix-fu to read wide diagrams, and numbers on current frontier is unreadable and need to be visually constructed from the diagram. For #155 I need only two max numbers and direction of branches to understand what is going on. Numbers in between are not as useful. They may help to understand how much is left to rebase, but a separate status block that can be scripted into watchexec command can serve me better. That's my thoughts.

@abitrolly
Copy link
Contributor

@mhagger better merge it. Maybe make it optional if somebody needs to parse the diagram for alternative presentation. But then the --raw format without the axes should omit the legend too.

@mhagger mhagger merged commit e7a8603 into master Jul 16, 2020
@mhagger mhagger deleted the diagram-axes branch July 16, 2020 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

What do the numbers mean during rebase?

3 participants