Copy Paste

버전 1.0.0.0 (36.2 KB) 작성자: Amitabh Verma
A simple Cut, Copy, Paste contextmenu for edit boxes in GUI.
다운로드 수: 1K
업데이트 날짜: 2010/6/21

라이선스 보기

Copy Paste ver. 1.0

This is a very simple cut/copy/paste context menu using java handles. This code uses findjobj by Yair Altman (http://www.mathworks.com/matlabcentral/fileexchange/14317-findjobj-find-java-handles-of-matlab-graphic-objects) to locate the java handles.

Usage:
copy_paste(hObject)

Example:

f1 = figure('Name','Copy-Paste','Position', [480 480 340 100],'NumberTitle','off');
h1 = uicontrol(f1, 'Style', 'edit',...
'String', 'Cut',...
'BackgroundColor', [1 1 1],...
'Position', [10 10 100 50]);
h2 = uicontrol(f1, 'Style', 'edit',...
'String', 'Copy',...
'BackgroundColor', [1 1 1],...
'Position', [120 10 100 50]);
h3 = uicontrol(f1, 'Style', 'edit',...
'String', 'Paste',...
'BackgroundColor', [1 1 1],...
'Position', [230 10 100 50]);

% For single edit box object
copy_paste(h2);

% For selected edit box object
copy_paste(h1,h3);

% For all the edit boxes in a figure
copy_paste(gcf) or copy_paste(f1)

Your comments and suggestions are most welcomed.

인용 양식

Amitabh Verma (2024). Copy Paste (https://www.mathworks.com/matlabcentral/fileexchange/27971-copy-paste), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2010a
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Migrate GUIDE Apps에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!
버전 게시됨 릴리스 정보
1.0.0.0