For a while, I've been using virt-manager to manage my VMs. I like virt-manager - it saves me from a lot of XML wrangling. Just like that, today it helped me sort out an older issue with changing VM screen sizes.
The problem
My VMs run on Linux, so I usually run sudo apt-get install spice-vdagent on the guest VM as part of the setup. This gets clipboard integration and screen resizing working.
After installing the agent, I reboot the guest VM, then enable dynamic screen resizing in virt-manager's menu (View > Scale Display > Auto resize VM with window) and off we go.
This works every time ... most of the time!
With some OS versions, the goodies provided by the Spice Agent still don't kick in. Clipboard isn't shared between the host and the guest VM, and the guest screen doesn't resize - the Auto Resize VM with Window menu item is greyed out.
Hovering over that disabled menu item shows an alt text saying Guest agent is not available. Hmmm, this is odd, I've just installed the agent!
The solution
Eventually, I ran across a Reddit post with instructions for how to connect the host to the agent on the guest. Thanks, u/xleonardox!
Under View > Details, click Add Hardware, select Channel, and use device type Spice agent (spicevmc) and name com.redhat.spice.0 (in my case, both values were defaults). Reboot the guest VM.
Then hit the View menu again - the Auto Resize VM with Window is now available! Enable it.
If you're using Ubuntu's Gnome desktop environment, your VM's screen should be resizing as you need. Congratulations!
(Side note: since the issue has nothing to do with the video driver, the fix doesn't involve messing with the driver or video RAM either.)
Did this work for you? Let me know. Did you run into any issues? Definitely let me know!
Feeling adventurous?
If you're using less mainstram desktops, e.g. MATE, there might be more to do - I'll post the instructions in another post.