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

API for updating column descriptions in List2 #217

Open
gferreira2 opened this issue Sep 10, 2024 · 2 comments
Open

API for updating column descriptions in List2 #217

gferreira2 opened this issue Sep 10, 2024 · 2 comments

Comments

@gferreira2
Copy link

sometimes the number of columns in a table needs to change based on context: the number of axes in a designspace, the number of points in a glyph, etc.

could we have a proper API for this? something like List2.updateColumnDescriptions()

thanks in avance for considering it!

@typesupply
Copy link
Member

I want to add the following methods:

  • appendColumn(description)
  • removeColumn(identifier)
  • insertColumn(index, description)

It shouldn't be too hard to do. The _buildColumns method called during __init__ just needs to be refactored so that it can do the description to NSTable conversion at any time.

@typemytype
Copy link
Member

The most tricky part is matching the data model with the new identifiers: it could be a dict with associated keys or a nsobject with associated methods

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

3 participants