1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-11-18 00:05:15 +00:00

Switch to using \procedure to define new-style macros, and \function for custom filter operator functions

I now need to update the OP!
This commit is contained in:
jeremy@jermolene.com
2022-05-09 18:00:09 +01:00
parent 64448ae774
commit e092113f9f
15 changed files with 80 additions and 29 deletions

View File

@@ -89,6 +89,7 @@ value: value of the variable
params: array of {name:, default:} for each parameter
isMacroDefinition: true if the variable is set via a \define macro pragma (and hence should have variable substitution performed)
options includes:
isProcedureDefinition: true if the variable is set via a \procedure pragma (and hence should not have variable substitution performed)
isFunctionDefinition: true if the variable is set via a \function pragma (and hence should not have variable substitution performed)
*/
Widget.prototype.setVariable = function(name,value,params,isMacroDefinition,options) {
@@ -97,7 +98,8 @@ Widget.prototype.setVariable = function(name,value,params,isMacroDefinition,opti
value: value,
params: params,
isMacroDefinition: !!isMacroDefinition,
isFunctionDefinition: !!options.isFunctionDefinition
isFunctionDefinition: !!options.isFunctionDefinition,
isProcedureDefinition: !!options.isProcedureDefinition
};
};