diff --git a/@CVC_checker/pvs_to_cvc_subtypes.m b/@CVC_checker/pvs_to_cvc_subtypes.m index ed79aa07ce1358105b0f506684666cd853d48548..c0346d0d0cf3849ab31079346fa52f4370c6329c 100644 --- a/@CVC_checker/pvs_to_cvc_subtypes.m +++ b/@CVC_checker/pvs_to_cvc_subtypes.m @@ -2,19 +2,33 @@ function [ cvc_type ] = pvs_to_cvc_subtypes( pvs_type ) %PVS_TO_CVC_SUBTYPES Summary of this function goes here % Detailed explanation goes here + + + %pvs_type is parsed string = char(pvs_type); + +% change cases +string = regexprep(string,'real','REAL'); +string = regexprep(string,'Real','REAL'); +string = regexprep(string,'int','INT'); +string = regexprep(string,'Int','INT'); +string = regexprep(string,'bool','BOOLEAN'); +string = regexprep(string,'Bool','BOOLEAN'); +string = regexprep(string,'BOOL[^EAN]','BOOLEAN'); + % remove brackets string_no_brack = regexp(string,'(?<=\{)[^\n]*(?=\})','match'); if isempty(string_no_brack) - cvc_type = pvs_type; + + cvc_type = {string}; return end split_at_pipe = regexp(char(string_no_brack),'\|','split'); if (size(split_at_pipe,2) ~= 2) %something strange happened - cvc_type = pvs_type; + cvc_type = {string}; return; end diff --git a/@GUI/textbox_callback.m b/@GUI/textbox_callback.m index f12db25e0a2ce6bfdcfd66e977a47d593244b0e5..4e50b1a5b3eb6f141d465e08e467e0d3596ef91e 100644 --- a/@GUI/textbox_callback.m +++ b/@GUI/textbox_callback.m @@ -17,6 +17,13 @@ end if((strcmp(event.Character,'r')) && (strcmp(char(event.Modifier),'command') || strcmp(char(event.Modifier),'control'))) return end + +if strcmp(event.Key,'tab') + event.Character = ''; + return; +end + + if(~isempty(unicode2native(event.Character))) % make sure the character is a printable character if event.Character > 33 || event.Character == 8