GUI screen size keeps changing from where I set it

Hello,
I'm having troubles keep my gui screen size the size I set it in guide. Every time I run the Gui and have it call to other guis then back to the main one, the main one has gotten larger. This also happens to all the other guis i call to. does anyone know how to hard set the size of the gui in guide so that the size i choose is the size it stays?

 採用された回答

Image Analyst
Image Analyst 2013 年 10 月 2 日

1 投票

I do this all the time and that does not happen. What are the units of your main GUI set to? Mine are all set to Normalize. Then let's see the code (for example the push button callback) where you call your second GUI and then return to the main GUI. Third, have you stepped though this line by line in the debugger to see exactly what line of code the resizing is happening on?

3 件のコメント

Jan
Jan 2013 年 10 月 2 日
Exactly. GUIs do not change their size without a reason. So search for the commands, which causes the observed changes.
Alex
Alex 2013 年 10 月 2 日
% --- Executes on button press in DRAW_INLET_CONDITIONS.
function DRAW_INLET_CONDITIONS_Callback(hObject, eventdata, handles)
% hObject handle to DRAW_INLET_CONDITIONS (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
filemenufcn(gcbf,'FileSave')
close all
uiopen('DRAW_INLET_Solution_RECIRC.fig',1);
this is how i'm calling to other guis. there ins't any code in my programs that tells it to change size. i'll try setting units to normalize.
thank you
Alex
Alex 2013 年 10 月 2 日
the problem was the units everything was in. I placed everything where i wanted it to stay. selected all of the parts, set their units to normalized then resized the gui and set the gui units to normalized. now when i call to all my guis they stay the same size. thank you for mentioning units. didn't know that was something you could change.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeEnvironment and Settings についてさらに検索

タグ

質問済み:

2013 年 10 月 2 日

コメント済み:

2013 年 10 月 2 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by