Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
I just started to learn KMP and I want to see how to integrate C++ code into my project. I successfully edited the build.gradle.kts to build a C++ library for Android and have called a JNI function in the library. // composeApp/build.gradle.kts android { ... externalNativeBuild { cmake { path = file("src/main/cpp/CMakeLists.txt") version = "3.22.1" } } But the desktop version is not able to do the same. If it helps. So far I added the following: compose.desktop { application { ... jvmArgs += ...| Kotlin Discussions - Latest posts
Sorry for being reply this late, but I think we can create a CoroutineScope to do that easily, right?| Kotlin Discussions - Latest posts
Hi. While developing an app on Android Studio ( Meerkat Feature Drop | 2024.3.2 Patch 1 ), everything was going fine till today morning when, in order to create a ViewModel and Relevant Factory, I created a class called DataFetchViewModel. And suddenly following error has started to come. I have tried every single possible solution right from clearing caches, updating Android Studio, Repairing IDE, Rescanning indexes and what not. Any Help would be really helpful : kotlin version: 2.0.21 erro...| Kotlin Discussions
We have a native Android app that is mostly WebViews and uses Jetpack Navigation. We want to start migrating to fully native screens using Kotlin Multiplatform (KMP) to share both logic and UI between Android and iOS. None of us on the dev team has prior KMP experience. My assumption is the following: we could create a KMP module for, say, SSO, which uses Compose Multiplatform Navigation internally for its own screens. The Android app would continue using Jetpack Navigation. The native Androi...| Kotlin Discussions - Latest posts
I’m working on a Kotlin Multiplatform (KMP) project and want to explore whether it’s possible to configure on-demand feature delivery, similar to Android’s Play Feature Delivery or Play Asset Delivery. The idea is that we have a super app consisting of multiple modules say four independent apps/features and I want to separate each one so that when the user selects a specific app, it’s downloaded on demand and then opened directly within the same super app. I’d like to know: Can a KM...| Kotlin Discussions
A reactive pipeline is very commonly used in various sicarios. In frontend development, we use such pipelines to bind the states and views in many ways. For example, we have ref and computed in Vue. We have re-executing mechanism in React and Compose. In server side development, we use streams and flows to process sequential data. However, to define the reactive pipeline is not that intuitive. For example, to define c=a+b, we have to write a lambda with explicit specifications. The lambda thi...| Kotlin Discussions - Latest posts
I would also like to know why these are different and what to do about it. Note that the coroutines-core dependency also pulls in stdlib, meaning it pulls in both versions of the annotations. We run the enforcer plugin and its not happy about this.| Kotlin Discussions - Latest posts
@susmitha.gudapati how are you doing this now? I’ve found myself in the situation where i need to use Kotlin/JS with typescript interfaces, and everything i read and try gives very subpar results. I tried both dukat and karakum. I’m trying to convert the Obsidian library: https://www.npmjs.com/package/obsidian.| Kotlin Discussions - Latest posts
Consider the following example: Project foo is a KMP library with cinterop dependencies. The dependencies are built with system toolchain and target system libraries, e.g. glibc > 2.20 Project bar is a KMP / KN executable with a dependency on foo. When konan is invoked to build and link bar, it uses its own bundled LLVM and sysroot The sysroot bundled with konan (available in ~/.konan/dependencies) is heavily outdated (kernel 4.9.2, glibc 2.19) even though the LLVM toolchain is relatively rec...| Kotlin Discussions - Latest posts
I’m not sure if I’m opening this in the right place but I’ve been banging my head against the wall for over a month on this I’ve got a compose scrollable column with some items, and I can’t make accessibility navigation go through them in the order they’re laid out - specifically on iOS. Android works perfectly whether I define traversalIndex or not. What’s worse is it’s inconsistent. The slower I traverse (with accessibility swipes) the better it works, but never 100% and eve...| Kotlin Discussions - Latest posts
Hello everybody¡¡ I’m starting to learn different aspects about programming in kotlin. Sometimes I recive this confussin error message, I don’t understand it. can anybody explain me it?? but if I open the generated class after compile: Can anyone explain me why i’m getting that error?? Thanks in advance| Kotlin Discussions - Latest posts
Consider the following functions: fun Int.ext() { // TODO } fun doSomething(f: Int.() -> Unit) { // TODO } The functional parameter f has the same type as the extension function ext. So, I can do this: doSomething(Int::ext) The question is… In the body of doSomething function, I can do this: fun doSomething(f: Int.() -> Unit) { 42.f() // OK f(42) // OK } But when I call the ext function, this happens: 42.ext() // OK ext(42) // compiler error Why does that happens? I thought that function ty...| Kotlin Discussions - Latest posts
When int is converted into Integer (autoboxing), compiler calls public static Integer valueOf(int i); When underlying field is converted into an instance of the value class, the compiler calls ValueClass.box-impl method which just wraps constructor. I would like to implement cache in similar way as Integer does, but I cannot override the method. I tried sth with e.g. @JvmName@JvmStatic, but result method returns the underlying field instead of instence of the class and then it is not called w...| Kotlin Discussions - Latest posts
It works, Thanks!| Kotlin Discussions - Latest posts
I have the class O that defines the protected field code. I have the class BO that extends O. In a method of BO that takes a BO as a parameter, I can access this.code and other.code. But in a method of BO that takes an O as a parameter, I can access this.code but not other.code. Why ?| Kotlin Discussions - Latest posts
Consider this code: class Log { private fun print(input: String, params: String) { println("${input.padEnd(15)}-> $params") } fun debug(input: String, vararg data: Any) { print(input, "vararg data: Any") } fun debug(input: String, data: Any) { print(input, "data: Any") } } fun main() { val log = Log() log.debug("data = [data]", data = arrayOf("data")) log.debug("[data]", arrayOf("data")) } The output is: data = [data] -> vararg data: Any [data] -> data: Any The public methods on the class Log...| Kotlin Discussions - Latest posts
WorldWind Kotlin v1.8.8 - now with GeoPackage vector features and NGA styles support https://github.com/WorldWindEarth/WorldWindKotlin/releases/tag/v1.8.8 Added support of Geo Package Features Content with Well Known Binary Geometries and NGA Feature Styles Geo Package processing migrated to NGA library Added Geographic and Triangle Mesh shape rendering implementations Added possibility to create KMP image factories Added possibility to define base altitude level for shape extrude Added above...| Kotlin Discussions - Latest posts
I see that Compose Multiplatform 1.9 has just released with the introduction of the new WebElementView New API for embedding HTML content I’m making a Compose Multiplatform (targeted to iOS and Android) that’s just a wrapper to one of our existing SPA web apps. I’m using WKWebView on iOS and WebView on Android, giving them both a URL to your webapp to display. Should I now start using WebElementView instead? Is it meant as a good replacement for this? Thanks! Jørund| Kotlin Discussions - Latest posts
Any plans to support Java 25 now that gradle has released 9.1.0 with full support?| Kotlin Discussions - Latest posts
Hi, I have a quick question about exception handling when calling a Kotlin function from Swift/Objective-C code. Do I need to annotate all functions, including nested and helper functions, or is it enough to annotate only the public (API) function that is called from Swift? Best regards, Sven| Kotlin Discussions
Kotlin is a concise multiplatform language developed by JetBrains.| Kotlin Discussions
Java Version = 1.8 Idea Version = 2016.1 Build error Information:Kotlin: Kotlin JPS plugin version 1.0.1-release-IJ143-32 Information:Kotlin: Plugin loaded: KotlinAndroidJpsPlugin Information:Kotlin: Using kotlin-home = /Users/raccoon/Library/Application Support/IntelliJIdea2016.1/Kotlin/kotlinc Information:Kotlin: Kotlin Compiler version 1.0.1-1 Information:Kotlin: Using Kotlin home directory /Users/raccoon/Library/Application Support/IntelliJIdea2016.1/Kotlin/kotlinc Information:Kotlin: Co...| Kotlin Discussions