Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enchance webide-representation support #112

Open
VitaliyZaharenko opened this issue Apr 15, 2020 · 1 comment
Open

Enchance webide-representation support #112

VitaliyZaharenko opened this issue Apr 15, 2020 · 1 comment

Comments

@VitaliyZaharenko
Copy link
Contributor

VitaliyZaharenko commented Apr 15, 2020

I have two issues that's related to -webide-representation

  1. When we define type in external file(to use it with import in some other .ksy file) we have no way to use -webide-representation. Seems that obj, which passed to
// paresedToTree.ts
reprObject(obj: IExportedValue): string

have ksyType undefined on imported types.
2. I think we need more flexible way to represent values in -webide-representation. Especially numeric types. It would be nice to add the ability to limit the number of decimal places for float numbers. When we parse vectors, quaternions or matrices, this is especially desirable. Maybe in addition to hex, dec etc add len attribute, something like "{x:len=3} Or add more general dsl for value manipulations, like c format string or smth.

@GreyCat
Copy link
Member

GreyCat commented Apr 15, 2020

@VitaliyZaharenko Likely we'll try to deprecate -webide-representation and replace it with more universal to-string, as per kaitai-io/kaitai_struct#732.

Basically, the idea is to reuse existing KS expression language syntax, so we'd likely enhance KS expression language so it will include interpolated strings, rich formatting, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants