Bonsoir,

Je suis débutant python 2.7.x.
J'ai créé une mini apli, une télécommande pour Linux.
Mon gui est sur Tkinter.
Je voudrais savoir s'il est possible d'ajouter des mini-icônes (des touches de la télécommande) dans mon menu.
Si non que faut-il faire pour cela ?
Pouvez-vous m'aiguiller ?

Exemple :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
Fichier   Touches 
                 +  Touche 1 (mini icônes)
                 +  Touche 2 (mini icônes)
Pour une sélection plus rapide des touches en un coup d'oeil depuis le menu.

Mon Menu :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
from Tkinter import *
menubar = Menu(fenetre)
fichier_menu = Menu(menubar, tearoff=0)
fichier_menu.add_command(label="Quitter", command=fenetre.quit)
menubar.add_cascade(label="Fichier", menu=fichier_menu)
 
edit_menu = Menu(menubar, tearoff=0)
edit_menu.add_command(label="Undo", command=donothing)
edit_menu.add_separator()
edit_menu.add_command(label="Couper", command=donothing)
edit_menu.add_command(label="Copier", command=donothing)
edit_menu.add_command(label="Coller", command=donothing)
edit_menu.add_command(label="Supprimer", command=donothing)
edit_menu.add_command(label="Test", command=test)
edit_menu.add_command(label="Test2", command=test2)
edit_menu.add_command(label="Configuration", command=configuration)
edit_menu.add_command(label="Erreur", command=erreur_url)
edit_menu.add_command(label="Tout Selectionner", command=donothing)
menubar.add_cascade(label="Edition", menu=edit_menu)
 
touche_menu = Menu(menubar, tearoff=0)
touche_menu.add_command(label="Freebox V5", command=donothing)
touche_menu.add_command(label="Freebox V6", command=donothing)
touche_menu.add_separator()
touche_menu.add_command(label="touche_R", command=touche_Cote_Droit_R)
touche_menu.add_command(label="Touche B", command=touche_Rond_Rouge_B)
touche_menu.add_command(label="Touche Y", command=touche_Rond_Jaune_Y)
touche_menu.add_command(label="Touche A", command=touche_Rond_Vert_A)
touche_menu.add_command(label="Touche X", command=touche_Rond_Bleu_X)
touche_menu.add_command(label="Touche Select", command=touche_Select)
touche_menu.add_command(label="Touche Marche Arret", command=touche_On_Off)
touche_menu.add_command(label="Touche Liste", command=touche_liste)
touche_menu.add_command(label="Touche Tv", command=touche_TV)
touche_menu.add_command(label="Touche 1", command=touche_1)
touche_menu.add_command(label="Touche 2", command=touche_2)
touche_menu.add_command(label="Touche 3", command=touche_3)
touche_menu.add_command(label="Touche 4", command=touche_4)
touche_menu.add_command(label="Touche 5", command=touche_5)
touche_menu.add_command(label="Touche 6", command=touche_6)
touche_menu.add_command(label="Touche 7", command=touche_7)
touche_menu.add_command(label="Touche 8", command=touche_8)
touche_menu.add_command(label="Touche 9", command=touche_9)
touche_menu.add_command(label="Touche 0", command=touche_0)
touche_menu.add_command(label="Touche INFO", command=touche_INFO)
touche_menu.add_command(label="Touche MAIL", command=touche_MAIL)
touche_menu.add_command(label="Touche AIDE", command=touche_HELP)
touche_menu.add_command(label="Touche PIP", command=touche_PIP)
touche_menu.add_command(label="Touche Back", command=touche_Back)
touche_menu.add_command(label="Touche Swap", command=touche_Swap)
touche_menu.add_command(label="Touche Volume +", command=touche_volume_plus)
touche_menu.add_command(label="Touche Volume -", command=touche_volume_moins)
touche_menu.add_command(label="Touche ^", command=touche_fleche_haut)
touche_menu.add_command(label="Touche <--", command=touche_fleche_gauche)
touche_menu.add_command(label="Touche Ok", command=touche_OK)
touche_menu.add_command(label="Touche bas", command=touche_fleche_bas)
touche_menu.add_command(label="Touche -->", command=touche_fleche_droite)
touche_menu.add_command(label="Touche Programme +", command=touche_programme_plus)
touche_menu.add_command(label="Touche Programme -", command=touche_programme_moins)
touche_menu.add_command(label="Touche Mute", command=touche_mute)
touche_menu.add_command(label="Touche Home", command=touche_free)
touche_menu.add_command(label="Touche Rec", command=touche_rec)
touche_menu.add_command(label="Touche << (Retour arriere)", command=touche_retour_arriere)
touche_menu.add_command(label="Touche >|| (Lecture pause)", command=touche_lecture_pause)
touche_menu.add_command(label="Touche [] (Stop)", command=touche_Stop)
touche_menu.add_command(label="Touche >> (Avance rapide)", command=touche_avance_rapide)
touche_menu.add_command(label="Touche |<< (precedent)", command=touche_precedent)
touche_menu.add_command(label="Touche >>| (suivant)", command=touche_suivant)
touche_menu.add_command(label="Touche Start", command=touche_Start)
touche_menu.add_command(label="Touche directionnel haut", command=touche_directionnel_haut)
touche_menu.add_command(label="Touche directionnel gauche", command=touche_directionnel_gauche)
touche_menu.add_command(label="Touche directionnel bas", command=touche_directionnel_bas)
touche_menu.add_command(label="Touche directionnel droite", command=touche_directionnel_droite)
touche_menu.add_command(label="Touche L", command=touche_L)
menubar.add_cascade(label="Touches", menu=touche_menu)
 
config_menu = Menu(menubar, tearoff=0)
config_menu.add_command(label="Menu", command=donothing)
config_menu.add_command(label="Telecommande", command=donothing)
menubar.add_cascade(label="Config", menu=config_menu)
 
helpmenu = Menu(menubar, tearoff=0)
helpmenu.add_command(label="Index", command=donothing)
helpmenu.add_command(label="Aide1", command=aide1)
helpmenu.add_command(label="Aide2", command=aide2)
helpmenu.add_command(label="Aide3", command=aide3)
helpmenu.add_command(label="A Propos...", command=a_propos)
menubar.add_cascade(label="Aide", menu=helpmenu)
 
fenetre.config(menu=menubar)
fenetre.mainloop()
Merci.