MATLAB SIMULINK 7 - GRAPHICAL USER INTERFACE Manual do Utilizador Página 270

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 330
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 269
10 Examples of GUIDE GUIs
10-46
Original_Size = [ 0 0 94 19.230769230769234];
% If the resized figure is smaller than the
% original figure size then compensate.
if (Figure_Size(3)<Original_Size(3)) | ...
(Figure_Size(4) ~= Original_Size(4))
if Figure_Size(3) < Original_Size(3)
% If the width is too small then reset to origianl width.
set(hObject, 'Position',...
[Figure_Size(1), Figure_Size(2), ...
Original_Size(3), Original_Size(4)])
Figure_Size = get(hObject, 'Position');
end
if Figure_Size(4) ~= Original_Size(4)
% Do not allow the height to change.
set(hObject, 'Position',...
[Figure_Size(1),...
Figure_Size(2)+Figure_Size(4)-Original_Size(4),...
Figure_Size(3), Original_Size(4)])
end
end
% Adjust the size of the Contact Name text box.
% Set the units of the Contact Name field to 'Normalized'.
set(handles.Contact_Name,'units','normalized')
% Get its Position.
C_N_pos = get(handles.Contact_Name,'Position');
% Reset it so that it's width remains normalized.
% relative to figure.
set(handles.Contact_Name,'Position',...
[C_N_pos(1) C_N_pos(2) 0.789 C_N_pos(4)])
% Return the units to 'Characters'.
set(handles.Contact_Name,'units','characters')
% Reposition GUI on screen.
movegui(hObject, 'onscreen')
Vista de página 269
1 2 ... 265 266 267 268 269 270 271 272 273 274 275 ... 329 330

Comentários a estes Manuais

Sem comentários