Bonsoir
Je cherche a traduire un code Delphi sans succes
le code Delphi
Voici ce que j'ai ecrit
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13 // appel de la fonction DefFonte(C.Font, 'Times New Roman', 24, []); // la fonction a executer procedure DefFonte(F: TFont; Nom: string; Taille: integer; Styl: TFontStyles); begin with F do begin Name := Nom; Size := Taille; Style := Styl; end; end;
Le message d'erreur recu a la compilation
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14 // appel de la fonction DefFonte(Printer()->Canvas->Font, "Times New Roman", 24, []); // la fonction a executer void __fastcall TForm1::DefFonte(TFont F, String Nom, int Taille, TFontStyles Styl) { Font->Name = Nom; Font->Size = Taille; Font->Style = Styl; } // declaration dans le .h void __fastcall TForm1::DefFonte(TFont F, String Nom, int Taille, TFontStyles Styl);
Je n'arrive pas a solutionner ce probleme[C++ Error] Unit1.cpp(78): E2188 Expression syntax![]()
Partager