mirror of
https://github.com/XITRIX/NXKit.git
synced 2026-05-30 11:46:52 +00:00
main
Warning
Deeply WIP project!
Main goal is to create a UI framework that tries to mimic Apple's UIKit as much as possible, so any iOS developer will be able to start using it without learning things from scratch and be as much portable as possible supporting various of platforms.
Current state:
- Skia powered renderer
- Platforms supported:
- iOS
- macOS
- Nintendo Switch (LibNX)
- Core implementation:
- CALayer (rendering hierarchy)
- Yoga flex auto layout
- Animation system
- Responder chain (touch propagation)
- Focus system (basic gamepad input support)
- UITraitCollection (dark mode)
TODO:
- UIViewController presentation
- Interface Builder
- A lot of things tbh ...
Build
First Skia need to be compiled:
Switch:
bin/gn gen out/horizon --args='is_official_build=false skia_use_gl=true is_trivial_abi=true target_cpu="arm64" target_os="horizon" is_debug=false'
ninja -C out/horizon skia skparagraph
iOS:
bin/gn gen out/ios-arm64 --args='is_official_build=false target_cpu="arm64" skia_use_gl=true skia_use_metal=true is_trivial_abi=true target_os="ios"'
ninja -C out/ios-arm64 skia skparagraph
macOS:
bin/gn gen out/mac-arm64 --args='is_official_build=false target_cpu="arm64" skia_use_gl=true skia_use_metal=true is_trivial_abi=true'
ninja -C out/mac-arm64 skia skparagraph
To build project:
Switch:
cmake -B build/switch -DPLATFORM_SWITCH=ON
make -C build/switch ThorVGApp.nro -j$(nproc)
nxlink build/switch/ThorVGApp.nro
iOS:
cmake -B build/ios -GXcode -DPLATFORM_IOS=ON
open xCode project
Description
Languages
C++
49.3%
C
47.9%
CMake
1.5%
Python
0.6%
Objective-C
0.4%
Other
0.2%