Well, I would say I do it manually in the editing.
To avoid confusion with some things @David and @John78 were just talking about, you can manually zoom an scroll in a video window while you are capturing the footage and thereby create such effects. I did something like that when I started out, but that’s not how I’m doing it now.
These days I always capture the full screen VHTV footage and then do all the formatting later in the editing. When you have learned how to do that in your video editing software it is just so much more effective, precise and easier, that the “manual manual” way is really not an option anymore.
With a GIF I fisrt review the recorded footage to find a moment that I think might make a good GIF and decide in what aspect ratio I want to frame that. For Shotcut I’ve made templates in aspect ratios 5:2, 16:9, 4:3, 1:1, 3:4, 9:16 and 2:5. So in the case of the Rollie GIF above I imported the recorded footage into my 3:4 aspect ratio template, meaning the GIF could be, for example 300 pixels wide and 400 pixels high. This one is 450x600.
Then in this 3:4 project I can cut the clip and zoom it however I want it to fill that 3:4 “window”. And when I use so-called key frames I can go to any moment in the clip, and define how I want it to be zoomed in at that moment. I can also define if I want the “camera movement” between these key frames to be a linear, or smooth or pseudo-handheld motion. For a GIF such as this I’ll just define some of these key frames, watch a preview, make some adjustments, watch a preview again and so on.
In Shotcut there’s also an option to do automatic object tracking, and I’ve played around with that, but to get that to work the way you want it to may take much more time than just doing it manually. At least for the VHTV stuff that I’ve been doing. If you want to stabilize some shaky handheld footage that might be another thing.
It is all a bit more complicated than what I explained here, but that’s the general gist of it. And if anybody needs specific help with how to do this in Shotcut, I can be of assistance.