This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | Next revision Both sides next revision | ||
Text_Fields [2019/06/25 08:45] peternlewis |
Text_Fields [2019/07/01 01:04] peternlewis |
||
---|---|---|---|
Line 35: | Line 35: | ||
You can insert text tokens into text fields using the *Edit ➤ Insert Token* menu. If you hold the option key down while selecting a token, you will get help on that token (from this wiki). | You can insert text tokens into text fields using the *Edit ➤ Insert Token* menu. If you hold the option key down while selecting a token, you will get help on that token (from this wiki). | ||
- | Text token fields also process %NN% or %NNNN% as arbitrary hex unicode characters (eg %41% is an A), and (except for regular expression fields) process backslashed characters `\a`,`\b`,`\e`,`\f`,`\t`,`\r`,`\n` (bell,backspace,escape,form feed,tab,return,line feed). | + | Text token fields also process %NN% or %NNNN% or %NNNNNN% as arbitrary hex unicode characters (eg %41% is an A, %01F300% is 🌀), and (except for regular expression fields) process backslashed characters \a,\b,\e,\f,\t,\r,\n (bell,backspace,escape,form feed,tab,return,line feed). |
- | To include a percent in your text, simply double the percent (%%). To include a backslash \ in your text, double the backslash (\\). | + | Text tokens can also include the [[manial:Tokens#Text_Case_Conversions|Text Case Conversion]] characters like `\U` and `\L`. |
- | ==== Text Case Conversions ==== | + | In most text fields, you can select (in the BUTTON{{{⚙}}} menu) whether to process normally, or just tokens (not backspashed characters) or do no text processing at all. Alternatively, to include a percent in your text, simply double the percent (%%). To include a backslash \ in your text, double the backslash (\\). |
- | + | ||
- | Text token fields also support (v9.0+) text case conversion escapes. The most common use is to change the case of an interpolated variable or other token, as well as in [[action:Search_and_Replace|Search and Replace by regular expression]] action. The conversion escape codes are: | + | |
- | + | ||
- | * `\U` converts everything up to the next `\L` or `\E` to uppercase. | + | |
- | * `\L` converts everything up to the next `\U` or `\E` to lowercase. | + | |
- | * `\u` converts the next character to uppercase. | + | |
- | * `\l` converts the next character to lowercase. | + | |
- | * `\U\l` lowercase first, then uppercase. | + | |
- | * `\L\u` uppercase first, then lowercase. | + | |
- | * `\E` stop changing case. | + | |
- | + | ||
- | You should not use `\u` after `\U` or `\l` after `\L` unless you terminate the sequence with `\E` first. | + | |
===== Script Fields ===== | ===== Script Fields ===== |