-
Notifications
You must be signed in to change notification settings - Fork 343
KaTeX overline underline border #1919
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
base: main
Are you sure you want to change the base?
Conversation
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.
Thanks @MdSaifAliMolla! This will also need updates to the KaTeX widget tests, and also please update the description with screenshots comparing both web and mobile.
|
||
static final overline = KatexExample.block( | ||
r'overline: \overline{a}', | ||
r'\overline{a}', |
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.
Please add a link to a test message in #test here channel, matching other tests.
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.
done.
case 'overline': | ||
// .overline { border-top: 0.04em solid; } | ||
borderStyle = KatexBorderStyle( | ||
position: KatexBorderPosition.top, | ||
widthEm: 0.04, | ||
color: KatexSpanColor(0, 0, 0, 255), | ||
); | ||
|
||
case 'underline': | ||
// .underline { border-bottom: 0.04em solid; } | ||
borderStyle = KatexBorderStyle( | ||
position: KatexBorderPosition.bottom, | ||
widthEm: 0.04, | ||
color: KatexSpanColor(0, 0, 0, 255), | ||
); |
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.
These don't seem to match an existing class in katex.scss
. Can please you provide the reference for these styles?
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.
i didn't find any related class in katex.scss, but i found that the border-width is given 0.04em or 0.049em in some places.
Mostly did trial and error and whatever pleases the eye😔.
.angl { // from package actuarialangle, which is always used in a subscript. box-sizing: border-box; border-top: 0.049em solid; // defaultRuleThickness in scriptstyle border-right: 0.049em solid; // ditto margin-right: 0.03889em; // 1 mu }
also this
.fcolorbox { box-sizing: border-box; border: 0.04em solid; // \fboxrule = 0.4pt }
dbc21a9
to
31d7ab8
Compare
31d7ab8
to
4a99319
Compare
@rajveermalviya take a look. |
closes #1673
To reduce the gap between line and text, I used CustomPainter.