cs_slayer
Messages postés202Date d'inscriptiondimanche 1 septembre 2002StatutMembreDernière intervention18 mars 2008
-
13 avril 2003 à 09:47
Weado
Messages postés119Date d'inscriptionmercredi 19 juin 2002StatutMembreDernière intervention21 avril 2009
-
19 mai 2003 à 20:58
Cette discussion concerne un article du site. Pour la consulter dans son contexte d'origine, cliquez sur le lien ci-dessous.
Weado
Messages postés119Date d'inscriptionmercredi 19 juin 2002StatutMembreDernière intervention21 avril 2009 19 mai 2003 à 20:58
au pire utilise une fonction call
BasicInstinct
Messages postés1470Date d'inscriptionmardi 5 février 2002StatutMembreDernière intervention20 octobre 201412 15 avril 2003 à 09:16
Directement pompé de l'Api-GUIDE
'In a module
Public Const NTM_REGULAR = &H40&
Public Const NTM_BOLD = &H20&
Public Const NTM_ITALIC = &H1&
Public Const TMPF_FIXED_PITCH = &H1
Public Const TMPF_VECTOR = &H2
Public Const TMPF_DEVICE = &H8
Public Const TMPF_TRUETYPE = &H4
Public Const ELF_VERSION = 0
Public Const ELF_CULTURE_LATIN = 0
Public Const RASTER_FONTTYPE = &H1
Public Const DEVICE_FONTTYPE = &H2
Public Const TRUETYPE_FONTTYPE = &H4
Public Const LF_FACESIZE = 32
Public Const LF_FULLFACESIZE = 64
Type LOGFONT
lfHeight As Long
lfWidth As Long
lfEscapement As Long
lfOrientation As Long
lfWeight As Long
lfItalic As Byte
lfUnderline As Byte
lfStrikeOut As Byte
lfCharSet As Byte
lfOutPrecision As Byte
lfClipPrecision As Byte
lfQuality As Byte
lfPitchAndFamily As Byte
lfFaceName(LF_FACESIZE) As Byte
End Type
Type NEWTEXTMETRIC
tmHeight As Long
tmAscent As Long
tmDescent As Long
tmInternalLeading As Long
tmExternalLeading As Long
tmAveCharWidth As Long
tmMaxCharWidth As Long
tmWeight As Long
tmOverhang As Long
tmDigitizedAspectX As Long
tmDigitizedAspectY As Long
tmFirstChar As Byte
tmLastChar As Byte
tmDefaultChar As Byte
tmBreakChar As Byte
tmItalic As Byte
tmUnderlined As Byte
tmStruckOut As Byte
tmPitchAndFamily As Byte
tmCharSet As Byte
ntmFlags As Long
ntmSizeEM As Long
ntmCellHeight As Long
ntmAveWidth As Long
End Type
Declare Function EnumFontFamiliesEx Lib "gdi32" Alias "EnumFontFamiliesExA" (ByVal hdc As Long, lpLogFont As LOGFONT, ByVal lpEnumFontProc As Long, ByVal LParam As Long, ByVal dw As Long) As Long
Function EnumFontFamProc(lpNLF As LOGFONT, lpNTM As NEWTEXTMETRIC, ByVal FontType As Long, LParam As Long) As Long
Dim FaceName As String
'convert the returned string to Unicode
FaceName = StrConv(lpNLF.lfFaceName, vbUnicode)
'print the form on Form1
Form1.Print Left$(FaceName, InStr(FaceName, vbNullChar) - 1)
'continue enumeration
EnumFontFamProc = 1
End Function
'In a form
Private Sub Form_Load()
'KPD-Team 2000
'URL: http://www.allapi.net/ 'E-Mail: KPDTeam@Allapi.net
Dim LF As LOGFONT
'set graphics mode to persistent
Me.AutoRedraw = True
'enumerates the fonts
EnumFontFamiliesEx Me.hdc, LF, AddressOf EnumFontFamProc, ByVal 0&, 0
End Sub
sebleboss2002
Messages postés189Date d'inscriptionlundi 30 décembre 2002StatutMembreDernière intervention 3 avril 2005 14 avril 2003 à 18:34
Ah, c'est vrai ke j'avais pas pensé a ce problème... Dans ce cas, connaitrais-tu un autre moyen de lister les polices windows ???
BasicInstinct
Messages postés1470Date d'inscriptionmardi 5 février 2002StatutMembreDernière intervention20 octobre 201412 14 avril 2003 à 10:58
'lut
ca fait plaisir d'avoir son nom dans les commentaires d'une sources...
Petit defaut de la source, tu utilise l'objet printer pour lister les polices, Mais malheureusement ne possedant pas d'imprimantes parametrees, j'ai 1 zoli message d'erreur 482 : erreur d'impimante
Sinon c'est une joli source :)
sebleboss2002
Messages postés189Date d'inscriptionlundi 30 décembre 2002StatutMembreDernière intervention 3 avril 2005 13 avril 2003 à 20:14
Ah !!! Merci beaucoup !!!
cs_tex
Messages postés116Date d'inscriptionlundi 16 septembre 2002StatutMembreDernière intervention23 mai 2004 13 avril 2003 à 18:50
Slt
g trouvé le prob avec ton bug pour le btn Copier de la toolbar :
en fait tu l'as nommé "paste" et tu as mis "past" dans le code.
Voilà, @+ tex
sebleboss2002
Messages postés189Date d'inscriptionlundi 30 décembre 2002StatutMembreDernière intervention 3 avril 2005 13 avril 2003 à 10:39
ok, pas de prob !
P.S : C'est koi ta photo ?????
DarthPredateur
Messages postés30Date d'inscriptionvendredi 17 janvier 2003StatutMembreDernière intervention25 mars 2003 13 avril 2003 à 10:17
une capture serait la bienvenue !
sebleboss2002
Messages postés189Date d'inscriptionlundi 30 décembre 2002StatutMembreDernière intervention 3 avril 2005 13 avril 2003 à 10:07
Lol ! Trop rapide mon gars !!!! ;)
cs_slayer
Messages postés202Date d'inscriptiondimanche 1 septembre 2002StatutMembreDernière intervention18 mars 2008 13 avril 2003 à 09:47
Tien, je suis passer trop to le zip n'est pas encore, je repasserai plus tard testé ça !!!
19 mai 2003 à 20:58
15 avril 2003 à 09:16
'In a module
Public Const NTM_REGULAR = &H40&
Public Const NTM_BOLD = &H20&
Public Const NTM_ITALIC = &H1&
Public Const TMPF_FIXED_PITCH = &H1
Public Const TMPF_VECTOR = &H2
Public Const TMPF_DEVICE = &H8
Public Const TMPF_TRUETYPE = &H4
Public Const ELF_VERSION = 0
Public Const ELF_CULTURE_LATIN = 0
Public Const RASTER_FONTTYPE = &H1
Public Const DEVICE_FONTTYPE = &H2
Public Const TRUETYPE_FONTTYPE = &H4
Public Const LF_FACESIZE = 32
Public Const LF_FULLFACESIZE = 64
Type LOGFONT
lfHeight As Long
lfWidth As Long
lfEscapement As Long
lfOrientation As Long
lfWeight As Long
lfItalic As Byte
lfUnderline As Byte
lfStrikeOut As Byte
lfCharSet As Byte
lfOutPrecision As Byte
lfClipPrecision As Byte
lfQuality As Byte
lfPitchAndFamily As Byte
lfFaceName(LF_FACESIZE) As Byte
End Type
Type NEWTEXTMETRIC
tmHeight As Long
tmAscent As Long
tmDescent As Long
tmInternalLeading As Long
tmExternalLeading As Long
tmAveCharWidth As Long
tmMaxCharWidth As Long
tmWeight As Long
tmOverhang As Long
tmDigitizedAspectX As Long
tmDigitizedAspectY As Long
tmFirstChar As Byte
tmLastChar As Byte
tmDefaultChar As Byte
tmBreakChar As Byte
tmItalic As Byte
tmUnderlined As Byte
tmStruckOut As Byte
tmPitchAndFamily As Byte
tmCharSet As Byte
ntmFlags As Long
ntmSizeEM As Long
ntmCellHeight As Long
ntmAveWidth As Long
End Type
Declare Function EnumFontFamiliesEx Lib "gdi32" Alias "EnumFontFamiliesExA" (ByVal hdc As Long, lpLogFont As LOGFONT, ByVal lpEnumFontProc As Long, ByVal LParam As Long, ByVal dw As Long) As Long
Function EnumFontFamProc(lpNLF As LOGFONT, lpNTM As NEWTEXTMETRIC, ByVal FontType As Long, LParam As Long) As Long
Dim FaceName As String
'convert the returned string to Unicode
FaceName = StrConv(lpNLF.lfFaceName, vbUnicode)
'print the form on Form1
Form1.Print Left$(FaceName, InStr(FaceName, vbNullChar) - 1)
'continue enumeration
EnumFontFamProc = 1
End Function
'In a form
Private Sub Form_Load()
'KPD-Team 2000
'URL: http://www.allapi.net/
'E-Mail: KPDTeam@Allapi.net
Dim LF As LOGFONT
'set graphics mode to persistent
Me.AutoRedraw = True
'enumerates the fonts
EnumFontFamiliesEx Me.hdc, LF, AddressOf EnumFontFamProc, ByVal 0&, 0
End Sub
14 avril 2003 à 18:34
14 avril 2003 à 10:58
ca fait plaisir d'avoir son nom dans les commentaires d'une sources...
Petit defaut de la source, tu utilise l'objet printer pour lister les polices, Mais malheureusement ne possedant pas d'imprimantes parametrees, j'ai 1 zoli message d'erreur 482 : erreur d'impimante
Sinon c'est une joli source :)
13 avril 2003 à 20:14
13 avril 2003 à 18:50
g trouvé le prob avec ton bug pour le btn Copier de la toolbar :
en fait tu l'as nommé "paste" et tu as mis "past" dans le code.
Voilà, @+ tex
13 avril 2003 à 10:39
P.S : C'est koi ta photo ?????
13 avril 2003 à 10:17
13 avril 2003 à 10:07
13 avril 2003 à 09:47