当前位置:网站首页>Flet教程之 16 Tabs 选项卡控件 基础入门(教程含源码)
Flet教程之 16 Tabs 选项卡控件 基础入门(教程含源码)
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 my limited software testing experience, a full-time summary of automation testing experience
- What is cloud computing?
- Le Cluster kubernets en cours d'exécution veut ajuster l'adresse du segment réseau du pod
- MIF file format record
- Half of the people don't know the difference between for and foreach???
- STM32入门开发 采用IIC硬件时序读写AT24C08(EEPROM)
- Talk about SOC startup (VI) uboot startup process II
- oracle常见锁表处理方式
- Neural approvals to conversational AI (1)
- Learning notes | data Xiaobai uses dataease to make a large data screen
猜你喜欢
正在运行的Kubernetes集群想要调整Pod的网段地址
In my limited software testing experience, a full-time summary of automation testing experience
What is cloud computing?
How to write test cases for test coupons?
分布式数据库主从配置(MySQL)
请查收.NET MAUI 的最新学习资源
总结了200道经典的机器学习面试题(附参考答案)
Nuclear boat (I): when "male mothers" come into reality, can the biotechnology revolution liberate women?
聊聊SOC启动(七) uboot启动流程三
The post-90s resigned and started a business, saying they would kill cloud database
随机推荐
Qt|多个窗口共有一个提示框类
基于华为云IOT设计智能称重系统(STM32)
使用MeterSphere让你的测试工作持续高效
Verilog realizes nixie tube display driver [with source code]
禁锢自己的因素,原来有这么多
electron添加SQLite数据库
Excel公式知多少?
TDengine 社区问题双周精选 | 第二期
R language uses image of magick package_ Mosaic functions and images_ The flatten function stacks multiple pictures together to form a stack layers on top of each other
测试优惠券要怎么写测试用例?
学习笔记|数据小白使用DataEase制作数据大屏
Software design - "high cohesion and low coupling"
Network protocol concept
Briefly introduce closures and some application scenarios
Creative information was surveyed by 2 institutions: greatdb database has been deployed in 9 places
Complete collection of common error handling in MySQL installation
Blog moved to Zhihu
Leetcode - interview question 17.24 maximum submatrix
网络协议 概念
一起探索云服务之云数据库