hastebrot
01/20/2017, 6:38 PMjavafx.*
classes in the imports context menu somehow.edvin
01/20/2017, 8:41 PMedvin
01/20/2017, 8:42 PMbutton
would be to write this.button
. That would only match the EventTarget.button
extension function.edvin
01/20/2017, 8:43 PMjchildress
01/20/2017, 8:44 PMimport tornadofx.*
works for me...edvin
01/20/2017, 8:44 PMtornadofx.*
because lookups for builders will be faster as well.edvin
01/20/2017, 8:45 PMRuckus
01/20/2017, 8:47 PMimport tornadofx.*
for me is I like to use IDEA's smart code reformatting, and if less than 6 tornadofx imports are used, it replaces the *
with the actual imports. Do you know of a way to force IDEA to always use tornadofx.*
any time there are any tornadofc usages? (I don't want to change the setting globally as I like it, just for a given package like tornadofx)edvin
01/20/2017, 8:49 PMtornadofx
package. Then it would never be a problem, since you need to import some subtype of Component
to do anything TornadoFX related.edvin
01/20/2017, 8:49 PMedvin
01/20/2017, 8:53 PMjchildress
01/20/2017, 8:53 PMImport settings▾
jchildress
01/20/2017, 8:54 PMedvin
01/20/2017, 8:54 PMedvin
01/20/2017, 8:54 PMRuckus
01/20/2017, 8:55 PMtornadofx
and it does the trick.jchildress
01/20/2017, 8:55 PMedvin
01/20/2017, 8:55 PMRuckus
01/20/2017, 8:55 PMedvin
01/20/2017, 8:55 PMedvin
01/20/2017, 8:57 PMedvin
01/20/2017, 8:57 PMRuckus
01/20/2017, 8:58 PMpermalmberg
01/20/2017, 10:02 PMoverride fun show(property: IntProperty?) {
with(myForm) {
field(property?.header) {
textfield {
bind(property?.observable(IntProperty::getValue, IntProperty::setValue))
}
}
}
}
property : IntProperty
is a POJO, with get/set for an Integer
My problem is that the `bind`expression gives a Type Mismatch: Wants: Property<Int!>
, Found: PojoProperty<Int!>?
Is there anyway to make this binding work without going via a something like this (since `by property`can't be used for local variables):
var value: Int by property(0)
fun valueProperty() = getProperty(ViewBuilder::value)
permalmberg
01/20/2017, 10:04 PMshow(property: IntProperty)
fixes itedvin
01/20/2017, 10:06 PMtextfield
builder takes an observable as parameter, so you can do textfield(property?.observable..)
directly.permalmberg
01/20/2017, 10:06 PMedvin
01/20/2017, 10:07 PMImportSettingsPanel
within IDEA, still trying to figure out how it configures the star imports.permalmberg
01/20/2017, 10:08 PMedvin
01/20/2017, 10:09 PM