Problem with uipanel GUi matlab
6 次查看(过去 30 天)
显示 更早的评论
Hi there !
I am a problem which is starting to get on my nerve but can't find a solution. I created a GUI that works perfectly. ~ When I process it, I have a panel that shows at the button ( not entirely on the window, just the top of it). When I go into my GUI figure, it's not there.
So basically I have a " phantom panel" which I would like to delete, but does not appear in my GUI Figure.
Is there a command to list all panels created in the GUI figure, or something similar to this?
Thanks
2 个评论
David Sanchez
2014-2-26
Depending on how yo created your GUI you can see the handles of the objects in it. Could you attach the *.fig and *.m file of your GUI? I could take a look
采纳的回答
David Sanchez
2014-2-26
That "panel" string is associated with the bottom left panel called "Change of values". Delete it and rebuilt it again. Besides that, as I mentioned in the comment above, the whole GUI seems to have several hidden object under visible objects. That's why the images you presented above do not match (see for example the 4 push buttons in the main panel of the GUIDE in contrast with the 5 in the interface, all with no matching names). Depending on the hierarchy set when building the GUI, some objects are visible when the gui is run instead of those visible when the *.fig is opened in GUIDE mode. If I were you, I would revise the whole gui. As I said previously, there seem to be several panels on top of each other, are they of any use to you?
3 个评论
David Sanchez
2014-2-26
I played around with your gui and when you delete the panel I mentioned previously ("Change of values"), that "panel" sign doesn't show up. Somehow you manage to add it there. The easiest way to get rid of it will be to delete that small panel and create it again from scratch. Make sure on every step things go as expected.
更多回答(2 个)
David Sanchez
2014-2-26
In the GUIDE, expand the area of your GUI downwards and eastwards. Move the "Change of values" panel too. Click on the place where the ghost panel should be and make sure it is not there. Try also to select all "Ctrl+A" and make sure than it is highlighted only those objects visible in the final interface. You can attach the *.fig if the problem persists.
Image Analyst
2014-2-26
You most likely have some code in the OpeninfFcn() like this:
% Enlarge figure to full screen.
set(gcf, 'Units', 'Normalized', 'OuterPosition', [0 0 1 1]);
That sets the size to the full screen but does not take into account that you have a task bar set to be always on top. Change your position to be something less than full screen, like this:
% Enlarge figure to full screen.
set(gcf, 'Units', 'Normalized', 'OuterPosition', [0 0.1 1 0.9]);
Make sure that the Units property of all your controls is set to "normalized".
2 个评论
David Sanchez
2014-2-26
I checked your GUI. Did you realize there is a hidden panel behind the panel containing the 6 axis? Did you make this GUI or was it given to you like this? It seems that this gui is built on top of another one and is showing objects from both.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Migrate GUIDE Apps 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!