IActiveScriptAuthor::GetScriptTextAttributesIActiveScriptAuthor::GetScriptTextAttributes
Retourne les attributs de texte pour un bloc de script.Returns the text attributes for a script block.
SyntaxeSyntax
HRESULT GetScriptTextAttributes(
LPCOLESTR pszCode,
ULONG cch,
LPCOLESTR pszDelimiter,
DWORD dwFlags,
SOURCE_TEXT_ATTR *pattr);
);
ParamètresParameters
pszCode
[in, size_is (cch
)] le texte du bloc de script.[in, size_is(cch
)] The text of the script block. Cette chaîne ne devra pas se terminer par null.This string does not have to be null terminated.
cch
[in] La taille utilisée pour le pszCode
et pattr
paramètres.[in] The size used for the pszCode
and pattr
parameters.
pszDelimiter
[in] L’adresse du délimiteur de fin de script.[in] The address of the end-of-script delimiter. Lorsque pszCode
est analysé à partir d’un flux de texte, l’hôte utilise généralement un séparateur (par exemple, un double guillemet), pour détecter la fin du scriptlet.When pszCode
is parsed from a stream of text, the host typically uses a delimiter (such as two single quotation marks), to detect the end of the scriptlet. Définissez ce paramètre avec la valeur NULL s’il n’existe pas de séparateurs pour identifier la fin du bloc de script.Set this parameter to NULL if there is no delimiter to identify the end of the script block.
dwFlags
[in] Les indicateurs qui sont associés aux attributs de texte du bloc de script.[in] The flags that are associated with the text attributes of the script block. Peut être une combinaison des valeurs suivantes :Can be a combination of the following values:
ConstanteConstant | ValueValue | DescriptionDescription |
---|---|---|
GETATTRTYPE_DEPSCANGETATTRTYPE_DEPSCAN | 0 x 00010x0001 | Identifier des identificateurs qui ont l’attribut SOURCETEXT_ATTR_IDENTIFIER et identifier les opérateurs point qui ont l’attribut SOURCETEXT_ATTR_MEMBERLOOKUP.Identify identifiers that have the SOURCETEXT_ATTR_IDENTIFIER attribute, and identify dot operators that have the SOURCETEXT_ATTR_MEMBERLOOKUP attribute. |
GETATTRFLAG_THISGETATTRFLAG_THIS | 0x01000x0100 | Identifier l’objet actuel qui possède l’attribut SOURCETEXT_ATTR_THIS.Identify the current object that has the SOURCETEXT_ATTR_THIS attribute. |
GETATTRFLAG_HUMANTEXTGETATTRFLAG_HUMANTEXT | 0 x 80000x8000 | Identifier le texte de contenu et le commentaire chaîne ayant l’attribut SOURCETEXT_ATTR_HUMANTEXT.Identify string content and comment text that has the SOURCETEXT_ATTR_HUMANTEXT attribute. |
pattr
[in, out, size_is (cch
)] les informations de couleur pour le code de bloc de script.[in, out, size_is(cch
)] The color information for the script block code.
Valeur de retourReturn Value
Élément HRESULT
.An HRESULT
. Les valeurs possibles sont notamment celles figurant dans le tableau suivant.Possible values include, but are not limited to, those in the following table.
ValueValue | DescriptionDescription |
---|---|
S_OK |
La méthode a réussi.The method succeeded. |
NotesRemarks
Voir aussiSee Also
IActiveScriptAuthor (Interface) IActiveScriptAuthor Interface
Énumération SOURCE_TEXT_ATTRSOURCE_TEXT_ATTR Enumeration
Commentaires
Nous aimerions avoir votre avis. Choisissez le type d’avis que vous souhaitez fournir :
Notre système de commentaires est basé sur l’infrastructure de problèmes GitHub. Apprenez-en davantage sur notre blog.
Chargement du commentaire...