I'm new to Anko and would like to know what is the...
# anko
a
I'm new to Anko and would like to know what is the best way of specifying the same layout params on more than one component?
l
Using Splitties View DSL (preferrably the snapshot version, which reflects the current develop branch, until I publish alpha-05 or newer version) is your best option I guess, as you don't have subclass View, and layout params functions work for all `View`s. Full disclosure: I am the author of Splitties
a
Is that instead of Anko?
l
It's an alternative, yes. I made it after trying anko, and after having went back to xml
a
Thanks. I'll take a look, but I'd like to try Anko first.
a
You can try with an function receiving as parameter the
context
you need or an extension function for that context. You can see that context in the DSL I suppose you already have
g
I wonder if there's a way to extend a widget and set default lparams values for it. I extended toolbar but only use it to hide the child views