is kotlin native also part of the cooperation with...
# kotlin-native
s
is kotlin native also part of the cooperation with Google? i mean are Google interested about it? i suspect they'll choose kotlin native for main programming language for their new "fuchia" platform 😛
r
Why do you think they would choose Kotlin/Native over Go?
n
Aren’t they using dart on the platform?
s
i don't know i have a feeling they might choose kotlin native
@nitrog42 i heard some stuff about it, but i don't think they made official announcement about dart
and i hope it won't be go, i hate that language
r
Kotlin Native is something we are extreme interested in for Android, esp. for code reusability with other platforms, or just to avoid JNI when possible
👍 13
t
Fuchsia seems to be closely tied to Flutter, which uses Dart ... which doesn't strike me as a particularly beautiful language, so if Fuchsia gains momentum, perhaps Kotlin/Native could be made to interoperate with Flutter's AOT compiled Dart... 🙏 ...and people won't have to rewrite everything in yet another language.
k
in case you didn't know, ^ romain guy is an android engineer at google
s
Flutter with Kotlin/Native... Ah, dreams, dreams...
n
If i'm not mistaken Flutter is Dart specific. Somehow I don't think Dart APIs are Kotlin compatible.
At the end of the day Fushsia is still an experimental project, unless Google have turned it into an industrial one. As a guess (prediction you have seen here first simple smile ) Google have a very high chance of dropping Dart support if Fushia is intended as an eventual replacement to Android.
s
As far as I know, Flutter uses a blink-based (chrome) rendering engine as base layer. Only painting and text layouting engine is used. All other parts, including rendering and even non-basic painting implemented in dart code which itself is AOT-compiled to native code. example: https://github.com/flutter/engine/blob/master/lib/ui/painting.dart#L1532 binded to https://github.com/flutter/engine/blob/master/lib/ui/painting/canvas.h#L64 My dream is framewrok with architecture like Fultter, but with Kotlin/Native instead of Dart. For now, flutter looks very powerful framework for developing UI: rich and powerful widgets framework, solid archetecture and very useful hot reload (it is like Instant Run in Andriod Studio, but works 🙂 )
t
It's not really Blink-based, is it? It just uses Skia, the drawing library used by Chrome but also by Android and (on some platforms) Firefox. So it's more like React Native than React (i.e. doesn't render to a browser engine), except it draws its own widgets, so Flutter is to React Native as Swing is to AWT (kind of). Anyway, I think the view construction code would look a lot better with a Kotlin DSL than it does in Dart, e.g. https://flutter.io/tutorials/layout/#step-2-implement-the-title-row
1
👍🏻 2
s
My assumptions about blink comes from lines like this. https://github.com/flutter/engine/blob/6c5315c3a1d72ee2aae520e05c1ebf0f6794ae0e/lib/ui/painting/rrect.h#L12
namespace blink {