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

Feature: Allow changing execution order of map-rows and map-cols #124

Closed
wants to merge 1 commit into from
Closed

Feature: Allow changing execution order of map-rows and map-cols #124

wants to merge 1 commit into from

Conversation

HallerPatrick
Copy link

I quickly setup a working modification, such that the user can decide which mapping function is called first and second. I dont know if this is idiomatic typst code. Feel free to adjust or discard :) This solves #123

Copy link
Owner

@PgBiel PgBiel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!
Do you think you can rebase this PR on (and point it to be merged to) 0.1.0-dev, where the latest developments occur? Should be a matter of just moving code to the appropriate files.

If not, I can try to do it at some point.

@@ -2821,6 +2841,7 @@
map-vlines: none,
map-rows: none,
map-cols: none,
map-order: ("rows", "cols"),
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it should just be a string, "rows" or "cols". This design would allow running the mappers multiple or even zero times.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So you mean, if map-order is "cols", then it should first run the cols mapper and then the rows mapper and vice versa? Then I would choose a more descriptive name for the options such as "rows-first" and "cols-first".

@PgBiel PgBiel added the enhancement New feature or request label Feb 19, 2024
@PgBiel PgBiel added this to the v0.1.0 milestone Feb 19, 2024
@HallerPatrick HallerPatrick closed this by deleting the head repository Feb 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants