how can I make the .fig GUI width and height to be 900 x 100?

4 次查看(过去 30 天)
I want to make the .fig GUI width and height to be 900 x 100. The reason is that I need put more than 10 TabPanel inside one .fig GUI.
Right now, the largest width and height is only 384 x 81. As a result, I can only put 3 TabPanel inside.
thanks
  2 个评论
booterr
booterr 2016-6-20
编辑:Walter Roberson 2016-6-26
here is the code, which is generated automatically by Matlab:
function varargout = new(varargin)
% NEW MATLAB code for new.fig
% NEW, by itself, creates a new NEW or raises the existing
% singleton*.
%
% H = NEW returns the handle to a new NEW or the handle to
% the existing singleton*.
%
% NEW('CALLBACK',hObject,eventData,handles,...) calls the local
% function named CALLBACK in NEW.M with the given input arguments.
%
% NEW('Property','Value',...) creates a new NEW or raises the
% existing singleton*. Starting from the left, property value pairs are
% applied to the GUI before new_OpeningFcn gets called. An
% unrecognized property name or invalid value makes property application
% stop. All inputs are passed to new_OpeningFcn via varargin.
%
% *See GUI Options on GUIDE's Tools menu. Choose "GUI allows only one
% instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES
% Edit the above text to modify the response to help new
% Last Modified by GUIDE v2.5 19-Jun-2016 22:07:01
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @new_OpeningFcn, ...
'gui_OutputFcn', @new_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end

请先登录,再进行评论。

采纳的回答

Image Analyst
Image Analyst 2016-6-26
Double click in the figure to bring up the property inspector. Make sure the units property is "pixels". Then in the position property (expand it to see width and height), type in 900 for the width, and 100 for the height. If that still doesn't work, make sure the resize property is set to "on".
  3 个评论
Image Analyst
Image Analyst 2016-6-26
The window size is limited to the number of pixels on your screen. So unless you have a 9000 pixel wide screen, you'll have to scale down your panel size.
booterr
booterr 2016-6-26
Yes,this is really an great answer. I understand. You are right, My current screen setup is 1920x1080. This means the GUI'fig' can only have max 1920 x 1080 pixels size. It looks like I need think another method to design multiple tabpanels.

请先登录,再进行评论。

更多回答(2 个)

Andrew Bliss
Andrew Bliss 2016-6-13
Using "guide" just resize with the black box in the lower right corner.
  1 个评论
booterr
booterr 2016-6-20
编辑:booterr 2016-6-26
yes, I already use "Guide" to resize the black box to the max, which seems only allow 384 x 81 size. The "Guide" does not work to change the GUI to a bigger size

请先登录,再进行评论。


Walter Roberson
Walter Roberson 2016-6-26

类别

Help CenterFile Exchange 中查找有关 Migrate GUIDE Apps 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by