How can I place buttons created by uicontrol() in a relative location, as opposed to absolute location, within a ui window?
It makes no sense to me that a uibuttongroup can be placed in a relative location, but the actual buttons can not. This is a problem when resizing a window.
For example, I can do:
button_group_1 = uibuttongroup('Visible','on','Position',[ 0.4 0 0.4 0.4 ]);button_1 = uicontrol( button_group_1,'Style','radiobutton','String','button_1','Position',[ 10 50 100 50 ]);
But I can not do:
button_group_1 = uibuttongroup('Visible','on','Position',[ 0.4 0 0.4 0.4 ]);button_1 = uicontrol( button_group_1,'Style','radiobutton','String','button_1','Position',[ 0.4 0 0.4 0.4 ]);
Could someone help me implement buttons in a relative position so that a window can be resized and their locations still make sense?
Best Answer