小编rey*_*yez的帖子

Tkinter复选框/组合框下拉列表

我试图用Python创建一个后处理数据应用程序,并且正在使用Tkinter为此设计GUI。

我不知道Tkinter是否支持由复选框组成的下拉列表,然后您可以从中选择多个复选框。下图反映了我要描述的内容:

在此处输入图片说明

这可能吗?

python checkbox combobox tkinter list

5
推荐指数
1
解决办法
3173
查看次数

在饼图上显示带有图例的数字 - Tkinter,Pyplot,Matplotlib

我正在使用Tkinter为界面开发一个应用程序,然后使用matplotlib中的pyplot创建一个饼图.

我已成功地在没有图例的饼图上显示数据,从而显示百分比.以下是相关的源代码提取.

labels = ["Oranges", "Bananas", "Apples", "Kiwis", "Grapes", "Pears"]
values = [0.1, 0.4, 0.1, 0.2, 0.1, 0.1]

 # now to get the total number of failed in each section
actualFigure = plt.figure(figsize = (8,8))
actualFigure.suptitle("Fruit Stats", fontsize = 22)

#explode=(0, 0.05, 0, 0)
# as explode needs to contain numerical values for each "slice" of the pie chart (i.e. every group needs to have an associated explode value)
explode = list()
for k in labels:
    explode.append(0.1)

pie= plt.pie(values, labels=labels, …
Run Code Online (Sandbox Code Playgroud)

python tkinter matplotlib pie-chart

3
推荐指数
1
解决办法
7464
查看次数

标签 统计

python ×2

tkinter ×2

checkbox ×1

combobox ×1

list ×1

matplotlib ×1

pie-chart ×1