OVH Cloud OVH Cloud

GetThemeColor

1 réponse
Avatar
Drizzit
Bonjour =E0 toutes et =E0 tous.
Je cherche =E0 utiliser l API GetThemeColor
J'ai trouv=E9 ca d=E9claration qui est la suivante :
Public Declare Function GetThemeColor Lib "uxtheme.dll" (ByVal hTheme
As Long, ByVal iPartId As Long, ByVal iStateId As Long, ByVal iPropId
As Long, pColor As Long) As Long
Je connais tous les param=E8tres sauf 'iPropId' pour lequel j'ai touv=E9
une liste de Constantes possibles, mais le probl=E8me est l=E0, sans les
valeurs. J'ai beau chercher sur internet, je ne trouve pas.
Est-ce que quelqu'un =E0 cela sous la main ?

TMT_BORDERCOLOR ' The color of the border associated with this part
and state.
TMT_FILLCOLOR ' The color of the background fill associated with this
part and state.
TMT_TEXTCOLOR ' The color of the text associated with this part and
state.
TMT_EDGELIGHTCOLOR ' The light color of the edge associated with
this part and state.
TMT_EDGEHIGHLIGHTCOLOR ' The highlight color of the edge associated
with this part and state.
TMT_EDGESHADOWCOLOR ' The shadow color of the edge associated with
this part and state.
TMT_EDGEDKSHADOWCOLOR ' The dark shadow color of the edge
associated with this part and state.
TMT_EDGEFILLCOLOR ' The fill color of the edge associated with this
part and state.
TMT_TRANSPARENTCOLOR ' The transparent color associated with this
part and state. If the TMT_TRANSPARENT value for this part and state is
true (see GetThemeBool), parts of the graphic that use this color will
not be drawn.
TMT_GRADIENTCOLOR1 ' The first color of the gradient associated with
this part and state.
TMT_GRADIENTCOLOR2 ' The second color of the gradient.
TMT_GRADIENTCOLOR3 ' The third color of the gradient.
TMT_GRADIENTCOLOR4 ' The fourth color of the gradient.
TMT_GRADIENTCOLOR5 ' The fifth color of the gradient.
TMT_SHADOWCOLOR ' The color of the shadow drawn underneath text
associated with this part and state.
TMT_GLOWCOLOR ' The color of the glow produced by calling
DrawThemeIcon using this part and state.
TMT_TEXTBORDERCOLOR ' The color of the text border associated with
this part and state.
TMT_TEXTSHADOWCOLOR ' The color of the text shadow associated with
this part and state.
TMT_GLYPHTEXTCOLOR ' The color that the font-based glyph associated
with this part and state will use.
TMT_GLYPHTRANSPARENTCOLOR ' The transparent glyph color associated
with this part and state. If the TMT_GLYPHTRANSPARENT value for this
part and state is true (see GetThemeBool), parts of the glyph that use
this color will not be drawn.
TMT_FILLCOLORHINT ' The color used as a fill color hint for custom
controls.
TMT_BORDERCOLORHINT ' The color used as a border color hint for
custom controls.
TMT_ACCENTCOLORHINT ' The color used as an accent color hint for
custom controls.
TMT_BLENDCOLOR ' The color used as a blend color.

D'avance merci

1 réponse

Avatar
Jacques93
Bonjour Drizzit,
Drizzit a écrit :
Bonjour à toutes et à tous.
Je cherche à utiliser l API GetThemeColor
J'ai trouvé ca déclaration qui est la suivante :
Public Declare Function GetThemeColor Lib "uxtheme.dll" (ByVal hTheme
As Long, ByVal iPartId As Long, ByVal iStateId As Long, ByVal iPropId
As Long, pColor As Long) As Long
Je connais tous les paramètres sauf 'iPropId' pour lequel j'ai touvé
une liste de Constantes possibles, mais le problème est là, sans les
valeurs. J'ai beau chercher sur internet, je ne trouve pas.
Est-ce que quelqu'un à cela sous la main ?



Pour infos, ces constantes se trouvent dans Tmschema.h du SDK 2003 :

Private Const TMT_BORDERCOLOR = 3801 ' color of borders for
BorderFill
Private Const TMT_FILLCOLOR = 3802 ' color of bg fill
Private Const TMT_TEXTCOLOR = 3803 ' color text is drawn in
Private Const TMT_EDGELIGHTCOLOR = 3804 ' edge color
Private Const TMT_EDGEHIGHLIGHTCOLOR = 3805 ' edge color
Private Const TMT_EDGESHADOWCOLOR = 3806 ' edge color
Private Const TMT_EDGEDKSHADOWCOLOR = 3807 ' edge color
Private Const TMT_EDGEFILLCOLOR = 3808 ' edge color
Private Const TMT_TRANSPARENTCOLOR = 3809 ' color of pixels that are
treated as transparent (not drawn
Private Const TMT_GRADIENTCOLOR1 = 3810 ' first color in gradient
Private Const TMT_GRADIENTCOLOR2 = 3811 ' second color in gradient
Private Const TMT_GRADIENTCOLOR3 = 3812 ' third color in gradient
Private Const TMT_GRADIENTCOLOR4 = 3813 ' forth color in gradient
Private Const TMT_GRADIENTCOLOR5 = 3814 ' fifth color in gradient
Private Const TMT_SHADOWCOLOR = 3815 ' color of text shadow
Private Const TMT_GLOWCOLOR = 3816 ' color of glow produced
by DrawThemeIcon
Private Const TMT_TEXTBORDERCOLOR = 3817 ' color of text border
Private Const TMT_TEXTSHADOWCOLOR = 3818 ' color of text shadow
Private Const TMT_GLYPHTEXTCOLOR = 3819 ' color that font-based
glyph is drawn with
Private Const TMT_GLYPHTRANSPARENTCOLOR = 3820 ' color of
transparent pixels in GlyphImageFile
Private Const TMT_FILLCOLORHINT = 3821 ' hint about fill color
used (for custom controls)
Private Const TMT_BORDERCOLORHINT = 3822 ' hint about border color
used (for custom controls)
Private Const TMT_ACCENTCOLORHINT = 3823 ' hint about accent color
used (for custom controls)



--
Cordialement,

Jacques.