Resizing plugin not working properly.

I’m stuck trying to get my plugin to resize properly. I’m using my own gui library, and Reaper x64 for testing.

I have a custom View class that inherits from CPluginView, and i have overridden the canResize() and checkSizeConstraint() functions to return true.
When the plugin first starts, Reaper’s window border adjusts to the size of the plugin correctly.
When I attempt to resize the window (from the plugin) using the IPlugFrame’s resizeView(), the plugin scales fine but Reaper’s FX window stays the same size (leaving a white border or clipping the plugin).
I’m able to resize Reaper’s FX window manually, however I have not been able to change it at all from the plugin.

Does anybody have any thoughts on what I might be missing? Thanks for reading!


my synthesizer plug-in ( can resize from 100% to 150% and 200%. I think that this is what you want to achieve as well, right?

I am using Reaper regularly and it seems to work fine here. The Reaper frame adapts to editor size correctly after resizing was initiated from the plug-in side.

The GUI of my plug-in is done with VSTGUI and I used this example as a base:

Maybe this helps a bit to see which sequences need to be done.


Thanks for the info!

I suspect that there is some critical step that VSTGUI handles which I am missing. In the mean time I can just resize via the fx window. I’m afraid I may have to go digging through the VSTGUI source to get to the bottom of this.

Just in case you did not see this yet, here are some sequence diagrams from the SDK: - “Resize View Call Sequences” section.


Now I am finding that modifying the rect that gets passed to checkSizeConstraint() has no effect on the size of the fx window (for example if I try to lock the aspect ratio when dragging to resize). Which is really quite inconvenient. There appears to be a intermediate window that is being resized appropriately (which is the size of my plugin, and on top of reaper’s FX window). However this still leaves the FX window incorrect. (I can provide screenshots) I’m stumped.

I’ve figured it out:

I was calling resizeView() from my (separate) draw thread instead of the window (plugin view) thread. If I call it from the correct thread everything works great!

Remember that everything in the edit controller domain must happen on the main thread also calls to the IComponentHandler instance of the host. So don’t call beginEdit, endEdit or performEdit on a secondary thread.