Fork me on GitHub
#reveal
<
2020-11-05
>
vlaaad21:11:56

Hey there! I just released 1.0.154 with natural structural navigation, please give it a try! I'll update the docs soon... Structural nav is used with Alt+Arrows, and it's "natural" in a sense that you press the arrow of the direction you want the cursor to move, and it jumps by value. Hard to explain, but it's sort of similar to navigating the tables and REBL. Very curious to hear your opinions since I haven't seen such struct nav implementations before

vlaaad21:11:17

I also updated auto-scrolling behavior to use structural information in a way that shows the start of the output instead of always scrolling to the bottom... Should have been 1.1.154 really :D

seancorfield21:11:55

@vlaaad Thanks. Will update right now and let you know how it goes 🙂

đź‘Ť 3
seancorfield22:11:54

Hmm, I don't have home/end keys on my (mac) keyboard. If I'm inside a vector of hash maps and on the { of a map, I would expect alt-down to take me to the { of the next element of the vector, but it takes me a few elements inside it, as if it is navigating a bit too far?

vlaaad22:11:31

hmm, that shouldn't happen... can you share that vector of hashmaps?

seancorfield22:11:12

Not easily, it's a large blob of data from our system at work.

seancorfield22:11:27

If it matters, it uses qualified keywords for all the keys?

vlaaad22:11:42

probably doesn't matter. Can't reproduce it with

[{:a/a 1}
 {:b/b 2}
 {:c/c 2}]

vlaaad22:11:53

regarding missing home/end, I'll think what I can do...

seancorfield22:11:33

Maybe you can bind ctl-alt-left and ctl-alt-right to home/end?

vlaaad22:11:54

it might interfere with some linux distros that use ctrl+alt+arrows to navigate between virtual desktops... that probably will require os-specific keybindings. I think it's inevitable, but I would prefer to do it later..

vlaaad22:11:47

it would be great if you could make a repro for "over-nav" — I tried various big nested vectors of maps to no luck

seancorfield22:11:39

Are you testing on a Mac?

vlaaad22:11:39

I didn't, but I have access to a Mac. I'll try that tomorrow, it's too late here in Europe. Going to sleep now, I'll get back to you later!

seancorfield22:11:30

Here's a small example that seems to have strange behavior:

[[1 2 3]
 [4 5 6]
 [7 8 9]]
With the cursor on the second [ (just before the 1), alt-right puts the cursor on the 3. If I do alt-down instead, the cursor ends up on the [ before the 7 -- skipping the second element of the vector. Is that what you would expect?

vlaaad22:11:18

no, Alt-right should go to 1 and alt+down should go to the [ before 4

vlaaad22:11:16

I remember you mentioning long time ago that fastest way to navigate for you was using alt arrows that scrolls by N rows or something

seancorfield22:11:33

If I'm on the ] after the 3 and do alt-left, I end up on the outer [ rather than then inner [ which is also a bit of a surprise.

vlaaad22:11:46

I remember it because it felt off since Reveal didn't have such a thing.

seancorfield22:11:03

If I'm on that outer [ and do alt-right, I end up on the 2.

vlaaad22:11:49

Maybe on mac Alt+arrow emits repeated key events?

seancorfield22:11:51

If I'm on the 2 and do alt-right, I end up on the 1 (not the 3).

vlaaad22:11:19

well, this is super weird

seancorfield22:11:49

(and alt-right on the 3 takes me to the 1 🙂 )

seancorfield22:11:17

I just confirmed I really am using 1.0.154, and I can see the output tracks (and highlights) the first element of each new result and scrolls as expected.

seancorfield22:11:42

But otherwise, the alt-arrow keys are mostly behaving exactly the same on 1.0.137 and 1.0.154

seancorfield22:11:50

And I just discovered that home is fn-alt-up and end is fn-alt-down -- but that's the same behavior on both 1.0.137 and 1.0.154 so I'm suspecting those are just macOS defaults... and maybe none of your key bindings are actually working on macOS?

seancorfield22:11:12

Anyways, thank you for all you do on Reveal, and we can chat tomorrow.

vlaaad07:11:59

I just tried 1.0.154 on a mac and structural nav worked as expected

vlaaad07:11:19

(on mac, by Alt I mean “Option”: ⌥)

vlaaad08:11:34

btw have you seen these messages? > I remember you mentioning long time ago that fastest way to navigate for you was using alt arrows that scrolls by N rows or something > I remember it because it felt off since Reveal didn’t have such a thing

vlaaad16:11:07

@U04V70XH6 ping :) have you tried structural navigation on a different mac? I couldn't reproduce your problem. What jdk do you use btw?

seancorfield17:11:57

We only have one Mac. I've been using JDK 14 mostly. I'll confirm the JDK and OpenJFX versions when I get to my desk.

vlaaad18:11:35

Fn+Option+Left and Fn+Option+Right worked for me as Alt+Home /`Alt+End` on mac

vlaaad18:11:09

do you still experience brokenness of structural navigation?

vlaaad18:11:15

and Fn+Option+Down / Fn+Option+Up (as well as just Fn+Up/`Fn+Down`) work for me as a textual, not structural, Page Up / Page Down

vlaaad18:11:23

(there is no structural Page Up/Down)

seancorfield19:11:53

@vlaaad Yeah, I figured out the home/end further up in this thread. My current JDK is 15+36 and my OpenJFX is 15-ea+6.

seancorfield19:11:33

I'm on 1.1.159 of Reveal.

seancorfield19:11:27

I did some brief work over the weekend on my Windows laptop and I'm running Reveal there on WSL via VcXsrv and structural navigation seemed more in line with what you described and what I expected.

seancorfield19:11:43

I haven't really dug into it at work today yet.

seancorfield22:11:41

So then I have to go up up left to get back to the { and then alt-down takes me to the same relative element of the next map (the third key)

seancorfield22:11:15

Combined with the auto-scroll to display the start of each printed expr, it's definitely an improvement.

parrot 3