Commit 96eb2bf9 authored by Leena Miettinen's avatar Leena Miettinen
Browse files

Doc: edit customwizard plugin API docs



Use standard wording for class and function descriptions.
Edit for grammar and style.

Change-Id: Ia1872b044b4add0c7c057ed4495584bd2c91becf
Reviewed-by: default avatarFriedemann Kleint <Friedemann.Kleint@digia.com>
parent 83aad38c
......@@ -403,7 +403,7 @@ static QString listWizards()
}
/*!
\brief Reads \c share/qtcreator/templates/wizards and creates all custom wizards.
Reads \c share/qtcreator/templates/wizards and creates all custom wizards.
As other plugins might register factories for derived
classes, call it in extensionsInitialized().
......@@ -496,7 +496,7 @@ QList<CustomWizard*> CustomWizard::createWizards()
/*!
\class ProjectExplorer::CustomProjectWizard
\brief A custom project wizard.
\brief The CustomProjectWizard class provides a custom project wizard.
Presents a CustomProjectWizardDialog (Project intro page and fields page)
for wizards of type "project".
......@@ -513,7 +513,7 @@ CustomProjectWizard::CustomProjectWizard(const Core::BaseFileWizardParameters& b
}
/*!
\brief Can be reimplemented to create custom project wizards.
Can be reimplemented to create custom project wizards.
initProjectWizardDialog() needs to be called.
*/
......@@ -577,7 +577,7 @@ Core::GeneratedFiles CustomProjectWizard::generateFiles(const QWizard *w, QStrin
}
/*!
\brief Utility to open the projects and editors for the files that have
Opens the projects and editors for the files that have
the respective attributes set.
*/
......
......@@ -114,7 +114,8 @@ QString TextFieldComboBox::valueAt(int i) const
\brief The TextFieldCheckBox class is a aheckbox that plays with
\c QWizard::registerField.
Provides a settable 'text' property containing predefined strings for 'true'/'false').
Provides a settable 'text' property containing predefined strings for
\c true and \c false.
\sa ProjectExplorer::Internal::CustomWizardFieldPage, ProjectExplorer::CustomWizard
*/
......@@ -216,8 +217,8 @@ void CustomWizardFieldPage::clearError()
}
/*!
\brief Create widget a control based on the control attributes map
and register it with the QWizard.
Creates a widget based on the control attributes map and registers it with
the QWizard.
*/
void CustomWizardFieldPage::addField(const CustomWizardField &field)\
......@@ -507,7 +508,8 @@ QMap<QString, QString> CustomWizardFieldPage::replacementMap(const QWizard *w,
/*!
\class ProjectExplorer::Internal::CustomWizardPage
\brief A custom wizard page presenting the fields to be used and a path chooser
\brief The CustomWizardPage class provides a custom wizard page presenting
the fields to be used and a path chooser
at the bottom (for use by "class"/"file" wizards).
Does validation on the Path chooser only (as the other fields can by validated by regexps).
......
......@@ -904,9 +904,7 @@ bool replaceFieldHelper(ValueStringTransformation transform,
}
/*!
\brief Performs field replacements.
Replace field values delimited by '%' with special modifiers:
Replaces field values delimited by '%' with special modifiers:
\list
\li %Field% -> simple replacement
\li %Field:l% -> replace with everything changed to lower case
......@@ -965,12 +963,13 @@ QString TemporaryFileTransform::operator()(const QString &value) const
/*!
\class ProjectExplorer::Internal::CustomWizardContext
\brief Context used for one custom wizard run.
\brief The CustomWizardContext class provides the context for one custom
wizard run.
Shared between CustomWizard and the CustomWizardPage as it is used
for the QLineEdit-type fields'
default texts as well. Contains basic replacement fields
like \c '%CppSourceSuffix%', \c '%CppHeaderSuffix%' (settings-dependent)
like \c '%CppSourceSuffix%', \c '%CppHeaderSuffix%' (settings-dependent).
reset() should be called before each wizard run to refresh them.
CustomProjectWizard additionally inserts \c '%ProjectName%' from
the intro page to have it available for default texts.
......@@ -979,11 +978,13 @@ QString TemporaryFileTransform::operator()(const QString &value) const
*/
/*!
\brief Special replaceFields() overload used for the arguments of a generator
This function is a special replaceFields() overload used for the arguments
of a generator
script.
Write the expanded field values out to temporary files and
inserts file names instead of the expanded fields in string 's'.
Writes the expanded field values out to temporary files specified by
\a files and inserts file names instead of the expanded fields in the
string \a s.
*/
bool CustomWizardContext::replaceFields(const FieldReplacementMap &fm, QString *s,
......
......@@ -260,9 +260,9 @@ bool PreprocessContext::process(const QString &in, QString *out, QString *errorM
}
/*!
\brief Custom wizard preprocessor based on JavaScript expressions.
Implements a custom wizard preprocessor based on JavaScript expressions.
Preprocess a string using simple syntax:
Preprocesses a string using a simple syntax:
\code
Text
@if <JavaScript-expression>
......@@ -274,7 +274,7 @@ Blup
The JavaScript-expressions must evaluate to integers or boolean, like
\c '2 == 1 + 1', \c '"a" == "a"'. The variables of the custom wizard will be
expanded before, so , \c "%VAR%" should be used for strings and \c %VAR% for integers.
expanded before, so \c "%VAR%" should be used for strings and \c %VAR% for integers.
\sa ProjectExplorer::CustomWizard
*/
......
......@@ -145,9 +145,9 @@ static bool
}
/*!
\brief Custom wizard script generator function (Step1) - dry run.
Performs the first step in custom wizard script generation.
Do a dry run of the generation script to get a list of files
Does a dry run of the generation script to get a list of files.
\sa runCustomWizardGeneratorScript, ProjectExplorer::CustomWizard
*/
......@@ -205,11 +205,12 @@ Core::GeneratedFiles
}
/*!
\brief Custom wizard script generator function (Step2) - actual file creation.
Performs the second step in custom wizard script generation by actually
creating the files.
In addition to the <file> elements
that define template files in which macros are replaced, it is possible to have
a custom wizard call a generation script (specified in the "generatorscript"
a custom wizard call a generation script (specified in the \a generatorscript
attribute of the <files> element) which actually creates files.
The command line of the script must follow the convention
\code
......@@ -219,7 +220,7 @@ Core::GeneratedFiles
Options containing field placeholders are configured in the XML files
and will be passed with them replaced by their values.
As Qt Creator needs to know the file names before actually creates them to
As \QC needs to know the file names before it actually creates the files to
do overwrite checking etc., this is 2-step process:
\list
\li Determine file names and attributes: The script is called with the
......
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