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

Allow text decoration color to be set #812

Closed
r0ckarong opened this issue May 11, 2017 · 6 comments
Closed

Allow text decoration color to be set #812

r0ckarong opened this issue May 11, 2017 · 6 comments

Comments

@r0ckarong
Copy link
Contributor

Is it possible to allow setting the color of text decoration separate from the font color? We are using Black headings with orange underlines in the new corporate style and I would like to support that.

Relates to
#811

@r0ckarong
Copy link
Contributor Author

r0ckarong commented May 11, 2017

Sorry posted the answer to the wrong issue: https://developer.mozilla.org/en-US/docs/Web/CSS/text-decoration-color

This allows you to set text decoration color in CSS. I would expect this to work just as described in the examples. Works well in HTML.

@mojavelinux
Copy link
Member

mojavelinux commented May 11, 2017

I updated the link to point to MDN, which is a trusted source for information about CSS ;)

@r0ckarong
Copy link
Contributor Author

Good to know =)

@mojavelinux
Copy link
Member

There's also been interest in controlling the thickness of the line.

mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Nov 15, 2019
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Nov 15, 2019
@mojavelinux
Copy link
Member

I've submitted a PR with a prototype. See #1388.

Prawn uses the line width that is set on the document to draw the line for the underline and strikethrough styles. So we could solve the issue of the line being too thick simply by changing that value. I don't think that default value is used anywhere else.

@mojavelinux
Copy link
Member

The problem with setting the line width globally to a value other than 1 is that the PDF generator than write the line width to the start of every content stream. That will break both tests and assumptions. So it's better to change the line width at the point of use.

mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Nov 21, 2019
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Nov 22, 2019
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

No branches or pull requests

2 participants