Merge pull request #3774 from TBM13/feature/calculatorHexNumbers

Calculator: Support hex numbers
This commit is contained in:
Jack Ye 2025-06-26 19:26:05 +08:00 committed by GitHub
commit b1832983a5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -20,7 +20,7 @@ namespace Flow.Launcher.Plugin.Calculator
@"bin2dec|hex2dec|oct2dec|" +
@"factorial|sign|isprime|isinfty|" +
@"==|~=|&&|\|\||(?:\<|\>)=?|" +
@"[ei]|[0-9]|[\+\%\-\*\/\^\., ""]|[\(\)\|\!\[\]]" +
@"[ei]|[0-9]|0x[\da-fA-F]+|[\+\%\-\*\/\^\., ""]|[\(\)\|\!\[\]]" +
@")+$", RegexOptions.Compiled);
private static readonly Regex RegBrackets = new Regex(@"[\(\)\[\]]", RegexOptions.Compiled);
private static Engine MagesEngine;