function hinsert = render_sptinsertmenu(hFig, pos)
%RENDER_SPTINSERTMENU Render a Signal Processing Toolbox "Insert" menu.
%   HINSERT = RENDER_SPTINSERTMENU(HFIG, POS) creates a "Insert" menu in POS position
%   on a figure whose handle is HFIG and return the handles to all the menu items.

%   Author(s): V.Pellissier
%   Copyright 1988-2003 The MathWorks, Inc.
%   $Revision: 1.4.4.2 $  $Date: 2004/04/13 00:32:41 $ 

strs = {'&Insert', ...
    '&X Label', ...
    '&Y Label', ...
    '&Title', ...
    'Dou&bleArrow', ...
    'A&rrow', ...
    'Li&ne', ...
    'Textb&ox', ...
    'Rectan&gle'};

% Work around so our zoom and the scribe buttons remain exclusive
cbs = {'', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn Xlabel', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn Ylabel', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn Title', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn DoubleArrow', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn Arrow', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn Line', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn Textbox', ...
    'sigsetappdata(gcbf,''siggui'',''ZoomState'', ''none'');setzoomstate(gcbf);insertmenufcn Rectangle'};

tags = {'insert', ...
    'figMenuInsertXLabel', ...
    'figMenuInsertYLabel', ...
    'figMenuInsertTitle', ...
    'figMenuInsertArrow', ...
    'figMenuInsertArrow', ...
    'figMenuInsertLine', ...
    'figMenuInsertTextbox', ...
    'figMenuInsertRectangle'};

sep = {'off', ...
    'off', ...
    'off', ...
    'off', ...
    'on', ...
    'off', ...
    'off', ...
    'off', ...
    'off'};

accel = {'', ...
    '', ...
    '', ...
    '', ...
    '', ...
    '', ...
    '', ...
    '', ...
    '', ...
    ''};

hinsert = addmenu(hFig,pos,strs,cbs,tags,sep,accel);

% [EOF]
