diff --git a/editions/tw5.com/tiddlers/filters/examples/jsonstringify Operator (Examples).tid b/editions/tw5.com/tiddlers/filters/examples/jsonstringify Operator (Examples).tid
deleted file mode 100644
index ead9ffb38..000000000
--- a/editions/tw5.com/tiddlers/filters/examples/jsonstringify Operator (Examples).tid
+++ /dev/null
@@ -1,9 +0,0 @@
-created: 20171029155046637
-modified: 20171029155227382
-tags: [[Operator Examples]] [[stringify Operator]]
-title: jsonstringify Operator (Examples)
-type: text/vnd.tiddlywiki
-
-<<.operator-example 1 """[[Title with "double quotes" and single ' and \backslash]] +[jsonstringify[]]""">>
-<<.operator-example 2 """[[Accents and emojis -> äñøßπ ⌛🎄🍪🍓 without suffix]] +[jsonstringify[]]""">>
-<<.operator-example 3 """[[Accents and emojis -> äñøßπ ⌛🎄🍪🍓 with rawunicode suffix]] +[jsonstringify:rawunicode[]]""">>
diff --git a/editions/tw5.com/tiddlers/filters/examples/stringify_Operator_(Examples).tid b/editions/tw5.com/tiddlers/filters/examples/stringify_Operator_(Examples).tid
index a664cf7d2..cc5a51429 100644
--- a/editions/tw5.com/tiddlers/filters/examples/stringify_Operator_(Examples).tid
+++ b/editions/tw5.com/tiddlers/filters/examples/stringify_Operator_(Examples).tid
@@ -1,9 +1,9 @@
created: 20161017154944352
-modified: 20171029155233487
+modified: 20230919124059118
tags: [[Operator Examples]] [[stringify Operator]]
title: stringify Operator (Examples)
type: text/vnd.tiddlywiki
<<.operator-example 1 """[[Title with "double quotes" and single ' and \backslash]] +[stringify[]]""">>
<<.operator-example 2 """[[Accents and emojis -> äñøßπ ⌛🎄🍪🍓 without suffix]] +[stringify[]]""">>
-<<.operator-example 3 """[[Accents and emojis -> äñøßπ ⌛🎄🍪🍓 with rawunicode suffix]] +[stringify:rawunicode[]]""">>
+<<.operator-example 3 """[[Accents and emojis -> äñøßπ ⌛🎄🍪🍓 with rawunicode suffix]] +[stringify:rawunicode[]]""">>
\ No newline at end of file
diff --git a/editions/tw5.com/tiddlers/filters/jsonstringify Operator.tid b/editions/tw5.com/tiddlers/filters/jsonstringify Operator.tid
index a7e4d565c..748a851bb 100644
--- a/editions/tw5.com/tiddlers/filters/jsonstringify Operator.tid
+++ b/editions/tw5.com/tiddlers/filters/jsonstringify Operator.tid
@@ -1,36 +1,12 @@
caption: jsonstringify
created: 20171029155051467
from-version: 5.1.14
-modified: 20171029155143797
-op-input: a [[selection of titles|Title Selection]]
-op-output: the input with JSON string encodings applied
+modified: 20230919124826880
op-parameter:
op-parameter-name:
-op-purpose: apply JSON string encoding to a string
-op-suffix: <<.from-version "5.1.23">> optionally, the keyword `rawunicode`
+op-purpose: deprecated, use <<.olink stringify>> instead
op-suffix-name: R
tags: [[Filter Operators]] [[String Operators]]
title: jsonstringify Operator
type: text/vnd.tiddlywiki
-The following substitutions are made:
-
-|!Character |!Replacement |!Condition |
-|`\` |`\\` |Always |
-|`"` |`\"` |Always |
-|Carriage return (0x0d) |`\\r` |Always |
-|Line feed (0x0a) |`\\n` |Always |
-|Backspace (0x08) |`\\b` |Always |
-|Form field (0x0c) |`\\f` |Always |
-|Tab (0x09) |`\\t` |Always |
-|Characters from 0x00 to 0x1f |`\\u####` where #### is four hex digits |Always |
-|Characters from 0x80 to 0xffff|`\\u####` where #### is four hex digits |If `rawunicode` suffix is not present (default) |
-|Characters from 0x80 to 0xffff|Unchanged |If `rawunicode` suffix is present <<.from-version "5.1.23">> |
-
-<<.from-version "5.1.23">> If the suffix `rawunicode` is present, Unicode characters above 0x80 (such as ß, ä, ñ or 🎄) will be passed through unchanged. Without the suffix, they will be substituted with `\\u` codes, which was the default behavior before 5.1.23.
-
-<<.note """Technical note: Characters outside the Basic Multilingual Plane, such as 🎄 and other emojis, will be encoded as a UTF-16 surrogate pair, i.e. with two `\u` sequences.""">>
-
-Also see the [[stringify Operator]].
-
-<<.operator-examples "jsonstringify">>
diff --git a/editions/tw5.com/tiddlers/filters/stringify_Operator.tid b/editions/tw5.com/tiddlers/filters/stringify_Operator.tid
index e06be4387..73dabb1c2 100644
--- a/editions/tw5.com/tiddlers/filters/stringify_Operator.tid
+++ b/editions/tw5.com/tiddlers/filters/stringify_Operator.tid
@@ -1,6 +1,7 @@
caption: stringify
created: 20161017153038029
-modified: 20171029155143797
+from-version: 5.1.14
+modified: 20230919130847809
op-input: a [[selection of titles|Title Selection]]
op-output: the input with ~JavaScript string encodings applied
op-parameter:
@@ -11,26 +12,25 @@ op-suffix-name: R
tags: [[Filter Operators]] [[String Operators]]
title: stringify Operator
type: text/vnd.tiddlywiki
-from-version: 5.1.14
The following substitutions are made:
|!Character |!Replacement |!Condition |
|`\` |`\\` |Always |
|`"` |`\"` |Always |
-|Carriage return (0x0d) |`\\r` |Always |
-|Line feed (0x0a) |`\\n` |Always |
-|Backspace (0x08) |`\\b` |Always |
-|Form field (0x0c) |`\\f` |Always |
-|Tab (0x09) |`\\t` |Always |
-|Characters from 0x00 to 0x1f |`\\x##` where ## is two hex digits |Always |
-|Characters from 0x80 to 0xffff|`\\u####` where #### is four hex digits |If `rawunicode` suffix is not present (default) |
+|Carriage return (0x0d) |`\r` |Always |
+|Line feed (0x0a) |`\n` |Always |
+|Backspace (0x08) |`\b` |Always |
+|Form field (0x0c) |`\f` |Always |
+|Tab (0x09) |`\t` |Always |
+|Characters from 0x00 to 0x1f |`\x##` where ## is two hex digits |Always |
+|Characters from 0x80 to 0xffff|`\u####` where #### is four hex digits |If `rawunicode` suffix is not present (default) |
|Characters from 0x80 to 0xffff|<<.from-version "5.1.23">> Unchanged |If `rawunicode` suffix is present |
-<<.from-version "5.1.23">> If the suffix `rawunicode` is present, Unicode characters above 0x80 (such as ß, ä, ñ or 🎄) will be passed through unchanged. Without the suffix, they will be substituted with `\\u` codes, which was the default behavior before 5.1.23.
+<<.from-version "5.1.23">> If the suffix `rawunicode` is present, Unicode characters above 0x80 (such as ß, ä, ñ or 🎄) will be passed through unchanged. Without the suffix, they will be substituted with `\u` codes, which was the default behavior before 5.1.23.
-<<.note """Technical note: Characters outside the Basic Multilingual Plane, such as 🎄 and other emojis, will be encoded as a UTF-16 surrogate pair, i.e. with two `\u` sequences.""">>
+<<.note """Characters outside the Basic Multilingual Plane, such as 🎄 and other emojis, will be encoded as a UTF-16 surrogate pair, i.e. with two `\u` sequences.""">>
-Also see the [[jsonstringify Operator]].
+<<.olink jsonstringify>> is considered deprecated, as it duplicates the functionality of <<.op stringify>>.
-<<.operator-examples "stringify">>
+<<.operator-examples "stringify">>
\ No newline at end of file
diff --git a/editions/tw5.com/tiddlers/howtos/Constructing JSON tiddlers.tid b/editions/tw5.com/tiddlers/howtos/Constructing JSON tiddlers.tid
index 58b36244c..ff4c7927c 100644
--- a/editions/tw5.com/tiddlers/howtos/Constructing JSON tiddlers.tid
+++ b/editions/tw5.com/tiddlers/howtos/Constructing JSON tiddlers.tid
@@ -1,7 +1,7 @@
-title: Constructing JSON tiddlers
-tags: [[JSON in TiddlyWiki]] [[Learning]]
created: 20220427174702859
-modified: 20220427174702859
+modified: 20230809113620964
+tags: [[JSON in TiddlyWiki]] Learning
+title: Constructing JSON tiddlers
See [[JSON in TiddlyWiki]] for an overview of using JSON in TiddlyWiki.
@@ -13,4 +13,4 @@ At a high level, we have several ways to generate JSON data in TiddlyWiki's own
* [[jsontiddler Macro]]
* [[jsontiddlers Macro]]
-When constructing JSON data manually, the [[jsonstringify Operator]] is needed to ensure that any special characters are properly escaped.
+When constructing JSON data manually, the [[stringify Operator]] is needed to ensure that any special characters are properly escaped.
diff --git a/editions/tw5.com/tiddlers/pragmas/Pragma_ _whitespace.tid b/editions/tw5.com/tiddlers/pragmas/Pragma_ _whitespace.tid
index 273a35bea..6e9f78287 100644
--- a/editions/tw5.com/tiddlers/pragmas/Pragma_ _whitespace.tid
+++ b/editions/tw5.com/tiddlers/pragmas/Pragma_ _whitespace.tid
@@ -1,13 +1,17 @@
created: 20220917113002350
-modified: 20230419103154329
+modified: 20230921180332436
tags: Pragmas
title: Pragma: \whitespace
type: text/vnd.tiddlywiki
-<<.from-version "5.1.15">> The ''\whitespace'' [[pragma|Pragmas]] determines how spaces and newlines are treated within wikitext. Note that this only applies to the printable text, and not to other text, such as the values of attributes.
+<<.from-version "5.1.15">> The ''\whitespace'' [[pragma|Pragmas]] determines how spaces and newlines are treated within wikitext.
* ''notrim'' -- whitespace text is not subject to special processing (the default)
-* ''trim'' -- whitespace text is removed
+* ''trim'' -- whitespace text is ignored
+
+Note that the processing only applies to the printable text, and not to other text, such as the values of attributes.
+
+The whitespace setting only applies to the parsed content in which it appears. The setting is inherited by embedded [[Procedure Definitions]] and [[Custom Widgets]] definitions, but is not inherited by [[Macro definitions]].
```
\whitespace trim|notrim
diff --git a/editions/tw5.com/tiddlers/procedures/Procedure Definitions.tid b/editions/tw5.com/tiddlers/procedures/Procedure Definitions.tid
index aa6d37a72..7d2ef564c 100644
--- a/editions/tw5.com/tiddlers/procedures/Procedure Definitions.tid
+++ b/editions/tw5.com/tiddlers/procedures/Procedure Definitions.tid
@@ -1,5 +1,5 @@
created: 20221007125701001
-modified: 20230419103154329
+modified: 20230921180332436
tags: WikiText Procedures
title: Procedure Definitions
type: text/vnd.tiddlywiki
@@ -18,6 +18,8 @@ This is the procedure text (param=<>)
\end
```
+Note that the [[Pragma: \whitespace]] setting is inherited from the parsing context in which the procedure definition occurs. That means that a tiddler containing multiple procedure definitions only needs a single whitespace pragma at the top of the tiddler, and the setting will be automatically inherited by the procedure definitions without needing the pragma to be repeated.
+
!! Procedure Definition with Set Widget
Procedures are implemented as a special kind of [[variable|Variables]] and so internally are actually defined with a <<.wlink SetWidget>> widget.
diff --git a/editions/tw5.com/tiddlers/widgets/Custom Widgets.tid b/editions/tw5.com/tiddlers/widgets/Custom Widgets.tid
index 3d762bed2..b8c48b2c3 100644
--- a/editions/tw5.com/tiddlers/widgets/Custom Widgets.tid
+++ b/editions/tw5.com/tiddlers/widgets/Custom Widgets.tid
@@ -1,5 +1,5 @@
created: 20221007144237585
-modified: 20230419103154328
+modified: 20230921180332436
tags: Concepts Reference
title: Custom Widgets
type: text/vnd.tiddlywiki
@@ -22,6 +22,8 @@ This is the widget, and the attribute is <>.
The name of the widget must start with a dollar sign. If it is a user defined widget that does not override an existing widget then it must include at least one period (dot) within the name (for example `$my.widget` or `$acme.logger`).
+Note that the [[Pragma: \whitespace]] setting is inherited from the parsing context in which the procedure definition occurs. That means that a tiddler containing multiple procedure definitions only needs a single whitespace pragma at the top of the tiddler, and the setting will be automatically inherited by the procedure definitions without needing the pragma to be repeated.
+
!! Using Custom Widgets
Custom widgets are called in the same way as ordinary built-in widgets: