Commit 6032847c authored by Riitta-Leena Miettinen's avatar Riitta-Leena Miettinen Committed by Orgad Shaneh

Doc: Using pattern substitution when expanding variables

Change-Id: Ifaf8dddf7b5991d6b472d80cb9e94f42de75c1e7
Reviewed-by: Orgad Shaneh's avatarOrgad Shaneh <orgads@gmail.com>
parent ff2c4953
......@@ -111,6 +111,30 @@
(\uicontrol {Variables}) button in a field to select from a list of variables that
are available in a particular context.
\QC uses pattern substitution when expanding variable names. To replace the
first match of \e pattern within \e variable with \e replacement, use:
\badcode
%{variable/pattern/replacement}
\endcode
To replace all matches of \e pattern within \e variable with \e replacement,
use:
\badcode
%{variable//pattern/replacement}
\endcode
The pattern can be a regular expression and the replacement can contain
backreferences. For example, if \c %{variable} is \c my123var, then
\c %{variable/(..)(\d+)/\2\1} is expanded to \c {123myvar}.
To use the default value if the variable is not set, use:
\badcode
%{variable:-default}
\endcode
\section1 Build Steps
The build system of \QC is built on qmake and make. In \uicontrol{Build Steps} you
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment