ResizableBorderComponent of DocumentWindow


#1

Is there a way to access the ResizableBorderComponent of the DocumentWindow?
Currently it isn’t possible to call “setBorderThickness” to change the border size of the DocumentWindow, so it’s always 5px.
If it was possible to access the ResizableBorderComponent of the DocumentWindow, you could adjust the border size of an application.
I found no way to achieve this in any other way.


#2

I think you’ll have to subclass it and overide getBorderThickness.


#3

The ResizableBorderComponent is added as a child, simply iterate through the list of children for the DocumentWindow and use dynamic_cast on each one until you find it.


#4

Right. It’s not enough to get access to the resizable frame, because your new choice of thickness would get overwritten every time DocumentWindow::resized() is called. Subclassing is the way to go.


#5

Thanks, you’re right. Subclassing the DocumentWindow was the way to go.