-
Notifications
You must be signed in to change notification settings - Fork 71
Add full placeholder when it's convenient #103
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
Add full placeholder when it's convenient #103
Conversation
| case MathAtomType.Fraction: | ||
| case MathAtomType.Ordinary: | ||
| // functions are treated as a LargeOperator so no special case here. Yet? | ||
| case MathAtomType.LargeOperator: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LargeOperators have special handling for positioning of superscripts and subscripts. They always support them.
| return false; | ||
| default: | ||
| return true; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will a blacklist-based approach be better? It seems that adding a placeholder is the minority case and new cases for MathAtomType should support direct scripts by default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe even black & white lists with default false?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case, a switch expression should be used for exhaustiveness warnings.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Played a bit with both approaches. Now I also see more advantages of having the single list. You're totally right.
Close: #47