I have a Java class: ``` public final class Util...
# announcements
r
I have a Java class:
Copy code
public final class Utils {
  public static void somethingUseful() {}
}
I don't see any suggestion to import the static method
Utils.somethingUseful()
when writing Kotlin code. Do I need to configure the Kotlin IDEA plugin?
I'm using
Version: 1.1.3-release-Studio3.0-2
g
Should work. If I write utils class name I see this class in suggestions, and if I choose it, Idea adds import. If I write only Utils method name and use Smart Type then Idea suggests me this class and method and imports it
r
apparently it didn't work for me then, let me record a video and share here
It only work if I already imported the class
g
If you want to use static function from not imported class and write only function name you must use Class Name Completion it always worked this way for java and kotlin in Idea, otherwise suggestion of all available static functions would pollute suggestions To import class by function name write “colorize” and then press Class Name Completion (Ctrl + Alt + Space on Mac)
And you don’t need it if class already imported or you wrote class name before function
r
very useful, thanks Andrey
👌 1
c
its a bug in 1.1.3. works in 1.1.2