Comments (7)
Thanks, I'll have a look
from compose-multiplatform.
@alexstyl
Yes, I reproduced it. Investigating.
from compose-multiplatform.
UIApplication.shared
is illegal to access in App Extensions and we still wrongfully do it in order to ensure, that no drawing happens when app is in background (which it says it is, it's UB most likely anyway). Working around it will also require us to update Skia. The version we use still performs MtlIsAppInBackground
check (which does the same thing) and wrongfully exits not even trying to perform the draw logic.
This is possible to fix, but a bit later. We didn't plan supporting such a feature and didn't do any sort of investigations, so there are some implications in existing code (regarding lifecycle, etc).
from compose-multiplatform.
Can you try to rewrite this code using the anchor constraints instead of autoresize mask? It seems to me that the size could be calculated incorrectly in this code.
from compose-multiplatform.
I tried this code and the result is the same:
let rootView = ComposeView()
.frame(maxWidth: .infinity, maxHeight: .infinity)
.background(Color.white)
let controller = UIHostingController(rootView: rootView)
self.addChild(controller)
controller.view.translatesAutoresizingMaskIntoConstraints = false
self.view.addSubview(controller.view)
controller.view.leadingAnchor.constraint(equalTo: self.view.leadingAnchor).isActive = true
controller.view.trailingAnchor.constraint(equalTo: self.view.trailingAnchor).isActive = true
controller.view.topAnchor.constraint(equalTo: self.view.topAnchor).isActive = true
controller.view.bottomAnchor.constraint(equalTo: self.view.bottomAnchor).isActive = true
controller.didMove(toParent: self)
from compose-multiplatform.
Keep in mind that I tried the same code to render a Swift View and the contents of the Swift View were displayed correctly.
from compose-multiplatform.
@elijah-semyonov did u have a look? could you kindly confirm that is indeed a bug in compose?
from compose-multiplatform.
Related Issues (20)
- Reduce variety of Preview annotations HOT 5
- Being able to create a ComposePanel with vsync disabled
- Need to tap the touchpad thrice for double click action when using combined clickable. However, Button clicks are only required to clicked twice. HOT 4
- ImageVector is blurry when used with `Image()` + `Modifier.scale()` HOT 2
- [Compose Resources] commonMainResourceAccessors is not generated in multi-module architecture using Kotlin 2.0.0 HOT 4
- `Dialogs` are not rendered as expected when used inside a `ImageComposeScene`
- Unable to compile kotlinjs
- "No such file or directory" when using `Res.getUri()` HOT 6
- FocusRequester is not working on web both js(IR) and WASM the same as in JVM HOT 1
- Support getting resources by key
- Failed to use common source set to manage compose multi-language string resources HOT 2
- PointerInputChange onDrag events always emit ID of 0 on desktop HOT 3
- Default Proguard rules cause release task failure when using Material 3 instead of 2 in Compose Desktop HOT 1
- Jetsnack images are not loading HOT 1
- syncPodComposeResourcesForIos: Cannot query the value of this provider because it has no value available.
- [Gradle] tryGetSkikoRuntimeIfNeeded() eagerly resolves KMP runtime configuration on task creation HOT 2
- [Compose Resources] `MissingResourceException` in Auto-Updater application with different folders HOT 1
- Cannot change preferredStatusBarStyle on ComposeUIViewController HOT 1
- Buuld release not working with kotlin 2 HOT 1
- Use browser sessionStorage API to back rememberSaveable on web HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from compose-multiplatform.