Replies: 3 comments 13 replies
-
I've thought about the grid view for a while, but I never wanted to get into the hassle of scaling it right (especially with three photos). And I thought it might be a pain to position the three images properly as well. If GTK4 has an auto-scaling Picture widget then that'll be great! The only thing is that I'd want to do as little cropping as possible. We've got the thumbnail size from the JSON, so I wonder whether we can do something to rearrange the images to minimise cropping (e.g. put the tall one in the first slot)… but then maybe people put things in a specific order sometimes, so we'd break that and so we might just have to live with cropping. (We already broke the "trivia quiz with images" pattern where people put the answer in the middle and "right" or "wrong" outside the cropped area, but then Twitter is breaking that as well now by showing full images!) |
Beta Was this translation helpful? Give feedback.
-
Is there not an option like CSS
Really? Well, that seems like a really dumb choice! https://developer.twitter.com/en/docs/twitter-api/migrate/data-formats/native-enriched-to-v2
Yep, looks like Twitter made a dumb choice 😒 Maybe the (cropped) thumbnail is a fixed size and we have to make do with their crop? I've not found it in the docs yet, though. |
Beta Was this translation helpful? Give feedback.
-
So, it's now included! It still has some bugs, but I think I am at a point where I leave it for now and revisit the remaining bugs when the rest is done. |
Beta Was this translation helpful? Give feedback.
-
While I was about to implement the image preview, I ran into the design issue on how do we want to display them.
The current Cawbird lines up all images in a row and displays them:
While this works and should be easy to implement (thanks to GTK4 offering an auto-scaling
Gtk.Picture
class), I do think that for more than two the previews become too small.Both the Twitter and the Mastodon client on the other hand are using a grid and display the image in this, which sometimes require cropping:
I personally would tend to use the grid-method, as while it requires some code to crop the images, it scales better for different sizes and should serve the wanted purpose of being a preview:
But wanted to ask for your opinion first, @IBBoard.
Beta Was this translation helpful? Give feedback.
All reactions