Skip to content

Added a \overset as a special string#1783

Merged
3b1b merged 1 commit into3b1b:masterfrom
EbbDrop:more-special-string
Apr 11, 2022
Merged

Added a \overset as a special string#1783
3b1b merged 1 commit into3b1b:masterfrom
EbbDrop:more-special-string

Conversation

@EbbDrop
Copy link
Copy Markdown
Contributor

@EbbDrop EbbDrop commented Apr 8, 2022

Motivation

Makes something like Tex("\overset", "{def A}", "{=}") work.

Proposed changes

Added "\\overset" -> "\\overset{\\quad}{\\quad}" and documented why \frac and friends do not work (yet).

Test

Code:

  color = {"isolate": ["{A}", "{B}"], "tex_to_color_map": {"{A}": GREEN, "{B}": BLUE}}
  t = Tex(r"a{B}c", r"\overset", "{A}{=} a{B}c", **color)
  self.play(Write(t))

Result:
Screenshot_2022-04-08_22-58-07

@TonyCrane TonyCrane requested a review from 3b1b April 10, 2022 03:48
@3b1b 3b1b merged commit d26b8a8 into 3b1b:master Apr 11, 2022
@EbbDrop EbbDrop deleted the more-special-string branch April 11, 2022 16:54
TonyCrane added a commit that referenced this pull request Apr 13, 2022
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

Successfully merging this pull request may close these issues.

3 participants