woelper / oculante

A fast and simple image viewer / editor for many operating systems
https://github.com/woelper/oculante
MIT License
824 stars 38 forks source link

Various icons aren't anchored correctly #381

Open Stoppedpuma opened 1 month ago

Stoppedpuma commented 1 month ago

Resizing the window can cause the menu icon to collide with the clear image icon. The icon will also go to the right of the image loading text instead of staying in place if images are loading.

https://github.com/woelper/oculante/assets/58333920/796a4c6e-f8ba-4e40-ae59-186bcf4e7db6

woelper commented 3 weeks ago

What would you expect to happen in this case?

I am inclined to close this as this is an extreme edge case.

Stoppedpuma commented 3 weeks ago

It shouldn't collide but it should hide like the rest of the icons, This also happens with the new icons: image

woelper commented 3 weeks ago

When exactly should it hide? If a certain width is reached?

Since it is aligned to the right, it will move with the window, which can be resized extremely small. I would argue that open/ menu are the most important icons, so maybe the others should not draw below a certain width?

Stoppedpuma commented 3 weeks ago

The current implementation is mostly fine, the problem occurs when the icons collide (folder and menu colliding into next and previous) instead of start to hide like the icons to the left of the compare icon.

https://github.com/woelper/oculante/assets/58333920/c7ff1e40-369e-4dca-97e7-8345fe2c8cbb

When exactly should it hide? If a certain width is reached?

I think the solution you suggested would be fine if implemented "correctly" from a users perspective, correctly meaning not hiding too many icons for the window size or hiding more useful icons instead of less useful ones. Prioritising would be a must here such as open and menu being the most important, next and previous being the second most, etc.

I would argue that open/ menu are the most important icons, so maybe the others should not draw below a certain width?

I agree, you aren't going to be making much use of the edit and details menus at these resolutions.

woelper commented 2 weeks ago

How about this? resize

Stoppedpuma commented 2 weeks ago

That works though I think the order of which Icons disappear should be reversed on the left side (Colour channel disappears first, next and previous last if that makes sense?) since you aren't really going to be making use of those features like details or editing at sizes that small.

woelper commented 2 weeks ago

Not sure if that is possible since the criteria is the x position of the individual widget. I'll take a look if there is something easy to "boost" importance of individual widgets, otherwise I'll leave it as above.

woelper commented 2 weeks ago

Got it, prev/next is now the "dominant" buttons and others hide first.

Stoppedpuma commented 2 weeks ago

One more issue I didn't realise before was RGBA seems to have the same anchoring problem, if it's not a lot of work you should probably figure out the file name being offset as well.

1720369983.webm