Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [kotlin]

Kotlin is a cross-platform, statically typed, general-purpose high-level programming language with type inference. This tag is often used alongside additional tags for the different targets (JVM, JavaScript, native, etc.) and libraries/frameworks (Android, Spring, etc.) used by Kotlin developers, if the question relates specifically to those topics.

kotlin
0 votes
0 answers
51 views

Adding module-info.java to a Kotlin project causes build error

I was trying to make a JavaFX project with Kotlin, Gradle on IntelliJ IDEA. Using Java 17. At first, I didn't used module-info.java, and it worked well, but it warned me "WARNING: Unsupported ...
2 votes
1 answer
50 views

Resolving scroll conflict: PullToRefresh (vertical) vs. Horizontal Pager in Jetpack Compose

I'm developing a screen in Jetpack Compose that combines two scrolling components: a PullToRefresh for vertical scrolling and an ImageSlider implemented using HorizontalPager for horizontal scrolling. ...
2 votes
1 answer
44 views

Migrating to Kotlin 2.0.0 causes compile time errors associated with nullablity

I am currently migrating my Android application to Kotlin 2.0.0: val myConfig: Configuration? = null val myFrameRate: String? = getPreferences(Context.MODE_PRIVATE).getString("my_FrameRate&...
0 votes
1 answer
391 views

Why the ModalBottomSheet is behind the navigation bar?

I need to implement a ModalBottomSheet in my app. But before doing that, I test it in a test app following this example. The problem is that the ModalBottomSheet does not appear above the navigation ...
1 vote
1 answer
28 views

RequestBody object with single property spring-boot

Language: Kotlin, Spring version: 3.2.3 I have controller that gives an object with single property: @RestController @RequestMapping("") class Test { @PostMapping("khar") ...
3 votes
1 answer
48 views

Enums in JNI GetMethodID signature parameter list

So, this is an edge case that no amount of Googling seems to unearth. I have an enum in Kotlin; package myapp public enum State { STATE_SUCCEEDED, STATE_FROZEN, STATE_WAITING, ...
0 votes
0 answers
10 views

Android compose `NotificationListenerService.onNotificationPosted` is never called

I'm trying to add a notification listener to a Kotlin android compose project: My AndroidManigest.xml: <application> <!-- ... --> <service android:name=&...
-1 votes
0 answers
10 views

Could not find gradle-8.3.1.jar (com.android.tools.build:gradle:8.3.1)

I want to create a new project I got this error: A problem occurred configuring root project 'My Application'. Could not resolve all files for configuration ':classpath'. Could not find gradle-8.3.1....
0 votes
0 answers
11 views

Crash on Destroy Method: "View ... does not have a NavController set"

I am getting a crash in the onDestroy method with the following error: `Fatal Exception: java.lang.RuntimeException: Unable to destroy activity {com..presentation.screens.main.MainActivity}: java.lang....
0 votes
1 answer
17 views

How to Pass ArrayList of Custom Objects Between Activities in Kotlin on Android Studio

I'm working on an Android project in Kotlin where I store user information in a custom object. I need to pass an ArrayList<CustomObject> from one activity to another and display the stored ...
0 votes
1 answer
15 views

Could not get unknown property 'kotlin_version' Flutter packages

after updating Flutter I'm getting this error with almost every package I add to the project. For this example we'll use the permission_handler package. FAILURE: Build failed with an exception. * ...
3 votes
2 answers
2k views

How to change the color of the icons in the navigation bar in Jetpack Compose?

I have modified the color of the navigation bar to put a lighter color: <item name="android:navigationBarColor" tools:targetApi="1">@color/navigation_bar</item> Now ...
-1 votes
2 answers
48 views

how to solve the stupid error your project requires a newer version..?

BUILD FAILED in 1m 21s Running Gradle task 'bundleRelease'... 82.6s ┌─ Flutter Fix ─────────────────────────────────────────────────────────────────────────────────────┐ │ [...
-2 votes
0 answers
25 views

Linking of multiple apps [closed]

If we create an flutter application (Android + iOS) using visual studio code "we have 3 applications named A, B & C. A is the main app and the other two apps (B & C) are separate apps. i ...
17 votes
7 answers
35k views

Kotlin - Error: Could not find or load main class _DefaultPackage

I followed the Kotlin tutorial for eclipse here : Getting Started With Eclipse Luna However, I'm running into this error: Error: Could not find or load main class _DefaultPackage Anyone who knows ...

15 30 50 per page
1
2 3 4 5
6436