mate-desktop / caja

Caja, the file manager for the MATE desktop
https://mate-desktop.org/
Other
271 stars 145 forks source link

Selecting next file from last column with ⇨ right-arrow key can jump from row 1 to... row 3 or 4 (EDITED) #1039

Open SebastJava opened 6 years ago

SebastJava commented 6 years ago

!!! This is the kind of problem which could make me look like a fool because you try it and it works fine... Only bugs one time out of four... EDITED: I just found out i get this strange behavior only when Caja is set to Icon view, in Compact Layout...

Expected behavior

Open a big folder. Select some file. Select the next one with the ⇨ right arrow. Keep pressing: next, next, next... When the end of the line is reached, i would expect it to select the first file on the next row...

Actual behavior

...But instead of going from, say, last item on row 1 to first item on row 2, it goes to first item on row... 3 or 4 !? Maybe not. Maybe it works fine and keeps moving on row 2... still pressing the ⇨ right-arrow key to select the next file... and the next one again... or just holding down this ⇨ right-arrow key to move much faster... then we are on row 3... then row 4... and then, oops! It jumped to row 7 or 8!

Steps to reproduce the behavior

P.S.: My keyboard is clean, my computer in good shape and i am not on drugs...

That is the only thing i could find to complain. Everything else is super nice, thanks!

Caja version: 1.18.5 sebastien@sebastien-X101CH ~ $ inxi -Fxz System: Host: sebastien-X101CH Kernel: 4.15.0-29-generic i686 (32 bit gcc: 5.4.0) Desktop: MATE 1.18.0 (Gtk 3.18.9-1ubuntu3.3) Distro: Linux Mint 18.3 Sylvia Machine: System: ASUSTeK (portable) product: X101CH v: x.x Mobo: ASUSTeK model: X101CH v: x.xx Bios: American Megatrends v: X101CH.1203 date: 07/30/2012 CPU: Dual core Intel Atom N2600 (-HT-MCP-) cache: 512 KB flags: (nx pae sse sse2 sse3 ssse3) bmips: 6385 clock speeds: max: 1600 MHz 1: 1167 MHz 2: 993 MHz 3: 826 MHz 4: 827 MHz Graphics: Card: Intel Atom Processor D2xxx/N2xxx Integrated Graphics Controller bus-ID: 00:02.0 Display Server: X.Org 1.18.4 drivers: (unloaded: fbdev,vesa) Resolution: 1024x600@60.02hz GLX Renderer: llvmpipe (LLVM 6.0, 128 bits) GLX Version: 3.0 Mesa 18.0.5 Direct Rendering: Yes Audio: Card Intel NM10/ICH7 Family High Definition Audio Controller driver: snd_hda_intel bus-ID: 00:1b.0 Sound: Advanced Linux Sound Architecture v: k4.15.0-29-generic Network: Card-1: Qualcomm Atheros AR9485 Wireless Network Adapter driver: ath9k bus-ID: 02:00.0 IF: wlp2s0 state: up mac: Card-2: Qualcomm Atheros AR8152 v2.0 Fast Ethernet driver: atl1c v: 1.0.1.1-NAPI port: e000 bus-ID: 04:00.0 IF: enp4s0 state: up speed: 100 Mbps duplex: full mac: Drives: HDD Total Size: 352.1GB (21.9% used) ID-1: /dev/sda model: Hitachi_HTS54323 size: 320.1GB ID-2: USB /dev/sdb model: Card_Reader size: 32.1GB Partition: ID-1: / size: 130G used: 55G (45%) fs: ext4 dev: /dev/sda5 ID-2: swap-1 size: 4.29GB used: 0.07GB (2%) fs: swap dev: /dev/sda6 RAID: No RAID devices: /proc/mdstat, md_mod kernel module present Sensors: System Temperatures: cpu: 75.0C mobo: N/A Fan Speeds (in rpm): cpu: 0 Info: Processes: 172 Uptime: 2:22 Memory: 493.1/986.2MB Init: systemd runlevel: 5 Gcc sys: 5.4.0 Client: Shell (bash 4.3.481) inxi: 2.2.35

sc0w commented 6 years ago

caja version?

It works fine here

SebastJava commented 6 years ago

@sc0w Caja version: 1.18.5

SebastJava commented 6 years ago

@sc0w EDITED: I just found out i get this strange behavior only when Caja is set to Icon view, in Compact Layout...

vkareh commented 6 years ago

I can also confirm this. Interestingly, I can reproduce easily in /etc and based on my screenshot, you can see how there is a chunk of those folders that are indented slightly - those all got skipped when moving from the top-right (avahi). Pressing right arrow jumped the selected folder all the way down to gconf (selected in dark green on bottom-left).

screenshot at 2018-08-13 15-15-05

Don't know what causes this issue yet, but my money is on 2 things: the fact that some icons are indented (why?), and the way that traversing the files with the keyboard only focuses on those that are fully to the left when wrapping.

vkareh commented 6 years ago

Okay, based purely on this screenshot, the pattern seems to be that long names extend past the edge of the icons, which means that the position of the icon itself is dictated by a larged block that encompases both the icon along with its name. For a Compact View, I think this should be acceptable, which means that the issue is in keyboard navigation. When wrapping, we need to traverse not only the icon, but the entire block that contains the icon/name.

SebastJava commented 6 years ago

Yes, it goes as @vkareh says, seemingly. I tried with another folder: /usr/share Again, in Icon View + Compact Layout.

Just by looking at it, watching those little indents, i could guess where the focus would jump to. I pressed the ⇨ right-arrow and the focus jumped from row 2 to... row 9! Exactly as i predicted based on what @vkareh says...

Bonus: Then, i tried just the opposite. Going backward with the ⇦ left-arrow key. Still in Compact Layout. Well, it went from row 9 to... 8... then 7, then 6... So everything works fine when using the ⇦ left-arrow key... I confirmed 3 times there is a wrong behavior with the ⇨ right-arrow key, jumping rows when there is some indent.

rcaridade145 commented 6 years ago

This commit https://gitlab.gnome.org/GNOME/nautilus/commit/86d50d906db14ad9256eb26058b9d4fb2e054b35 seems to address this issue.