?? vis_footnotebuttondownfcn.m
字號:
function vis_footnoteButtonDownFcn% VIS_FOOTNOTEBUTTONDOWNFCN Callback set by VIS_FOOTNOTE%% som_showtitleButtonDownFcn%% Moves the axis of current callback object using DRAGRECT% command. This callback is set to all texts added to figures by % VIS_FOOTNOTE function.%% See also DRAGRECT, SOM_SHOWTITLE.% Copyright (c) 1997-2000 by the SOM toolbox programming team.% http://www.cis.hut.fi/projects/somtoolbox/ % Version 2.0beta Johan 080698% Action[txt,fig]=gcbo; % Get text and figure handlesax=get(txt,'parent'); % Get axis handlememunits_fig=get(fig,'units'); % Get figure size in pixelsset(gcf,'units','pixels'); pos_fig=get(fig,'position'); memunits_txt=get(txt,'units'); % Get text field size in pixelsset(txt,'units','pixels'); text_size=get(txt,'extent');memunits_ax=get(ax,'units'); % Get axis position in pixelsset(ax,'units','pixels'); pos_ax=get(ax,'position');%%% Move textpos_final=dragrect([pos_ax(1:2) text_size(3:4)]);%%% Keep the text inside the figure!pos_final(1)=max(pos_final(1),0);pos_final(2)=max(pos_final(2),0);pos_final(1)=min(pos_final(1),pos_fig(3)-text_size(3));pos_final(2)=min(pos_final(2),pos_fig(4)-text_size(4));%%% Set new positionnew_pos=[pos_final(1:2) pos_ax(3:4)];set(ax,'position', new_pos);%%% Set the text on the top of the object stack children=get(gcf,'children');i=find(ismember(children,ax));new_i=[i 1:i-1 i+1:length(children)];set(gcf,'children',children(new_i));set(txt,'position',[0 0 0]);set(fig,'units',memunits_fig);set(ax,'units',memunits_ax);set(txt,'units',memunits_txt);
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -