当前位置:网站首页>Flet教程之 17 Card卡片组件 基础入门(教程含源码)
Flet教程之 17 Card卡片组件 基础入门(教程含源码)
2022-07-07 09:46:00 【知识大胖】
Flet是什么
Flet 是一个框架,使您能够轻松地以您喜欢的语言构建实时 Web、移动和桌面应用程序,并与您的团队安全地共享它们。无需前端经验。
什么是GridView
带有略微圆角和高程阴影的面板。
实战代码
import flet
from flet import Image, Page, GridView, border_radius
def main(page: Page):
page.title = "GridView Example"
page.theme_mode = "dark"
page.padding = 50
page.update()
images = GridView(
expand=1,
runs_count=5,
max_extent=150,
child_aspect_ratio=1.0,
spacing=5,
run_spacing=5,
)
page.add(images)
for i in range(0, 60):
images.controls.append(
Image(
src=f"https://picsum.photos/150/150?{i}",
fit="none",
repeat="noRepeat",
border_radius=border_radius.all(10),
)
)
page.update()
flet.app(target=main, view=flet.WEB_BROWSER)
边栏推荐
- In depth learning autumn recruitment interview questions collection (1)
- Use metersphere to keep your testing work efficient
- Easyui学习整理笔记
- Zhou Yajin, a top safety scholar of Zhejiang University, is a curiosity driven activist
- Activity lifecycle
- Excel公式知多少?
- There are ways to improve self-discipline and self-control
- 一起探索云服务之云数据库
- Tsinghua Yaoban programmers, online marriage was scolded?
- La voie du succès de la R & D des entreprises Internet à l’échelle des milliers de personnes
猜你喜欢
Verilog design responder [with source code]
Web端自动化测试失败的原因
【系统设计】指标监控和告警系统
Nuclear boat (I): when "male mothers" come into reality, can the biotechnology revolution liberate women?
Le Cluster kubernets en cours d'exécution veut ajuster l'adresse du segment réseau du pod
学习笔记|数据小白使用DataEase制作数据大屏
Complete collection of common error handling in MySQL installation
在我有限的软件测试经历里,一段专职的自动化测试经验总结
The road to success in R & D efficiency of 1000 person Internet companies
一度辍学的数学差生,获得今年菲尔兹奖
随机推荐
Some opinions and code implementation of Siou loss: more powerful learning for bounding box regression zhora gevorgyan
【问道】编译原理
清华姚班程序员,网上征婚被骂?
Stm32f1 and stm32subeide programming example -max7219 drives 8-bit 7-segment nixie tube (based on SPI)
Test the foundation of development, and teach you to prepare for a fully functional web platform environment
深度学习秋招面试题集锦(一)
关于在云服务器上(这里用腾讯云)安装mysql8.0并使本地可以远程连接的方法
R語言使用magick包的image_mosaic函數和image_flatten函數把多張圖片堆疊在一起形成堆疊組合圖像(Stack layers on top of each other)
【系统设计】指标监控和告警系统
Talk about SOC startup (x) kernel startup pilot knowledge
软件设计之——“高内聚低耦合”
R语言使用quantile函数计算评分值的分位数(20%、40%、60%、80%)、使用逻辑操作符将对应的分位区间(quantile)编码为分类值生成新的字段、strsplit函数将学生的名和姓拆分
STM32入门开发 编写DS18B20温度传感器驱动(读取环境温度、支持级联)
测试开发基础,教你做一个完整功能的Web平台之环境准备
The Oracle message permission under the local Navicat connection liunx is insufficient
千人規模互聯網公司研發效能成功之路
Onedns helps college industry network security
互联网协议
Electron adding SQLite database
Audit migration