columns_ui:config:global_variables
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
columns_ui:config:global_variables [2013/01/05 21:28] – deleted spam 79.181.68.35 | columns_ui:config:global_variables [2018/07/25 18:18] (current) – musicmusic | ||
---|---|---|---|
Line 3: | Line 3: | ||
Global variables were created as a way of speeding up playlist formatting, by separating the parts of formatting that is common to all your columns, and only processing it once per track instead of once per column. It works by defining variables which you can access in your column display strings. | Global variables were created as a way of speeding up playlist formatting, by separating the parts of formatting that is common to all your columns, and only processing it once per track instead of once per column. It works by defining variables which you can access in your column display strings. | ||
- | Note: Information on the legacy format for global variables can be viewed [[columns_ui: | ||
===== Global variables string ===== | ===== Global variables string ===== | ||
This string, in the [[columns_ui: | This string, in the [[columns_ui: | ||
Line 9: | Line 8: | ||
==== Setting variables ==== | ==== Setting variables ==== | ||
- | You can set variables in your global variables string using the '' | + | You can set variables in your global variables string using the '' |
- | ^ Standard-syntax titleformatting ^ Script-syntax titleformatting ^ | + | '' |
- | | $'' | + | |
Note: You can only define globals in the global string - i.e. you cannot access defined globals. | Note: You can only define globals in the global string - i.e. you cannot access defined globals. | ||
- | The truth value of a call to '' | + | The truth value of a call to '' |
===== Accessing global variables ===== | ===== Accessing global variables ===== | ||
- | You can access global variables in your display and style strings using the '' | + | You can access global variables in your display and style strings using the '' |
- | ^ Standard-syntax titleformatting ^ Script-syntax titleformatting ^ | + | '' |
- | | $'' | + | |
where | where | ||
- | * //variable name// is the name of the variable as defined in the '' | + | * //variable name// is the name of the variable as defined in the '' |
* the return value is the //variable value// | * the return value is the //variable value// | ||
- | The truth value of a call to '' | + | The truth value of a call to '' |
- | + | ||
- | ===== Notes on using the script-syntax ===== | + | |
- | + | ||
- | Things to remember: | + | |
- | * Strings are enclosed in quotation marks. For example: < | + | |
- | * To print a string you must use the print() function. For example: < | + |
columns_ui/config/global_variables.txt · Last modified: 2018/07/25 18:18 by musicmusic