non compositional custom editor

I have one concept my_byte which contains an integer property from 0 to 255 and a concept my_word, which contains two children LSB and MSB of type my_byte. If for instance I want to represent the number 512, LSB must be 0 and MSB must be 2.

Is it possible to define an editor for my_word that is not a composition of the two my_byte editors? Is it possible to directly write 512 and LSB/MSB are calculated automatically.

Of course I know that Java code is needed for this. But I wonder if really a complete custom editor must be developed. Is there a way to use the cell provider of an existing editor and just replace a few functions that are related to the string representation? An editor with a user replaceable lambda function would be great.

1 comment

I think the "model access" cell can be used here. You specify the get/set/validate functions to convert the values of LSB and MSB into a string and vice versa.




Please sign in to leave a comment.