ios 26的tabbar 背景透明

if #available(iOS 13.0, *){

let appearance = UITabBarAppearance()

appearance.configureWithTransparentBackground()

// 移除阴影和边框

appearance.shadowColor = .clear

appearance.shadowImage = UIImage()

appearance.backgroundImage = UIImage()

// 设置标准外观

tabBar.standardAppearance = appearance

// iOS 15 需要设置 scrollEdgeAppearance

if #available(iOS 15.0, *) {

tabBar.scrollEdgeAppearance = appearance

}

appearance.backgroundImage = UIImage()

appearance.shadowImage = UIImage()

appearance.backgroundColor = .clear

tabBar.standardAppearance = appearance

}else{

tabBar.isTranslucent = true

tabBar.backgroundColor = .clear

}

相关推荐
元Y亨H4 天前
MacBook Air 开发神器:IDEA 与 PyCharm 极简安装及环境配置
macos
yuanyxh5 天前
macOS 应用 - 纯对话生成
前端·macos·ai编程
AI创界者7 天前
PilotTTS 一键整合包(Win/Mac):8G 显存畅跑,实测解锁情绪与副语言的精准控制
人工智能·macos·aigc·音视频
AirDroid_cn7 天前
系统终端与iTerm2字体看起来不一样?macOS Sequoia统一渲染指南
macos
JiaWen技术圈7 天前
2026 年的 macOS 磁盘清理方法
macos
lichong9517 天前
让AI自己用电脑!Cua:后台操作鼠标键盘,Mac/Windows/Linux全支持
人工智能·macos·ai·计算机外设·agent·提示词
A尘埃7 天前
批处理命令(Linux/Mac、Windows项目启动脚本)
linux·windows·macos
zzb15807 天前
ios基础-MVC-UIView
ios·mvc·cocoa
他们都不看好你,偏偏你最不争气8 天前
【iOS】Runtime - Part 2 && 消息发送:缓存、查找与转发
macos·ios·objective-c·cocoa