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

True italic font support #711

Open
mklein994 opened this issue Jun 10, 2018 · 8 comments
Open

True italic font support #711

mklein994 opened this issue Jun 10, 2018 · 8 comments

Comments

@mklein994
Copy link
Contributor

Currently, italic fonts are achieved by making the current font oblique. It would be great if it would use the italic font instead.

Here's how I envision it could work: Similar to using a custom font with ~/.termux/font.ttf, put an italic font in a file called ~/.termux/font-italic.ttf. Then run this:

$ termux-reload-settings
$ echo -e '\e[3m light fixture \e[0m' # characters that look different in italics

and it would print this:
light fixture


Examples with Source Code Pro

Regular:

screenshot_20180610-172126

Italic:

screenshot_20180610-173553

@LittleHouse75
Copy link

This would be very cool -- hoping to use the font Operator Mono (or one of its free clones) with emacs in Termux.

@ghost ghost added the enhancement label Jan 14, 2019
@zorro
Copy link

zorro commented Mar 18, 2020

Any updates on this?

@doas-ice
Copy link

doas-ice commented Jul 3, 2020

It would be really cool to have this feature. I really love Victor-mono.

@j0ng4b
Copy link

j0ng4b commented Jun 7, 2022

Well, I successfully build a version of termux thats support italics here some screenshots:

With an italic font:
Italic

Without an italic font:
Screenshot_20220606-225524-874

Without italic the text is rendered as a monospaced text. Should I make a pull request? I not already not made one because what I made on code seems a bit of mess and had some points I can't understand.

@j0ng4b
Copy link

j0ng4b commented Jun 7, 2022

Would be possible to also add true support to bold fonts.

@zorro
Copy link

zorro commented Jun 7, 2022

Well, I successfully build a version of termux thats support italics here some screenshots:

With an italic font: Italic

Without an italic font: Screenshot_20220606-225524-874

Without italic the text is rendered as a monospaced text. Should I make a pull request? I not already not made one because what I made on code seems a bit of mess and had some points I can't understand.

I think it will be better to fallback to the regular font rather than the monospace font

@j0ng4b
Copy link

j0ng4b commented Jun 7, 2022

I think it will be better to fallback to the regular font rather than the monospace font

It's true, I forgot to made this, the monospace was to test if everything works as expected, a better fallback is to use the current behaviour of italics alongside the regular font

@rendiix
Copy link

rendiix commented Jun 21, 2022

amazing, waiting for this PR to be merged

Screenshot_20220621-080109669 (1)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants