function buttonswap_scal_BKP(hObject, eventdata, parentfig,Empty_Button,Button,titles,Plotsettings,LockMode,Footnote, AxesAFS)

set(Plotsettings(1),'String',num2str(20));
set(Plotsettings(2),'String',num2str(0.1));
set(Plotsettings(3),'String',num2str(0.1));

data = get(Empty_Button,'UserData');
if data.scalBorg==1
    data.scalBorg=0;
    set(titles(2),'String','Generalized Borgen plot - FSV-scaling');

    set(hObject,'String','swap to RS-scal.','TooltipString', sprintf('transform the AFS into the RS-scaling'));
else
    data.scalBorg=1;
    set(titles(2),'String','Generalized Borgen plot - RS-scaling');

    set(hObject,'String','swap to FSV-scal.','TooltipString', sprintf('transform the AFS into the FSV-scaling'));
end

set(Empty_Button,'UserData',data);

plotAFS_BKP(Empty_Button,AxesAFS);



if isfield(data, 'FixPoint1_B')==1 && size(data.FixPoint1_B,1)>0
    if data.scalBorg==1
        plot(AxesAFS, data.FixPoint1_B(1), data.FixPoint1_B(2),'kx','LineWidth',2);
    else
       plot(AxesAFS, data.FixPoint1_SV(1), data.FixPoint1_SV(2),'kx','LineWidth',2);
    end
end

if isfield(data, 'FixPoint2_B')==1 && size(data.FixPoint2_B,1)>0
    if data.scalBorg==1
        plot(AxesAFS, data.FixPoint2_B(1), data.FixPoint2_B(2),'ko','LineWidth',2);
    else
       plot(AxesAFS, data.FixPoint2_SV(1), data.FixPoint2_SV(2),'ko','LineWidth',2);
    end
end

if isfield(data, 'FixPoint3_B')==1 && size(data.FixPoint3_B,1)>0
    if data.scalBorg==1
        plot(AxesAFS, data.FixPoint3_B(1), data.FixPoint3_B(2),'k+','LineWidth',2);
    else
       plot(AxesAFS, data.FixPoint3_SV(1), data.FixPoint3_SV(2),'k+','LineWidth',2);
    end
end

if isfield(data,'AFSL2_B')==1 && size(data.AFSL2_B,1)>0
    plotAFSLock_BKP(Empty_Button, AxesAFS,2);
elseif isfield(data,'AFSL_B')==1 && data.numb_segmentsL(1)>0
    plotAFSLock_BKP(Empty_Button, AxesAFS,1);
end

